Raised This Month: $ Target: $400
 0% 

register touch


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Miko000000
Senior Member
Join Date: Jul 2008
Location: Slovakia
Old 02-04-2009 , 11:27   Re: register touch
Reply With Quote #8

I do this

Code:
public hook_touch(ptr,id)
{
    if(get_pcvar_num(p_enable) && is_user_alive(id))
    {
    static szClassName[32]
    pev(ptr, pev_classname, szClassName, sizeof szClassName - 1)
  
    if(!equal(szClassName, "YOUR_CLASSNAME"))
    return FMRES_IGNORED
    
    if(!get_pcvar_num(mines_enabled))
        return
    
    if(!is_user_alive(id))
        return
    
    explode(ent, 0)
    
    }
    return FMRES_IGNORED
}
sorry i dont know what is classname
and there is messange

Code:
Welcome to the AMX Mod X 1.8.1-300 Compiler.
Copyright (c) 1997-2006 ITB CompuPhase, AMX Mod X Team

Error: Undefined symbol "p_enable" on line 4156
Warning: Function "hook_touch" should return a value on line 4167
Warning: Function "hook_touch" should return a value on line 4170
Error: Undefined symbol "ent" on line 4170
Warning: Expression has no effect on line 4170
Error: Expected token: ";", but found ")" on line 4170
Error: Invalid expression, assumed zero on line 4170
Error: Too many error messages on one line on line 4170

Compilation aborted.
5 Errors.
Could not locate output file C:\pluginy\MZ\hns.amx (compile failed).

Last edited by Miko000000; 02-04-2009 at 11:31.
Miko000000 is offline
Send a message via ICQ to Miko000000 Send a message via Skype™ to Miko000000
 



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 01:38.


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