#1

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

https://sampwiki.blast.hk/wiki/Scripting_Basics
https://sampwiki.blast.hk/wiki/Control_Structures
https://sampwiki.blast.hk/wiki/Keywords
Reply
#3

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

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

https://sampwiki.blast.hk/wiki/PAWN_tutorial
Reply
#6

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
Reply
#7

Remove these lines

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

Код:
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.
Reply
#9

this is errors now
Reply
#10

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;
}
Reply
#11

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?
Reply
#12

how to make it?
Reply
#13

?? ?
Reply
#14

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!!!
Reply
#15

Код:
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
Reply
#16

how to fix it?
Reply
#17

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

i need to fix that error!!!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)