Raised This Month: $149 Target: $400
 37% 

problem with fm_cs_get_user_team


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Mankled
Senior Member
Join Date: Oct 2019
Old 12-09-2020 , 00:06   problem with fm_cs_get_user_team
Reply With Quote #1

im getting this error from my main zp plugin

Code:
L 12/06/2020 - 06:12:12: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/06/2020 - 06:12:12: [AMXX] Run time error 10: native error (native "get_pdata_int")
L 12/06/2020 - 06:12:12: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13097)
L 12/06/2020 - 06:12:12: [AMXX]    [1] zombie_plague.sma::clcmd_changeteam (line 3537)
line 13097
Code:
stock fm_cs_get_user_team(id)                                                         13095
{                                                                                                     13096
return get_pdata_int(id, OFFSET_CSTEAMS, OFFSET_LINUX);              13097
}
line 3537
Code:
static team                                           3536
team = fm_cs_get_user_team(id)          3537
this is what i tried to do to fix it
https://forums.alliedmods.net/showthread.php?t=149797

after I did this above. players in my server are having a problem to select their team. when they connect to the server, they are no able to select a team and they stay as spectator. even if they press M to choose a team they cant spawn.
Mankled is offline
Mankled
Senior Member
Join Date: Oct 2019
Old 12-13-2020 , 00:18   Re: problem with fm_cs_get_user_team
Reply With Quote #2

any help pls ??
Mankled is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-13-2020 , 04:13   Re: problem with fm_cs_get_user_team
Reply With Quote #3

Use cs_get_user_team()?
__________________
fysiks is offline
Mankled
Senior Member
Join Date: Oct 2019
Old 12-13-2020 , 14:58   Re: problem with fm_cs_get_user_team
Reply With Quote #4

Quote:
Originally Posted by fysiks View Post
Use cs_get_user_team()?
I changed all fm_cs_get_user_team to cs_get_user_team and now im getting 43 stupid warning that i dont know what to do !

look at error here, some of them:

Code:
team = cs_get_user_team(id)

if (team == CS_TEAM_SPECTATOR || team == CS_TEAM_UNASSIGNED)

ewrite_string(CS_TEAM_NAMES[cs_get_user_team(ID_TEAM)]) // team

write_short(cs_get_user_team(victim)) // team
Mankled is offline
meTaLiCroSS
Gaze Upon My Hat
Join Date: Feb 2009
Location: Viņa del Mar, Chile
Old 12-13-2020 , 15:56   Re: problem with fm_cs_get_user_team
Reply With Quote #5

