Dreamball:Creating Floating Platforms

From Valve Developer Community
Jump to: navigation, search

Floating platforms are the platforms with the 4 thrusters, you'll see these in the Dreamball's own maps. They are simply a func tracktrain with a few extra entities parented to them.

A floating platform.

Creating a platform

An automatic platform

This will be a platform that moves forward / backward forever, automatically. To build one, build your basic brush first. Tie it to a func tracktrain and name it platform_float1. Change the max speed to your desired speed, for example we'll use 70. Change your height above track to 1. You can use any moving sound, if any at all. For this example we'll use the one we use, objects/platform_hover_loop1.wav. Now check the flag Fixed Orientation.

Now place a path track in the centre of your platform_float1 brush - so the start of your platform is at the path1 point.. This will be point 1 for where it floats to. Name it path1 and put the Next Stop Target to path2. Change the Orientation Type to No change. That is for example, you can tinker with it more yourself.

Now in your path1 path_track, add these 2 outputs:

My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnPass platform_float1 Stop 0 0.00 No
Io11.png OnPass platform_float1 StartForward 0 2.50 No

This will give us the automatic movement. Add those same outputs to the path2 path_track. Now place a logic auto so we can make it auto start. Inside the logic_auto add this output:

My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnMapSpawn platform_float1 StartForward 0 0.00 No

That will now give us an automatic moving platform. It will move between path1 and path2 constantly. You can tinker more with it's values and effects, but this will give you the movement. Parent models or particles to the platform_float1 to give some nice effects. See "SDK/mapsrc/sdk_auto_platform_float.vmf" for an example of an automatic one.


An manual platform

A manual platform we'll create is one that will stay still until your roll onto it, then it will move. When you roll off it, it will stop and move back to the start platform. For this create a brush again and tie it to the func tracktrain and name it platform_float1. Now create a brush in the centre of the platform, make it so once you're fully rolled onto the platform you'll then hit the trigger automatically. This will be our 'StartForward' trigger. Tie this brush to a trigger multiple. Now parent it to your platform_float1. Add this output to your trigger_multiple:

My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnStartTouch platform_float1 StartForward 0 0.00 No

Now we'll create the path track's for it. Place a path track in the centre of your platform_float1 again. Name it path1. Add path1 to your platform_float1's First Stop Target. Place another path_track for your stop point (you can add more if you want, just follow the pattern) and name it path2. Add path2 to your path1's Next Stop Target. Now in path1 add this output:

My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnPass platform_float1 Stop 0 0.00 No

This is so our platform stays still on map start. Now we've got setup a platform_float1 that will move forward when you touch the trigger brush in it. Now we just add the 'exit' brush. Place a trigger brush widely over the path of your whole platform_float1 travel distance. Make it fairly large so you don't leave the trigger until you leave the platform. Now in this new trigger_multiple add this output:

My Output Target Entity Target Input Parameter Delay Only Once
Io11.png OnEndTouchAll platform_float1 StartBackward 0 0.00 No

Now when you leave the platform, you'll leave that trigger brush and then start the platform to move back to the start. See "SDK/mapsrc/sdk_manual_platform_float.vmf" for an example of an manual one.

It may seem a little confusing, but it's real easy. See the example maps for a perfect explanation. You're also free to use the platform_float prefabs we've supplied.

See also

  • func tracktrain and path track.
  • "Dreamball Dev Kit/SDK_content/mapsrc/sdk_auto_platform_float.vmf" - an example on automatic platforms.
  • "Dreamball Dev Kit/SDK_content/mapsrc/sdk_manual_platform_float.vmf" - an example on manual platforms.
  • "Dreamball Dev Kit/SDK_content/prefabs/platform_float.vmf" - a automatic platform floater already built for use
  • Dreamball Level Creation