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

[L4D] Calling victory


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Mecha the Slag
Veteran Member
Join Date: Jun 2009
Location: Denmark
Old 11-03-2009 , 15:54   [L4D] Calling victory
Reply With Quote #1

Hi. I'm making a plugin for L4D versus, and I'm trying to find a way to call victory for the survivors. I've looked through

http://wiki.alliedmods.net/Left_4_Dead_Events

but I have little idea how to use them. I tried doing the following
PHP Code:
victory() {
    new 
Handle:event CreateEvent("finale_win")
    if (
event == INVALID_HANDLE)
    {
        
PrintToChatAll("Event is an invalid handle! GASP");
        return
    }
 
    new 
String:GameDifficulty[256];
    new 
String:GameMap[256];
    
GetConVarString(FindConVar("z_difficulty"), GameDifficultysizeof(GameDifficulty));
    
GetCurrentMap(GameMapsizeof(GameMap));
 
    
SetEventString(event"map_name"GameMap)
    
SetEventString(event"difficulty"GameDifficulty)
    
FireEvent(event)
    
PrintToChatAll("Event successfully fired!");


and it's being called correctly, but it doesn't actually start the victory screen or anything (only gave me an achievement fff)

Any help appreciated.
Mecha the Slag is offline
 



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 09:10.


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