Raised This Month: $ Target: $400
 0% 

Map time TF2


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
TsooJ
Member
Join Date: May 2012
Old 06-16-2012 , 19:22   Map time TF2
Reply With Quote #1

There should be a plugin changing the map time of payload maps.

For example:

I play pl_hoodoo_final alot. Is there a way to start the match with 10 minutes instead of 5 and add 10 minutes instead of 5 when capturing the first controll point???

I am aware of the plugin (add time) but that one hasn't got any timers in it.

Any suggestions?
TsooJ is offline
TsooJ
Member
Join Date: May 2012
Old 06-19-2012 , 05:12   Re: Map time TF2
Reply With Quote #2

No1??
TsooJ is offline
EGood
Member
Join Date: Feb 2011
Location: Israel
Old 06-19-2012 , 22:02   Re: Map time TF2
Reply With Quote #3

http://forums.alliedmods.net/showthread.php?t=174615
Help You ?
EGood is offline
TsooJ
Member
Join Date: May 2012
Old 06-20-2012 , 02:50   Re: Map time TF2
Reply With Quote #4

No not realy.

First, I want to CHANGE the map time.
Second, This is for counterstrike source..

Thank you. ;)
TsooJ is offline
Bacardi
Veteran Member
Join Date: Jan 2010
Location: mom's basement
Old 06-20-2012 , 04:51   Re: Map time TF2
Reply With Quote #5

You want change round time, not map time.

Try this, I did quick.
Maybe not work on those map what have set max time lower than 10minutes.
*edit
I think this will affect also in other map mods than CapturePoint. You do those changes...
PHP Code:
#include <sourcemod>
#include <sdktools>

public OnPluginStart()
{
    
HookEventEx("teamplay_setup_finished"teamplay_event);
    
HookEventEx("teamplay_point_captured"teamplay_event);
}

public 
teamplay_event(Handle:event, const String:name[], bool:dontBroadcast)
{
    if(
StrEqual(name"teamplay_point_captured"))
    {
        if( 
GetEventInt(event"cp") > // When they have pass first capture point already
        
{
            return;
        }
    }

    new 
ent FindEntityByClassname(MaxClients+1"team_round_timer");
    if(
ent != -1)
    {
        
CreateTimer(1.0Timer_SetTimeentTIMER_FLAG_NO_MAPCHANGE);
    }
}

public 
Action:Timer_SetTime(Handle:timerany:ent)
{
    
SetVariantInt(600); // 600 sec ~ 10min
    
AcceptEntityInput(ent"SetTime");


Last edited by Bacardi; 06-20-2012 at 04:53.
Bacardi is offline
TsooJ
Member
Join Date: May 2012
Old 06-20-2012 , 11:09   Re: Map time TF2
Reply With Quote #6

Thank you ,

Try this out tonight ;)
TsooJ is offline
TsooJ
Member
Join Date: May 2012
Old 06-21-2012 , 07:15   Re: Map time TF2
Reply With Quote #7

Hmm this didn't work out.

First he adds 9 minutes but after capturing a point he won't add more time than 9 minutes so he adds like 3:43 minutes.
TsooJ is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 06-21-2012 , 09:29   Re: Map time TF2
Reply With Quote #8

Quote:
Originally Posted by TsooJ View Post
Hmm this didn't work out.

First he adds 9 minutes but after capturing a point he won't add more time than 9 minutes so he adds like 3:43 minutes.
SetTime changes the timer to exactly 10 minutes rather than adding 10 minutes. If you want to add an extra 5 minutes on top of the 5 it adds, change this:

PHP Code:
SetVariantInt(600); // 600 sec ~ 10min
AcceptEntityInput(ent"SetTime"); 
to this:
PHP Code:
SetVariantInt(300); // 300 sec ~ 5min
AcceptEntityInput(ent"AddTime"); 
__________________
Not currently working on SourceMod plugin development.

Last edited by Powerlord; 06-21-2012 at 09:29.
Powerlord is offline
Bacardi
Veteran Member
Join Date: Jan 2010
Location: mom's basement
Old 06-21-2012 , 09:59   Re: Map time TF2
Reply With Quote #9

I misread "add" time when first capture. Chage what @Powerlord mention.
something like this


9min 59sec is not same as 9min however...
Bacardi is offline
TsooJ
Member
Join Date: May 2012
Old 06-21-2012 , 14:15   Re: Map time TF2
Reply With Quote #10

The script works but for some stupit reason the time in PL maps wont go any further than 9 minutes ?
TsooJ is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:13.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode