AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   TFC Flag Capture (https://forums.alliedmods.net/showthread.php?t=51483)

FormulaZero 02-18-2007 17:35

TFC Flag Capture
 
Hello, I've been working on a plugin that does this: When a user from a team captures the flag there team gets +20 health and +3 speed. When the user picks the flag up he gets +5 health, I havn't gotten far yet but I'm stuck and can't call the flag capture function does anybody mind helping? I'm trying to make it so when a player captures the flag there team gets +20 health and +3 speed, just get me that far please, I think I can play out the rest:

PHP Code:

#include <amxmodx>
#include <amxmisc>
#include <tfcx>
#include <fun>

#define PLUGIN "TFC Flag Bonus"
#define VERSION "1.0"
#define AUTHOR "FormulaZero"

new cbonus

public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
register_event("TeamScore","capflag","be")
    
    new 
Cvar[] = "amx_capbonus"
    
register_cvar(Cvar"1")
    
cbonus get_cvar_pointer(Cvar)
}

public 
capflag(id)
{
    if(!
is_user_alive(id))
        return
    if(
tfc_get_user_goalitem(1,1)(id) < 



All times are GMT -4. The time now is 07:56.

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