PHP Code:
stock fm_cs_get_user_team(id)                                                         
{                                                                                                    
    return 
_:cs_get_user_team(id);              

__________________
Quote:
Originally Posted by joropito View Post
You're right Metalicross
meTaLiCroSS is offline
Mankled
Senior Member
Join Date: Oct 2019
Old 12-13-2020 , 20:29   Re: problem with fm_cs_get_user_team
Reply With Quote #6

Quote:
Originally Posted by meTaLiCroSS View Post
PHP Code:
stock fm_cs_get_user_team(id)                                                         
{                                                                                                    
    return 
_:cs_get_user_team(id);              

now its giving me a lot of errors log

Code:
L 12/13/2020 - 18:10:25: Start of error session.
L 12/13/2020 - 18:10:25: Info (map "zm_foda") (file "addons/amxmodx/logs/error_20201213.log")
L 12/13/2020 - 18:10:25: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:10:25: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:10:25: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:10:25: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:10:25: [AMXX]    [1] zombie_plague.sma::fnGetCTs (line 10471)
L 12/13/2020 - 18:10:25: [AMXX]    [2] zombie_plague.sma::check_round (line 9197)
L 12/13/2020 - 18:10:25: [AMXX]    [3] zombie_plague.sma::fw_ClientDisconnect (line 2785)
L 12/13/2020 - 18:10:25: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:10:25: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:10:25: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:10:25: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:10:25: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:12:27: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:12:27: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:12:27: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:12:27: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:12:27: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:14:10: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:14:10: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:14:10: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:14:10: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:14:10: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:18:14: [CSTRIKE] Invalid player 6 (not in-game)
L 12/13/2020 - 18:18:14: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:18:14: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:18:14: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:18:14: [AMXX]    [1] zombie_plague.sma::fnGetCTs (line 10471)
L 12/13/2020 - 18:18:14: [AMXX]    [2] zombie_plague.sma::check_round (line 9197)
L 12/13/2020 - 18:18:14: [AMXX]    [3] zombie_plague.sma::fw_ClientDisconnect (line 2785)
L 12/13/2020 - 18:22:19: [CSTRIKE] Invalid player 6 (not in-game)
L 12/13/2020 - 18:22:19: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:22:19: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:22:19: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:22:19: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:22:37: [CSTRIKE] Invalid player 6 (not in-game)
L 12/13/2020 - 18:22:37: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:22:37: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:22:37: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:22:37: [AMXX]    [1] zombie_plague.sma::zombieme (line 6938)
L 12/13/2020 - 18:22:37: [AMXX]    [2] zombie_plague.sma::start_infection_mode (line 6736)
L 12/13/2020 - 18:22:37: [AMXX]    [3] zombie_plague.sma::start_custom_mode (line 6640)
L 12/13/2020 - 18:22:37: [AMXX]    [4] zombie_plague.sma::start_nemesis_mode (line 6630)
L 12/13/2020 - 18:22:37: [AMXX]    [5] zombie_plague.sma::start_assassin_mode (line 6545)
L 12/13/2020 - 18:22:37: [AMXX]    [6] zombie_plague.sma::start_survivor_mode (line 6433)
L 12/13/2020 - 18:22:37: [AMXX]    [7] zombie_plague.sma::start_sniper_mode (line 6353)
L 12/13/2020 - 18:22:37: [AMXX]    [8] zombie_plague.sma::start_lnj_mode (line 6273)
L 12/13/2020 - 18:22:37: [AMXX]    [9] zombie_plague.sma::start_multi_mode (line 6184)
L 12/13/2020 - 18:22:37: [AMXX]    [10] zombie_plague.sma::start_plague_mode (line 6092)
L 12/13/2020 - 18:22:38: [AMXX]    [11] zombie_plague.sma::start_swarm_mode (line 5955)
L 12/13/2020 - 18:22:38: [AMXX]    [12] zombie_plague.sma::make_zombie_task (line 5872)
L 12/13/2020 - 18:24:52: [CSTRIKE] Invalid player 6 (not in-game)
L 12/13/2020 - 18:24:52: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:24:52: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:24:52: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:24:52: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:36:38: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:36:38: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:36:38: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:36:38: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:36:38: [AMXX]    [1] zombie_plague.sma::fnGetCTs (line 10471)
L 12/13/2020 - 18:36:38: [AMXX]    [2] zombie_plague.sma::check_round (line 9197)
L 12/13/2020 - 18:36:38: [AMXX]    [3] zombie_plague.sma::fw_ClientDisconnect (line 2785)
L 12/13/2020 - 18:37:22: [CSTRIKE] Invalid player 4 (not in-game)
L 12/13/2020 - 18:37:22: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:37:22: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:37:22: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:37:22: [AMXX]    [1] zombie_plague.sma::fnGetTs (line 10489)
L 12/13/2020 - 18:37:22: [AMXX]    [2] zombie_plague.sma::check_round (line 9233)
L 12/13/2020 - 18:37:22: [AMXX]    [3] zombie_plague.sma::fw_ClientDisconnect (line 2785)
L 12/13/2020 - 18:37:22: [CSTRIKE] Invalid player 4 (not in-game)
L 12/13/2020 - 18:37:22: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:37:22: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:37:22: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:37:22: [AMXX]    [1] zombie_plague.sma::logevent_round_end (line 1854)
L 12/13/2020 - 18:37:40: [CSTRIKE] Invalid player 5 (not in-game)
L 12/13/2020 - 18:37:40: [AMXX] Displaying debug trace (plugin "zombie_plague.amxx", version "4.3")
L 12/13/2020 - 18:37:40: [AMXX] Run time error 10: native error (native "cs_get_user_team")
L 12/13/2020 - 18:37:40: [AMXX]    [0] zombie_plague.sma::fm_cs_get_user_team (line 13098)
L 12/13/2020 - 18:37:40: [AMXX]    [1] zombie_plague.sma::humanme (line 7354)
L 12/13/2020 - 18:37:40: [AMXX]    [2] zombie_plague.sma::start_sniper_mode (line 6304)
L 12/13/2020 - 18:37:40: [AMXX]    [3] zombie_plague.sma::start_lnj_mode (line 6273)
L 12/13/2020 - 18:37:40: [AMXX]    [4] zombie_plague.sma::start_multi_mode (line 6184)
L 12/13/2020 - 18:37:40: [AMXX]    [5] zombie_plague.sma::start_plague_mode (line 6092)
L 12/13/2020 - 18:37:40: [AMXX]    [6] zombie_plague.sma::start_swarm_mode (line 5955)
L 12/13/2020 - 18:37:40: [AMXX]    [7] zombie_plague.sma::make_zombie_task (line 5872)

Last edited by Mankled; 12-13-2020 at 20:31.
Mankled is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-13-2020 , 22:06   Re: problem with fm_cs_get_user_team
Reply With Quote #7

We can only guess at what the answer actually is based on the lack of code you have provided. The most generic answer that can be given is to check if the user is connected since that is literally what the error tells you (that the player is not in the game).
__________________
fysiks is offline
Reply


Thread Tools
Display Modes

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 13:48.


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