Raised This Month: $12 Target: $400
 3% 

Trigger game end


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Arkarr
Veteran Member
Join Date: Sep 2012
Location: Just behind my PC screen
Old 04-17-2015 , 05:23   Trigger game end
Reply With Quote #1

How can we trigger the game end (for all games) ? There isn't a proper way to do it ? I was thinking about setting the game time to 00:01 but that's kinda bad...
__________________
Want to check my plugins ?
Arkarr is offline
Arkarr
Veteran Member
Join Date: Sep 2012
Location: Just behind my PC screen
Old 04-17-2015 , 07:38   Re: Trigger game end
Reply With Quote #2

Simple as that :
PHP Code:
int game_end FindEntityByClassname(-1"game_end");
    if (
game_end == -1) {
        
game_end CreateEntityByName("game_end");
        if (
game_end == -1) {
            
ThrowError("Unable to find or create entity \"game_end\"");
        }
    }

    
AcceptEntityInput(game_end"EndGame"); 
EDIT: Doesn't work in Insurgency !
__________________
Want to check my plugins ?

Last edited by Arkarr; 04-17-2015 at 09:05.
Arkarr 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 18:13.


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