Raised This Month: $ Target: $400
 0% 

API Scripting Help How to get human classes id?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
jonnzus
Epic Member
Join Date: Oct 2010
Location: Finland
Old 04-14-2013 , 07:57   How to get human classes id?
Reply With Quote #1

Hey, how can I get human classes id and use it like this?

PHP Code:
        if (zp_class_human_get_current(id) != hClassesid )
        {
            return 
PLUGIN_HANDLED;
        } 
__________________
Quote:
367. Everyone's copyright will be broken. No exceptions.
jonnzus is offline
artos
Senior Member
Join Date: Mar 2010
Old 04-14-2013 , 08:18   Re: How to get human classes id?
Reply With Quote #2

Like this:
PHP Code:
new class_name[32];
zp_class_human_get_name(zp_class_human_get_current(id), class_namecharsmax(class_name));

if (!
equal(class_name"Your class name"))
    return 
PLUGIN_CONTINUE
__________________

Last edited by artos; 04-14-2013 at 08:19.
artos is offline
Send a message via Skype™ to artos
jonnzus
Epic Member
Join Date: Oct 2010
Location: Finland
Old 04-19-2013 , 13:12   Re: How to get human classes id?
Reply With Quote #3

What's wrong with this?
http://pastebin.com/TAXXMJ22
i edited lines 133 - 141 + added includes.
compiler give this:
BuildDispenser.sma(36) : error 001: expected token: ";", but found "enum"
__________________
Quote:
367. Everyone's copyright will be broken. No exceptions.

Last edited by jonnzus; 04-19-2013 at 13:17.
jonnzus 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 16:14.


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