This wiki is archived and useful information is being migrated to the main bzflag.org website

Difference between revisions of "Weapon (object)"

From BZFlagWiki
Jump to: navigation, search
m (Code)
(Changed parameters to property list)
Line 19: Line 19:
 
|}
 
|}
 
Valid parameters for a weapon object are:
 
Valid parameters for a weapon object are:
*'''name''' : the name of the weapon, generally unused.
+
<properties>
*'''position ''' : the position in world units for the effect to begin at
+
name=the name of the weapon, generally unused.
*'''rotation ''' : the orientation in degrees for the effect to fire in.
+
position =the position in world units for the effect to begin at
*'''color ''' : the color the weapon should be.
+
rotation =the orientation in degrees for the effect to fire in.
*'''tilt ''' : the vertical tilt in degrees for the effect to fire in.
+
color =the color the weapon should be.
*'''initdelay ''' : the delay to wait after the server starts before the effect is triggered.
+
tilt =the vertical tilt in degrees for the effect to fire in.
*'''delay ''' : a list of delays to loop through after the startup delay.
+
initdelay =the delay to wait after the server starts before the effect is triggered.
*'''type ''' :  the [[FlagCode]] for the flag effect to use for the weapon.
+
delay =a list of delays to loop through after the startup delay.
*'''trigger ''' : if a delay is not used, when to trigger the flag, currently only flagcap is valid.
+
type = the [[FlagCode]] for the flag effect to use for the weapon.
*'''eventteam ''' : the team to use when looking at flagcap weapons.
+
trigger =if a delay is not used, when to trigger the flag, currently only flagcap is valid.
 
+
eventteam =the team to use when looking at flagcap weapons.
 +
</properties>
 
The weapon object can be used as many times as desired on a map.
 
The weapon object can be used as many times as desired on a map.
  

Revision as of 20:14, 16 April 2007

A weapon object is a BZW map structure that defines a fixed weapon effect. This is also called a world weapon.

Code

The code for a weapon object is as follows

weapon
 name example_weapon
 position 0.0 0.0 0.0
 rotation 0.0
 color 0
 tilt 0.0
 initdelay 10.0
 delay 10.0 3.0 5.0 3.0
 type V 
 trigger flagcap
 eventteam R
end

Valid parameters for a weapon object are:

name the name of the weapon, generally unused.
position the position in world units for the effect to begin at
rotation the orientation in degrees for the effect to fire in.
color the color the weapon should be.
tilt the vertical tilt in degrees for the effect to fire in.
initdelay the delay to wait after the server starts before the effect is triggered.
delay a list of delays to loop through after the startup delay.
type the FlagCode for the flag effect to use for the weapon.
trigger if a delay is not used, when to trigger the flag, currently only flagcap is valid.
eventteam the team to use when looking at flagcap weapons.

The weapon object can be used as many times as desired on a map.

Appearance

The weapon object will produce a weapon effect that is exactly the same as similar effects produced by players.

History

The weapon object was added in v2.0.0.

Editor Support

The weapon object is only fully supported by the BZWTools blender plug-in.