In many games the player can push and/or pull Objects like barrels, crates etc. If you are making a campaign mission in your map and want to add some variety you can use this little neat trick which makes at least pushing possible. It works fine (Except of animations which can't be added and pulling also doesn't work, but I am happy pushing Objects work fine).
You can use this method in several things like: "Go and push this box to this location to be able to jump through that hole (which is 3-4 meters above the floor in a wall)". To push objects just walk/run against your Object into any certain direction.
Maybe one day we will see a Vehicle Football or Soccer Match using tanks and walkers to push ball geometries into goals/fields...Just a thought...
Ok let's get started:
1.) First create your Object. You can also use any other assets/.msh's. Only the Object matters at all.
Here's a sample odf without any special things. Just the Geometry names:
Hidden/Spoiler:
Rename ClassLabel = "prop" into:
Code: Select all
ClassLabel = "droid"
Now if you want to remove any bitmaps from your minimap add this below [Properties]
Code: Select all
MapTexture = ""
MapScale = "0.0"
Code: Select all
MaxHealth = "1e+37"
1e+37 means a One with 37 zeros. To make it destructable just give it a Health of ~2000 (It's up to you).
If you want to make it respawn-able just add this line:
Code: Select all
RespawnTime = "180.0"
Code: Select all
AINoRepair = "1"
Code: Select all
Acceleraton = 0.0
MaxSpeed = 0.0
MaxStrafeSpeed = 0.0
MaxTurnSpeed = 0.0
PCMaxTurnSpeed = 0.0
PCMaxStrafeSpeed = 0.0
Code: Select all
IsAcklay = 1
Code: Select all
SetMemoryPoolSize("AcklayData", 20)
Some examples for anyone who's interested in making a mod using this method:
-As mentioned before a Soccer of Football match with vehicles might be fun
-For puzzle based maps/levels.
-For pushable covers. You push against a wall and it will work as a cover.
-As traps...
BUGS:
I just discovered this on yesterday and still need to figure out how to make better collisions.
For example you can move your camera (Using your mouse) through your Object. I added a collision and named it p_-svbot-cube and added these lines into my odf:
Hidden/Spoiler:
EDIT: Here's my odf (unchanged) using this method for comparison:
Hidden/Spoiler: