Difference between revisions of "Arc"

From BZFlagWiki
Jump to: navigation, search
m (format)
(Changed parameters to property list)
Line 24: Line 24:
 
|}
 
|}
 
Valid parameters for an [[arc]] are
 
Valid parameters for an [[arc]] are
*'''name''': defines the name of arc, often unused  
+
==Code==
*'''divisions''': defines the number of subdivisions in the arc
+
To place an arc into your map file, the following template is suggested:
*'''flatshading''': defines the use of flat shading, smooth is the default
+
{|
*'''angle''': defines the sweep of the arc, 360 indicates a full circle
+
|
*'''ratio''': defines the ratio to make a hollow arc, the parameter is (outrad - inrad) / outrad.
+
arc
*'''position''': defines the position of the arc in X-pos, Y-pos and the height of the arc in Z.
+
  name example_arc
*'''rotation''': defines a rotation around the Z axis for the arc, in degrees.
+
  divisions 16
*'''size''': defines the distance from the center to the side of the arc in X and Y, and the total height of the arc in Z.
+
  flatshading
*'''shift''': shift the arc (repeatable)
+
  angle 360
*'''shear''': (repeatable)
+
  ratio 1
*'''scale''': defines the scale of the arc in x,y, and z, 1 is the default, lower values make it smaller (repeatable)
+
  position 0 0 0
*'''spin angle''': rotate the arc around a vector by angle. ONE of nx, ny, and nz should be 1, the others should be 0. (repeatable)
+
  rotation 0
*'''phydrv''': reference to a predefined [[physics|physics driver]].
+
  size 10 10 10
*'''smoothbounce''': defines that shot bounces use normals
+
  shift 0 0 0
*'''matref''': reference to a predefined [[material]].
+
  shear 0 0 0
 +
  scale 1 1 1
 +
  spin angle nx ny nz
 +
  phydrv physics_driver_name
 +
  smoothbounce
 +
  matref material
 +
end
 +
|}
 +
Valid parameters for an [[arc]] are
 +
<properties>
 +
name=defines the name of arc, often unused  
 +
divisions=defines the number of subdivisions in the arc
 +
flatshading=defines the use of flat shading, smooth is the default
 +
angle=defines the sweep of the arc, 360 indicates a full circle
 +
ratio=defines the ratio to make a hollow arc, the parameter is (outrad - inrad) / outrad.
 +
position=defines the position of the arc in X-pos, Y-pos and the height of the arc in Z.
 +
rotation=defines a rotation around the Z axis for the arc, in degrees.
 +
size=defines the distance from the center to the side of the arc in X and Y, and the total height of the arc in Z.
 +
shift=shift the arc (repeatable)
 +
shear=(repeatable)
 +
scale=defines the scale of the arc in x,y, and z, 1 is the default, lower values make it smaller (repeatable)
 +
spin angle=rotate the arc around a vector by angle. ONE of nx, ny, and nz should be 1, the others should be 0. (repeatable)
 +
phydrv=reference to a predefined [[physics|physics driver]].
 +
smoothbounce=defines that shot bounces use normals
 +
matref=reference to a predefined [[material]].
 +
</properties>
  
 
==Appearance==
 
==Appearance==

Revision as of 19:42, 16 April 2007

The arc object is a BZW object that defines an arc or cylinder in the game arena.

Code

To place an arc into your map file, the following template is suggested:

arc
 name example_arc
 divisions 16
 flatshading
 angle 360
 ratio 1
 position 0 0 0
 rotation 0
 size 10 10 10
 shift 0 0 0
 shear 0 0 0
 scale 1 1 1
 spin angle nx ny nz
 phydrv physics_driver_name
 smoothbounce
 matref material
end

Valid parameters for an arc are

Code

To place an arc into your map file, the following template is suggested:

arc
 name example_arc
 divisions 16
 flatshading
 angle 360
 ratio 1
 position 0 0 0
 rotation 0
 size 10 10 10
 shift 0 0 0
 shear 0 0 0
 scale 1 1 1
 spin angle nx ny nz
 phydrv physics_driver_name
 smoothbounce
 matref material
end

Valid parameters for an arc are

name defines the name of arc, often unused
divisions defines the number of subdivisions in the arc
flatshading defines the use of flat shading, smooth is the default
angle defines the sweep of the arc, 360 indicates a full circle
ratio defines the ratio to make a hollow arc, the parameter is (outrad - inrad) / outrad.
position defines the position of the arc in X-pos, Y-pos and the height of the arc in Z.
rotation defines a rotation around the Z axis for the arc, in degrees.
size defines the distance from the center to the side of the arc in X and Y, and the total height of the arc in Z.
shift shift the arc (repeatable)
shear (repeatable)
scale defines the scale of the arc in x,y, and z, 1 is the default, lower values make it smaller (repeatable)
spin angle rotate the arc around a vector by angle. ONE of nx, ny, and nz should be 1, the others should be 0. (repeatable)
phydrv reference to a predefined physics driver.
smoothbounce defines that shot bounces use normals
matref reference to a predefined material.


Appearance

The arc, by default, has the red brick wall texture on the sides, and the grey roofs of normal boxes on the top. However, using matref, one can change the appearance of the arc.

History

The arc object has been supported since BZFlag 2.0.0. In previous versions of BZFlag, this object will not work.

Editor Support

Editors that support the arc object include Blender using the BZWTools, Wings3D using the BZW Exporter for Wings3D, and pyBZEdit. BZEdit and BZFed do NOT support the arcs.