Raised This Month: $ Target: $400
 0% 

Hamsandwich Forward, Return values


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
t3hNox
Senior Member
Join Date: Oct 2009
Old 06-14-2010 , 13:32   Re: Hamsandwich Forward, Return values
Reply With Quote #1

Unfortunately, no success.
The function now looks like this:
PHP Code:
public fwButtonUsed(idcaller) {
    if(
IsFreeRun == true && cs_get_user_team(idcaller) == CS_TEAM_T) {
        return 
HAM_SUPERCEDE;
    }
    if(
IsFreeRun == true && cs_get_user_team(idcaller) == CS_TEAM_CT) {
        return 
HAM_IGNORED
    }
    return 
HAM_IGNORED

(Yes, the second IF is probably not needed)
Server's console returns this error (although, the plugin completes fine) :
Code:
L 06/14/2010 - 20:22:17: [AMXX]    [0] sample.sma::fwButtonUsed (line 79)
L 06/14/2010 - 20:22:17: [CSTRIKE] Player out of range (97)
L 06/14/2010 - 20:22:17: [AMXX] Displaying debug trace (plugin "sample.amxx")
L 06/14/2010 - 20:22:17: [AMXX] Run time error 10: native error (native "cs_get_
user_team")
The 79th line is:
PHP Code:
    if(IsFreeRun == true && cs_get_user_team(idcaller) == CS_TEAM_T) { 
I guess I don't use cs_get_user_team properly ?
t3hNox 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 14:56.


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