Spawns bug :( Only one skin - CJ
#1

Whats wring with this script In server i have only one team/skin - SKIN ID 0, CJ and i cant select it

http://tuned.oo.lv/servsamp/gamemodes/sftdm.pwn
Reply
#2

http://wikitmp.sa-mp.com/index.php/AddPlayerClass

http://wikitmp.sa-mp.com/index.php/Skins

Take a look at those, that may help
Reply
#3

try changing SetWorldTime(04); to SetWorldTime(4);
Reply
#4

Quote:
Originally Posted by Jashugan
try changing SetWorldTime(04); to SetWorldTime(4);
?? what will that do? he is looking to change the skins :P not time
Reply
#5

Quote:
Originally Posted by TTJJ
He hasnt used any Functions too change skin and he has done addplayerclass correctly.

Make sure there are no dodgey filterscripts, or if any plugins are required, they are loaded. do you spawn in the right place?
Reply
#6

u dont understand!
here is screenshot


here is code: http://tuned.oo.lv/servsamp/gamemodes/sftdm.pwn
Reply
#7

Quote:
Originally Posted by TTJJ
Quote:
Originally Posted by Jashugan
try changing SetWorldTime(04); to SetWorldTime(4);
?? what will that do? he is looking to change the skins :P not time
If skins dont show like this it means the OnGameModeInIt function isn't loading properly which is usually caused by a piece of code being wrong in there. I dont know the function setworldtime well but it might be that "04" is bugging everything up if it should instead be "4".

Try it out and see, thats the only thing I can see that looks dodgy in the script.
Reply
#8

And what is this?

Quote:

C:\AppServ\www\servsamp\gamemodes\sftdm.pwn(1129) : warning 235: public function lacks forward declaration (symbol "SetupPlayerForClassSelection")
C:\AppServ\www\servsamp\gamemodes\sftdm.pwn(1245) : warning 235: public function lacks forward declaration (symbol "GameModeExitFunc")
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Warnings.

Reply
#9

Still bug...

I think, problem is here:


Код:
public OnPlayerRequestClass(playerid, classid)

{

	SetPlayerClass(playerid, classid);

	SetupPlayerForClassSelection(playerid);

	gPlayerClass[playerid] = classid;

	switch (classid) {

	  case 0:

	    {

				GameTextForPlayer(playerid, "~g~Street racer", 500, 3);

			}

		case 1:

		  {

				GameTextForPlayer(playerid, "~g~Biker", 500, 3);

			}

		case 2:

	    {

				GameTextForPlayer(playerid, "~g~Wang Band", 500, 3);

			}



		case 3:

	    {

				GameTextForPlayer(playerid, "~g~FBI", 500, 3);
				
      }
      
      
    case 4:

	    {

				GameTextForPlayer(playerid, "~g~Mafia", 500, 3);

			}
			
			
    case 5:

	    {

				GameTextForPlayer(playerid, "~g~Girl", 500, 3);

			}

	}

}







//------------------------------------------------------------------------------
But what? It starts, when i remove "return 1", but when is it, pawn show lots of errors!
Reply
#10



Код:
public OnPlayerRequestClass(playerid, classid)

{

	SetPlayerClass(playerid, classid);

	gPlayerClass[playerid] = classid;

	switch (classid) {

	  case 0:

	    {

				GameTextForPlayer(playerid, "~g~Street racer", 500, 3);

			}

		case 1:

		  {

				GameTextForPlayer(playerid, "~g~Biker", 500, 3);

			}

		case 2:

	    {

				GameTextForPlayer(playerid, "~g~Wang Band", 500, 3);

			}



		case 3:

	    {

				GameTextForPlayer(playerid, "~g~FBI", 500, 3);
				
      }
      
      
    case 4:

	    {

				GameTextForPlayer(playerid, "~g~Mafia", 500, 3);

			}
			
			
    case 5:

	    {

				GameTextForPlayer(playerid, "~g~Girl", 500, 3);

			}

	}
	SetupPlayerForClassSelection(playerid);  <----- this at the bottom

}

then you do:

public SetupPlayerForClassSelection(playerid)
{
	switch (whatever you have defined for teams)
	{
		case team name:
		{
			SetPlayerInterior(playerid,interiorID);
			SetPlayerPos(playerid,X,Y,Z);
			SetPlayerFacingAngle(playerid, ANGLE);
			SetPlayerCameraPos(playerid,X,Y,Z);
			SetPlayerCameraLookAt(playerid,X,Y,Z);
		}


etc.



//------------------------------------------------------------------------------
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)