Keeping Red from winning, but letting them win?

Lord Ned

L420: High Member
Feb 11, 2008
421
174
That title sounds confusing. I agree. It is.

I'm trying to get it so that red owns all 8 control points at the start of the map.

After defending for say the first 5 minutes and blue doesn't capture anything, it goes to Red Wins!

If blue owns any of the points, it goes to Sudden Death.

If blue captures all of the points it does NOT end the game, but unlocks inteligence, and you can run that to your spawn. If the time runs out while the inteligence is being held it goes into overtime till it's captured/dropped and times out.

I cannot get this to work right. Can't get blue to NOT win and red to WIN. (Since I restricted red from winning, to prevent them from winning as soon as the game starts.)

What entities do I need to configure for this?
 

Foreverkul

L4: Comfortable Member
Apr 12, 2008
157
14
game_win or something, then activate it, it can be set for sudden death as well.
Just say that if the first point is owned by red, then activate red win game_win entity.
 

Lord Ned

L420: High Member
Feb 11, 2008
421
174
But the first point is owned by red at the start of the map. So I had to disable the Red team from winning to keep the match from being over at the start.

Also they can capture any of the first four points at the start, so that wouldn't work.
 

Lord Ned

L420: High Member
Feb 11, 2008
421
174
How do I keep it from letting them win then? Just set "Can Blu win?" and "Can Red win" to No? And then just check against all the CP's?

Also, is there an input for the SD to enable/disable it?
 

Foreverkul

L4: Comfortable Member
Apr 12, 2008
157
14
What you do is make a game_round_timer for the set amount of time
Then you add an output on that timer onFinished you check to see if any of the points have been captured.
For each cap make a logic_branch and then set it to change between 1 and 0 depending on who controls it (so use onTeam#Cap with SetValue of the respective branch entity)
The when the timer is onFinished, Test each branch. On each branch, you should have an onTrue (or onFalse) that will activate a sudden death.

If you don't understand I could make a test map for you to look at, but try and figure it out first.
 

Lord Ned

L420: High Member
Feb 11, 2008
421
174
I was thinking of adding a math_counter, and on Team#Cap add one. OnHit Max enables Sudden Death, and OnHitMin (0) Disables SD.

Blah, I CANNOT find where I specified which round could win. I can see in the team_control_point_master where I can set "Restrict Team from Winning" But my only options are: Neither/Red/Blu. No both. :S
 
Last edited:

Pseudo

L6: Sharp Member
Jan 26, 2008
319
150
If a team_control_point_master is set to start disabled, neither team will automatically win by capturing all of the control points.
 

Lord Ned

L420: High Member
Feb 11, 2008
421
174
I'm cursed. Map won't compile.

Code:
Brush 8499: File C:Program FilesSteamsteamappslordmatthoffmansourcesdk_contenttfmapsrccp_game_entities_2.vmf, line 8605: unexpected symbol '!'
Go to brush 8499, remake it. Re-compile. now it's a NEW brush with the same error.


Edit:
Sweet, now the map crashes hammer while loading! :/

Time to go modify my VMF.

Edit2:
Code:
		side
		{
			"id" "1413"
			"plane" "(3840 -4096 0) (3456 -4096 0) (3456 -4096 160)"
			"material" "TOOLS/TOOLSTRIGGER"
			"uaxis" "[-1 0 0 -32] 0.5"
			"vaxis" "[0 0 -1 0] 0.25"
			"rotation" "0"
			"lightmapscale" "16"
			"smoothing_groups" "0"
		}
Line 8605 is "id" "1413"


*shoots self*
 
Last edited:

Lord Ned

L420: High Member
Feb 11, 2008
421
174
Ba dum pish.

Were all winners right now. Now I just need to set up my logic's to allow red to win. :c
 
Last edited:

Lord Ned

L420: High Member
Feb 11, 2008
421
174
Hmmn. Can we check the status of a math_counter after the 5 minutes? So we can have the math_counter enable SD when 1 or more CP's are owned, and have it Disable SD when none are owned? (OnHitMax, OnHitMin)

Edit:
This also poses a problem if they try to capture while the time is running out.

That's it. I'm recursed. Getting the same errror. Wonder if the Valve SDK Map has a terminal error that developes later on in it's life. :/

Code:
** Executing...
** Command: "c:program filessteamsteamappslordmatthoffmansourcesdkbinorangeboxbinvbsp.exe"
** Parameters: -game "c:program filessteamsteamappslordmatthoffmanteam fortress 2tf" "C:Program FilesSteamsteamappslordmatthoffmansourcesdk_contenttfmapsrccp_onslaught_rc_2"

Valve Software - vbsp.exe (Mar 11 2008)
2 threads
materialPath: c:program filessteamsteamappslordmatthoffmanteam fortress 2tfmaterials
Loading C:Program FilesSteamsteamappslordmatthoffmansourcesdk_contenttfmapsrccp_onslaught_rc_2.vmf
Brush 139: File C:Program FilesSteamsteamappslordmatthoffmansourcesdk_contenttfmapsrccp_onslaught_rc_2.vmf, line 2897: unexpected symbol ','
Side 5
Texture: TOOLS/TOOLSTRIGGER


** Executing...
** Command: Copy File
** Parameters: "C:Program FilesSteamsteamappslordmatthoffmansourcesdk_contenttfmapsrccp_onslaught_rc_2.bsp" "c:program filessteamsteamappslordmatthoffmanteam fortress 2tfmapscp_onslaught_rc_2.bsp"

The command failed. Windows reported the error:
  "The system cannot find the file specified."
 
Last edited: