[INFO] Playload entity setup.

Spacemonkeynz

L5: Dapper Member
Jan 31, 2008
234
52
[INFO] Payload entity setup.

I'm currently updating my es_cave map with the payload setup. Once i've done that i'll write a proper tutorial. But for the moment i'll list the important entities and the important options and outputs.

It's still incomplete, feel free to post any additions and i'll add it to the list.

func_tracktrain
A square brush entity using the playerclip texture, everything that moves with the cart is parented to this entity.


Properties
(you have to add these 3 keys yourself)
ManualAccelSpeed - 70
ManualDecelSpeed - 150
ManualSpeedChanges - 1

MaxSpeed - 90
First Stop Target - (the first path_track)
Distance Between the Wheels - 20

Move Sound - Cart.Roll
Start Sound - Cart.RollStart
Stop Sound - Cart.RollStop


path_track
The path that the train follows

prop_dynamic - Parented to the func_tracktrain
A model to be used for the train (goldrush uses a prop_physics_override, because at the end of the map the cart falls into the pit, however for most cases a prop_dynamic should work fine)

trigger_capture_area - Parented to the func_tracktrain
The capture area for the cart, friendly players in this area will move the cart, enemy players will stop the cart from moving.
Should be sized to a decent size around the cart.

Outputs
OnNumCappersChanged - math_remap - InValue
OnNumCappersChanged - team_train_watcher - SetNumTrainCappers

math_remap
Set the maximum amount of people that can move the cart to 3, you can change this if you want the cart to be moved by more or less players.

Properties
Maximum Value Input Value - 3
Output Value When Input is Max - 3

Outputs
OutValue - logic_case - InValue

logic_case
Used for deciding how fast the train should go depending on the number of people around it.

Properties
Case 01 - 0
Case 02 - 1
Case 03 - 2
Case 04 - 3

Outputs
OnCase01 - func_tracktrain - SetSpeedDirAccel - 0
OnCase02 - func_tracktrain - SetSpeedDirAccel - 0.55
OnCase03 - func_tracktrain - SetSpeedDirAccel - 0.77
OnCase04 - func_tracktrain - SetSpeedDirAccel - 1.0

team_train_watcher
Used for displaying info on the hud and linking PathTracks to ControlPoints
You need one of these for each round

Properties
Train to watch - (name of the func_tracktrain)
Node that the path starts at - (the first path_track)
Node that the path ends at - (the last path_track)

Linked PathTrack 1 - (the path_track that linked to CP 1)
Linked CP 1 - (the CP)
(repeat for each CP on the tracks)

Outputs
OnTrainStartRecede - func_tracktrain - SetSpeedDirAccel - -0.1
(makes the train move backwards)

mapobj_cart_dispenser - Parented to the func_tracktrain
The healing thing which heals you (excuse the technical language), in goldrush it's placed in the exhaust of the cart, and the healing ray comes out of it.

Properties
Team - Blue (to heal Blue)
Custom Touch Trigger - dispenser_touch_trigger

dispenser_touch_trigger - Parented to the func_tracktrain
A brush entity the same shape as the 'trigger_capture_area', players in this area will be healed and have their ammo restocked.

Control point setup
------------------------
Much like dustbowl, a 'team_control_point_round' for each mini-round,
and a 'team_control_point_master', as well as a 'team_control_point' for each CP.


