CampType Goal

+ attack
	+ defend
	+ camp
	+ mobilemg42
	+ snipe
* /bot goal\_setproperty facing 0
	+ optionally set additional facings. /bot goal\_setproperty facing 1 for example
* optionally set the stance. defaults to stand for all but mobilemg42
	+ /bot goal\_setproperty stance crouch or /bot goal\_setproperty stance prone
		- note that stance can not be set for mobilemg42 since it needs to be prone
* /bot goal\_finish

## Detailed Instructions

### Attack, Defend, Camp, Snipe

#### Description

Camp is a new goal type that is the logic behind all of these goal types. Attack, Defend, and Snipe were included to maintain backwards compatibility in map scripts that use the old names. Any of these goal types can be used when creating new goals. These goals are used to get the bots to go to and guard specific locations for some amount of time.
#### Setup

See the Fastrack example at the top of the page for an example setup.
#### Properties

Properties can be set with the goal\_setproperty command assuming that the goal has been selected.
##### facing

Facing is the direction the bots will look when at the camp spot. Any number of facings can be defined. Multiple facings results in the bots randomly choosing which one to use every second or so; resulting in the bots 'scanning' between them. When rendering the goal, facings are represented by a blue line with a white number attached to them. The white number is the index of the aim position which makes it easier to edit specific facings should they need to be changed.

**syntax:** /bot goal\_setproperty facing <int index>
**example:** /bot goal\_setproperty facing 0
**note:** The goal itself forces facing indexes to be added sequentially. This means that trying to set facing index 99 when only 1 other facing exists will result in index 1 being set ( indexes start at 0 ).
##### stance

Set the stance the bot should assume while performing this action.

**syntax:** /bot goal\_setproperty stance <string stance>
**example:** /bot goal\_setproperty stance crouch
**values:** stand crouch prone
##### group

A group is a method of organizing sets of goals. One advantage to this is that all goals in a group can be enabled or disabled in one line of script rather than seperate goal types requiring additional lines to enable or disable them. Assigning roles to a group is also possible as an alternative to assigning each individual goal a role.

**syntax:** /bot goal\_setproperty group <string groupName>
**example:** /bot goal\_setproperty group myGroup
##### mincamptime

MinCampTime defines the minimum amount of time in seconds a bot will spend at a camp spot.

**syntax:** /bot goal\_setproperty mincamptime <float seconds>
**example:** /bot goal\_setproperty mincamptime 15.0
**default:** 2.0 seconds
##### maxcamptime

MaxCampTime defines the maximum amount of time in seconds a bot will spend at a camp spot.

**syntax:** /bot goal\_setproperty maxcamptime <float seconds>
**example:** /bot goal\_setproperty maxcamptime 30.0
**default:** 6.0 seconds
##### tagname

Sets the name of the goal. This can optionally be set when passed as the optional parameter in the goal\_create command. Useful for renaming goals.

**syntax:** /bot goal\_setproperty tagname <string name>
**example:** /bot goal\_setproperty tagname myGoalName
##### role

See the section on bot roles.

**syntax:** /bot goal\_setproperty role <role mask>
**example:** /bot goal\_setproperty role 1
##### snipe

This property automatically sets the weapon limits for the goal to sniper weapons. It does not need to be used if you used /bot goal\_create snipe.

**syntax:** /bot goal\_setproperty snipe
**example:** /bot goal\_setproperty snipe
##### weapon

Camp goals can be weapon limited. This means that only bots that have a specific weapon or weapons will be able to use them. Any camp goal that is weapon limited automatically gets a higher priority than camp goals without a weapon limit.

**syntax:** /bot goal\_setproperty weapon <weapon name>
**example:** /bot goal\_setproperty weapon panzerfaust
**note:** for a list of valid weapon names, issue the command without any parameters or an invalid one.
##### radius

Set the radius for the goal.

**syntax:** /bot goal\_setproperty radius <int>
**example:** /bot goal\_setproperty radius 64
### MobileMg42

MobileMg42 goals are the same as the other basic camp goal types with the following exceptions:
* Weapon property cannot be set
* Stance property cannot be set
* Multiple facings cannot be set