Call of Duty 4: Scripting Reference - BadPlaces::BadPlace Arc

From COD Modding & Mapping Wiki
Share/Save/Bookmark
Jump to: navigation, search


BadPlace_Arc( <name>, <duration>, <origin>, <radius>, <height>, <direction>, <right angle>, <left angle>, <team>, ... )

Module: BadPlaces
SP Only

Summary:

Creates a bad place arc. AI will flee this position if they can, and will not go into it if they can avoid it.


Call this on:

Example:

BadPlace_Arc( "halftrack_bp", -1, mg42.origin, 1500, 400, (1.00, 0.00, 0.00), 20, 0, "allies" );

Required arguments:

  1. <name> The name of the bad place. If name is not "", the bad place can be moved or deleted by using the unique name.
  2. <duration> If duration > 0, the bad place will automatically delete itself after this time. If duration <= 0, the bad place must have a name and will last until manually deleted.
  3. <origin> The base position of the bad place.
  4. <radius> The radius of the bad place.
  5. <height> The height of the bad place.
  6. <direction> The direction vector is used to give a reference frame for the left and right angles.
  7. <right angle> The left angle and right angle are both positive angles (eg, "45, 45" will give a 90 degree arc).
  8. <left angle> The left angle and right angle are both positive angles (eg, "45, 45" will give a 90 degree arc).
  9. <team> You must specify at least one team for which this place is bad, but can give several. The allowed teams are 'axis', 'allies', and 'neutral'.


Optional arguments:

none


Notes:

none