SA-MP Forums Archive
Help - 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: Help (/showthread.php?tid=251895)



Help - SpiderWalk - 29.04.2011

Where i can find on SAMP Wiki how to script teams help!!


Re: Help - Alby Fire - 29.04.2011

https://sampwiki.blast.hk/wiki/Scripting_Basics
https://sampwiki.blast.hk/wiki/Control_Structures
https://sampwiki.blast.hk/wiki/Keywords


Re: Help - SpiderWalk - 29.04.2011

I need tutorial of Teams no Keywords and Scripting Basics i need Tutorial how to create Teams !


Re: Help - [DDC]Delight - 29.04.2011

http://forum.sa-mp.com/forumdisplay.php?f=70


Re: Help - G*Mafia - 29.04.2011

https://sampwiki.blast.hk/wiki/PAWN_tutorial


- SpiderWalk - 29.04.2011

Thanks G*Mafia

This is my GM.
http://pastebin.com/RxCGevFJ
This is errors what is problem?
Код:
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(94) : error 017: undefined symbol "SetPlayerToTeamColor"
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(170) : error 017: undefined symbol "SetPlayerTeamFromClass"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors



Re: Help - MadeMan - 29.04.2011

Remove these lines

pawn Код:
#if defined FILTERSCRIPT
#else
#endif



Re: Help - SpiderWalk - 29.04.2011

Код:
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(168) : error 017: undefined symbol "classid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.



Re: Help - SpiderWalk - 29.04.2011

this is errors now


Re: Help - MadeMan - 29.04.2011

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerTeamFromClass(playerid, classid);
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}
pawn Код:
public OnPlayerRequestSpawn(playerid)
{
    return 1;
}



Re: Help - SpiderWalk - 29.04.2011

Now when i enter to game i will have 2 skins how to give a Game Text on it to players now what team he is?


Re: Help - SpiderWalk - 29.04.2011

how to make it?


Re: Help - SpiderWalk - 29.04.2011

?? ?


Re: Help - azzerking - 29.04.2011

Right ok try this

pawn Код:
#define Civilian 0
#define Cops 1
#define Medic 2


public OnGameModeInit()
{
    AddPlayerClass(219, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0); // CIVIL // This is 0

    AddPlayerClass(280,2281.3210,2429.7224,3.2734,359.5055,3,1,22,50,29,500); //    COPS // This is 1

       AddPlayerClass(274, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0); // MEDIC // This is 2
}

SetPlayerTeamFromClass(playerid, classid)
{
    if(classid >= 0 && classid <= 0) SetPlayerTeam(playerid, Civilian); // All ways start with 0
    else if(classid >= 1 && classid <= 1) SetPlayerTeam(playerid, Cops);
    else if(classid >= 2 && classid <= 2) SetPlayerTeam(playerid, Medic);
}
public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerTeamFromClass(playerid, classid);

    if(classid >= 0 && classid <= 0)
    {
        GameTextForPlayer(playerid, "~r~Civilian", 3000, 3);
        SetPlayerInterior(playerid, 0);
        SetPlayerPos(playerid, 2219.1992,2124.8589,18.0782);
        SetPlayerFacingAngle(playerid, 265.7682);
        SetPlayerCameraPos(playerid, 2160.5520, 1167.0829, 10.8125);
        SetPlayerCameraLookAt(playerid, 2157.1101, 1167.2665, 9.1435);
    }

    if(classid >= 1 && classid <= 1)
    {
        GameTextForPlayer(playerid, "~r~Cops", 3000, 3);
        SetPlayerInterior(playerid, 0);
        SetPlayerPos(playerid, 2219.1992,2124.8589,18.0782);
        SetPlayerFacingAngle(playerid, 265.7682);
        SetPlayerCameraPos(playerid, 2160.5520, 1167.0829, 10.8125);
        SetPlayerCameraLookAt(playerid, 2157.1101, 1167.2665, 9.1435);
    }

    if(classid >= 2 && classid <= 2)
    {
        GameTextForPlayer(playerid, "~r~Medic", 3000, 3);
        SetPlayerInterior(playerid, 0);
        SetPlayerPos(playerid, 2219.1992,2124.8589,18.0782);
        SetPlayerFacingAngle(playerid, 265.7682);
        SetPlayerCameraPos(playerid, 2160.5520, 1167.0829, 10.8125);
        SetPlayerCameraLookAt(playerid, 2157.1101, 1167.2665, 9.1435);
    }
       return 1;
}
Try this as it maybe a little better to understand and is a good simple way for teams to be set out
if you need more help or reciveve error then post here and we will continue to help you!!!


Re: Help - SpiderWalk - 30.04.2011

Код:
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(169) : error 017: undefined symbol "classid"
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(171) : error 017: undefined symbol "classid"
C:\Documents and Settings\Korisnik\Desktop\G.R.P\gamemodes\SAW.pwn(181) : error 017: undefined symbol "classid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


3 Errors.
Now this errrors and this is my GM
http://pastebin.com/n4x6LQ97


Re: Help - SpiderWalk - 30.04.2011

how to fix it?


Re: Help - DRIFT_HUNTER - 30.04.2011

http://forum.sa-mp.com/showthread.ph...highlight=team


Re: Help - SpiderWalk - 30.04.2011

i need to fix that error!!!