some qustions - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: some qustions (
/showthread.php?tid=263605)
some qustions -
Christian_Bojic - 22.06.2011
I will ask you guys some questions
how to make teams that only such member of that team can open the gate
how to make a command that can be used only within a zone
Re: some qustions -
0_o - 22.06.2011
add this up of your command
pawn Код:
if GetPlayerTeam(playerid) == /*team id*/ )
Re: some qustions -
Christian_Bojic - 22.06.2011
thx but I have more question:
How to change spawn place?
Re: some qustions -
Wesley221 - 22.06.2011
pawn Код:
public OnPlayerSpawn(playerid)
{
if(GetPlayerTeam(playerid) == 0)
{
}
if(GetPlayerTeam(playerid == 1)
{
}
return 1;
}
Sorry for no tabs, kinda busy
Re: some qustions -
0_o - 22.06.2011
add under onplayerspawn
pawn Код:
if (GetPlayerSkin(playerid) == /*skinid*/) {
SetPlayerPos(playerid, /*XYZ Co-Ords*/);
//And So on...
Re: some qustions -
Christian_Bojic - 22.06.2011
oke Im new so dont know many things
Re: some qustions -
Christian_Bojic - 22.06.2011
but again error about it
E:\SErver\gamemodes\SFRJ.pwn(69) : error 035: argument type mismatch (argument 2)
E:\SErver\gamemodes\SFRJ.pwn(70) : error 035: argument type mismatch (argument 2)
E:\SErver\gamemodes\SFRJ.pwn(77) : error 001: expected token: ")", but found "{"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
3 Errors.
Re: some qustions -
Wesley221 - 22.06.2011
pawn Код:
public OnPlayerSpawn(playerid)
{
if(GetPlayerTeam(playerid) == 0)
{
}
if(GetPlayerTeam(playerid) == 1)
{
}
return 1;
}
Forgot a " ) ", fixed
Re: some qustions -
Joe Staff - 22.06.2011
I highly suggestyou learn the simple syntax of pawn coding. You'll have a hard time making scripts if you copy and paste everything. Also I believe SetPlayerPos will be ineffective under OnPlayerSpawn, should place it under OnPlayerStateChange if player state== PLAYER_STATE_SPAWNED
Re: some qustions -
Wesley221 - 22.06.2011
Quote:
Originally Posted by SilentHuntR
I highly suggestyou learn the simple syntax of pawn coding. You'll have a hard time making scripts if you copy and paste everything. Also I believe SetPlayerPos will be ineffective under OnPlayerSpawn, should place it under OnPlayerStateChange if player state== PLAYER_STATE_SPAWNED
|
++;
Never getting problems with the OnPlayerSpawn callback, although, not yet