force class selection -
GeneralAref - 03.02.2016
i have this but when i choose team back again to class selection.
Код:
CMD:st(playerid,params[]){
#pragma unused params
new Float:x,Float:y,Float:z;
if(PlayerInfo[playerid][pLogged]==false)return SendClientMessage(playerid,COLOR_RED,"You can not use this command.");
if(PlayerInfo[playerid][pAdmin]<CmdsOptions[st])return SendClientMessage(playerid,COLOR_RED,"You can not use this command.");
if(ServerInfo[st]==0)return CommandDisabled(playerid);
GetPlayerPos(playerid,x,y,z);
foreach(Player,i){
if(IsPlayerInRangeOfPoint(i,25.0,x,y,z)){
if(gTeam[playerid]!=gTeam[i]){
return SendClientMessage(playerid,COLOR_RED,"You can not use this command.");}}}
ForceClassSelection(playerid);
TogglePlayerSpectating(playerid,1);
TogglePlayerSpectating(playerid,0);
return 1;}
Respuesta: force class selection -
DkrX - 03.02.2016
use SetPlayerHealth(playerid, -1); and last forceclass?
Re: force class selection -
GeneralAref - 03.02.2016
i want without dying and fast
Re: force class selection -
Lumanov - 03.02.2016
ForceClassSelection(playerid);
Delete this.
Re: force class selection -
GeneralAref - 03.02.2016
Quote:
Originally Posted by Lumanov
ForceClassSelection(playerid);
Delete this.
|
Then how to change team



Re: force class selection -
povargek - 03.02.2016
Quote:
Originally Posted by GeneralAref
|
Do you have arranged a system of choice team?
Re: force class selection -
Lumanov - 03.02.2016
Quote:
Originally Posted by GeneralAref
|
*Delete*
Re: force class selection -
Sjn - 03.02.2016
Quote:
Originally Posted by GeneralAref
i want without dying and fast
|
Edit: Sorry i didn't notice you already have TogglePlayerSpectating. Anyway i'd say set their health to 0.0
Cause that's the most usual and effective way every people do.
Re: force class selection -
Rufio - 03.02.2016
People if you have no clue whatsoever as to what the OP is asking for OR if you have no clue whatsoever as to how to fix the issue, please refrain from posting. You are violating the forum rules. Thank you.
on topic: I don't know what the issue is with your original code as according to wiki SA-MP it should be working just perfect. However, you can achieve the system you want by simply using SetPlayerCameraPos, SetPlayerCameraLookAt and various SetPlayerSkin functions and you can simply use a GetPlayerSkin and assign the player to a team afterwards the skin selection. It takes effort and time but it gets the job done. Don't forget to save the player's old positions to teleport the player back to where he/she was before.
Edit: Stop telling him to use SetPlayerHealth function. He already said that he doesn't want to use the SetPlayerHealth function. Jesus christ. And no it isn't the most "useful and effective way" to do it and no, only beginner scripters do it.
Re: force class selection -
GeneralAref - 03.02.2016
i use text draw for team but after type /st and select team back to class selection and any problem in my text draws.