AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   BIG Problem (https://forums.alliedmods.net/showthread.php?t=164298)

Sp@jk 08-09-2011 18:39

BIG Problem
 
I have a problem, I am making a plugin that adds custom teams and I used Exolent's Team Join Managment to set player in spec and skip choose team and class menu's. I added custom menu and all, but when player is respawned ( I want to respawn a player when he/she choose a team ) I get a player that's looking on "cameras" just like when you are a spectator

PHP Code:

public team_handler(id,menu,item)
{
    switch(
item)
    {
        case 
0:
            
cs_set_user_team(id,CS_TEAM_CT)
        case 
1:
            
cs_set_user_team(id,CS_TEAM_T)
    }
    
ExecuteHamB(Ham_CS_RoundRespawn,id)



Hunter-Digital 08-09-2011 19:21

Re: BIG Problem
 
The player is teleported to spectator view points ? Then you need to set player's class aswell...

Search for the plugin that clears the "only 1 team change allowed" offset on player, use that and use engclient_cmd() with jointeam and joinclass, all of these instead of cs_set_user_team().


All times are GMT -4. The time now is 03:28.

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