Dreamball:Orb Hunt
Introduction
Creating an Orb Hunt map is done in a similar style to Tic-Toc Race, not from new custom entities, but existing ones, just used in a certain way. This tutorial will cover the basic construction of it. This tutorial will cover creating a simple 1 orb map, to create the extra orbs you just simply repeat the building process.
Construction
First let's create the orb effect. Place a env_sprite where your orb will be. Name it orb_sprite1. Set it's Sprite Name material to sprites/orb01.vmt
. Set it's scale to 1.5, and Size of Glow Proximity to 2.0 and lastly the Render Mode field to Additive. Check it's flag to Start On.
Now place an info_particle_system. Name it orb_destroy1 and set it's particle effect name to orb01
. Set it's Start Active field to No. Place another info_particle_system and name it orb_destroy1_warp
. Set it's particle effect name to warp_explosion1
. And Start Disabled flag to to Yes.
Place a game_text entity and name it got1
. Set the Message text to '1/1 Orbs collected'. And tinker with it's text colour, speed etc as desired.
Now place an env_screenoverlay entity. Name it 1orb
. Set overlay name to overlays/orbs/1orb
. make sure the Overlay Duration fields are set to 0 seconds.
Now place an ambient_generic entitiy. Set it's sound to ambient/levels/labs/electric_explosion4.wav
. Name this entity orb_explode_snd
Create a small trigger_once brush over the orb sprite. Shaped around it, so it looks like you hit the orb when hitting the trigger. Name the trigger orb_trig1
. Now in it's outputs tab add these:
Now that's the Orb effect set up. Place a math_counter entity and name it orb_math
. With it's following fields done:
- Start Disabled: No
- Initial Value: 0
- Minimum Legal Value: 0
- Maximum Legal Value: 1 (or more if you are using more orbs)
We'll add the outputs for the orb_math in after the next bit.
place a logic_case entity and name it Orb_score_case
. In it's field named Case 01 add 1. (add the rest for Case_02 - 2, o3 - 3 and so on, for more orbs.) Now in this entity add these outputs:
My Output > Target Entity Target Input Parameter Delay Only Once OnCase01 got1 Display None 0.00 No OnCase01 1orb StartOverlays None 0.00 No OnCase02 1orb StopOverlays None 0.00 No
Although this tutorial is for 1 orb, we'll still add the OnCase02, StopOverlays, assuming your doing more. You always need to stop the old overlay when calling a new one.
Now back to that orb_trig1 brush, add thise output:
My Output > Target Entity Target Input Parameter Delay Only Once OnStartTouch orb_math Add 1 0.00 No
Now open the orb_math entity and add thise output:
My Output > Target Entity Target Input Parameter Delay Only Once OutValue Orb_score_case InValue None 0.00 No
Conclusion
That is the base of the game mode done, you should have 1 orb ready for hunting! As you can see, you just repeat the process to get more orbs. there are a few more things to be done, to give it more realism, but they will not be explained here as they are done in your own favour. Here's an overview:
- Create trigger brushes under the map, for when the ball falls off, and restarts the map via cvar.
- env_fade to fade the screen on end map
- See the db_orb1.vmf example in the dreamball/mapsrc folder for more detail