-
Notifications
You must be signed in to change notification settings - Fork 46
Collisions
BEEmod adds a new system for specifying the shape of items more accurately, to allow objects to make decisions and avoid overlapping each other. Each collision volume is a axis aligned bounding box, which may optionally be flat on one axis to represent things like items on the side of a voxel. Volumes are always associated with a particular item, via the instance name.
A number of collision types can be specified, allowing ignoring specific kinds of collisions. For any specific volume, it may consist of multiple of these types.
-
SOLID
: General collisions, should be used for solid walls, props and the like that do not pass anything through. -
GRATE
/GRATING
: Grating blocks movement, but does not block "energy" effects. -
GLASS
: Glass blocks everything, except for line of sight and Discouragement Beams. -
BRIDGE
: The area of effect of a Light Bridge. -
FIZZLER
: The region occupied by an object destroying fizzler (meaning objects could be destroyed here). -
TEMPORARY
: Indicates a region which will only sometimes be solid. This should be used for the movement region of things like platforms and panels. -
DECORATION
/DECO
: Prohibits additional decoration from being placed in this area. -
ANTLINE
/ANTLINES
: Prohibits antlines from being placed in this area. -
EVERYTHING
: Shorthand for the combination of all other collision types.
Each volume may have any number of string 'tags' specified, to allow identifying volumes for later modification. The following is a list of tags the compiler may use:
-
generated
: Given to all volumes generated automatically fromOccupiedVoxel
definitions. -
movement
: The movement region of Piston Platforms and Track Platforms. -
field
: The actual fizzler field.
By default, collisions will be inferred from OccupiedVoxel
definitions, using the following collision type conversions:
-
COLLIDE_NOTHING
: Ignored. -
COLLIDE_SOLID
:SOLID
-
COLLIDE_GRATING
:GRATING
-
COLLIDE_GLASS
:GLASS
-
COLLIDE_BRIDGE
:BRIDGE
-
COLLIDE_FIZZLER
:FIZZLER
-
COLLIDE_PHYSICS
:TEMPORARY
+SOLID
-
COLLIDE_ANTLINES
:ANTLINE
-
COLLIDE_EVERYTHING
:EVERYTHING
If these are not accurate, you can replace these entirely by defining a Collisions
block in the Exporting
section, like so:
"Collisions"
{
"BBox"
{
"Type" "SOLID ANTLINE"
"Pos1" "-64 -64 -32"
"Pos2" "-32 64 -16"
}
"BBox"
{
"Type" "SOLID ANTLINE"
"tags" "a_tag"
"Pos1" "-32 -64 -32"
"Pos2" "64 64 -16"
}
"BBox"
{
"Type" "SOLID ANTLINE"
"tag" "tag one two three"
"Pos1" "-32 -64 -32"
"Pos2" "32 64 -16"
}
}
Tag
/Tags
are an optional space-separated list of tags to apply. For items which place multiple instances like Excursion Funnels and Track Platforms, the collisions are only added for the location of the "main" instance. For resizing items like platforms and fizzlers, these must be defined using conditions.