team_control_point
One for each checkpoint, including one for the end (you can set it's flag to invisible, in case you want a pit or something for the cart to fall into like at the end of goldrush)

Properties
Name - (unique name for each CP)
Print Name - (The name that will show up in the top left when a point is captured, eg in gravelpit, "Spacemonkey captured the Radar")
Default Owner - Red (maps starts with red owning all the CP's)

Warning Type - No Announcements (Important: I made a mistake with my first version of cave where I left this on, and what happen is every time Blu could come into contact with the cart, (which was a lot), Red would hear the announcement that their Control Point is being captured. A few other pl maps have this problem, so I thought i'd point it out.)

Outputs
OnCapTeam2 - trigger_capture_area - SetControlPoint - (the next control point on the path) - Delay 0.1 (The delay is important, otherwise without a delay, the next CP will be captured when the current point is capped.)

For the path_track linked to each Control Point
i.e, when the cart reaches this path_track, the point will be capped, and at cart can not roll back beyond this path_track

Outputs
OnPass - logic_relay - Trigger - Only Once: Yes (A relay to fire when the cart passes the first time)
OnPass - (the linked team_control_point) - SetOwner - 3 (for Blue) - (Set's the owner of the CP to Blu)
OnPass - (the previous path_track) - DisablePath (Disables the previous path_tack to prevent the cart going any further back.
OnPass - logic_relay - Trigger - Only Once: No (A relay to fire when the cart passes backwards, used to stop the sparks and the cart (if you have any))

team_control_point_round
Have one for each round

Properties
Control points this round - (the names of the CP's, separated by spaces
Restrict team from winning - Red

team_control_point_master
Restrict team from winning - Red
Switch teams on map win? - Yes
 
Last edited:
Dec 25, 2007
566
439
Note that mapobj_cart_dispenser also restocks ammo. Basically it's a dispenser without its own model.
 

Demitri Omni

L2: Junior Member
Apr 18, 2008
53
3
Somehow, upon setting everything up in a test map, the map immediately crashes when a blue team member enters the capture zone.
 

Spacemonkeynz

L5: Dapper Member
Jan 31, 2008
234
52
Somehow, upon setting everything up in a test map, the map immediately crashes when a blue team member enters the capture zone.

Yes, I got that as well, turns out I was missing something (but I forget what).

Do you have the control points set up yet?

I think that is a requirement, as without them, the 'team_train_watcher' doesn't know what to display and crashes the game.

That's just a guess though.
 

trainRiderJ

L5: Dapper Member
Mar 14, 2008
203
31
Has anyone experienced the goldrush bug where you get a ton of captures just by continually coming in contact with the cart?

I was wondering if that bug carries over to this payload entity system?
 
Feb 14, 2008
1,051
931
Is that a bug or is that meant to happen?

(I don't want it to be a bug, got 50 points without dying today, 40 were captures)
 

trainRiderJ

L5: Dapper Member
Mar 14, 2008
203
31
I find it hard to believe that me getting 9 "captures" in one stage of goldrush as a soldier was intended to happen. I've also seen reports of people on red team getting credit for captures.
 

Spacemonkeynz

L5: Dapper Member
Jan 31, 2008
234
52
It's the intending scoring system, which can be modified in the map.

You get points for partial caps, hence all the points. This can be reduced or turned off though.
 

TotalMark

L6: Sharp Member
Feb 13, 2008
331
78
I've been following this, and anytime I try to test my map, the whole game crashes!!!

Am I missing something?

EDIT: I fixed it, I was using a trigger multiple instead of the dispenser_touch_trigger.
 
Last edited:

AtionSong

L1: Registered
Feb 17, 2008
6
0
I'm having trouble setting up the control point. I set up a test-map with just one control point to make sure I can get the entities right. I set the once control point to red ownership initially, and then whenever I launch the map, it says that red has won (since red owns the only control point). Where's my issue?
 

Spacemonkeynz

L5: Dapper Member
Jan 31, 2008
234
52
Also, I think there is a property either in the team_control_point_round, or the team_control_point_master', which says "restrict team from winning".

You should set that to Red, so Red will not win when it owns all the CP's (i.e at the start of the game).
 

Ida

deer
aa
Jan 6, 2008
2,289
1,372
This is extremely helpful, but there's something wrong with my map...

I did everything as it said in the guide (but I picked Red where you told me to pick Blue, and vice versa, because I'm trying to make a map where RED attacks...), but somehow I think I missed something. My cart is simply one big dispenser that sits halfway down into the ground. No, it does not say "Dispenser built by" when I point at it, but it does make the default idle dispenser sound that you can hear from a dispenser that isn't in use (I set the cart sounds to what the guide said), and it gives me ammo and health. It just won't move, that's all... (Also, it points east, when my track goes to the north)
 

Butter

L1: Registered
May 11, 2008
13
0
The SetNumTRainCappers doesn't excist in the default command list does it ? :s I dont have it anyway..

Can someone upload a working prefab or example map (simple) with a working payload? Can't get mine to work at all.
 

Butter

L1: Registered
May 11, 2008
13
0
I hate this part of the tutorial from valve:

'The end point is set up in exactly the same way as a mid point, the only difference is what you want to do with it.

* The main difference is you will need to disable the Bomb_CapArea and anything else appropriate to your map, you can use the logic_relay and the end point to disable them. '

So how do I do this then? I'm no scripting wonder...

Next to that.. why is it that the cap area around the train does move with it.. but the dispenser area doesn't.. while they have the same parent.. it's so annoying.
 
Last edited:

Spacemonkeynz

L5: Dapper Member
Jan 31, 2008
234
52
I hate this part of the tutorial from valve:

'The end point is set up in exactly the same way as a mid point, the only difference is what you want to do with it.

* The main difference is you will need to disable the Bomb_CapArea and anything else appropriate to your map, you can use the logic_relay and the end point to disable them. '

So how do I do this then? I'm no scripting wonder...

Next to that.. why is it that the cap area around the train does move with it.. but the dispenser area doesn't.. while they have the same parent.. it's so annoying.

The tutorial is not from valve, it's made by a user, and imo he did a pretty good job.

Payload relies on the input and output system more so then the other game modes, you so have to make sure you understand it well.

You can disable the 'Bomb_CapArea' with input 'disable'
You can fire this from a logic_relay, the path_track, or the Control Point, up to you, but using a logic_relay keeps things tidy.

Basicly once the train reaches the last path_track, have the path_track send the 'OnPass' output to the logic_relay with an input of 'trigger', then have the logic_relay send outputs to whatever you want to (like the 'Bomb_CapArea')