SetSpawnInfo problem?
#1

Hello everyone!

Once again I have started on a new script. Basically I will make a gamemode from scratch and try to learn scripting from that, so well I am now coming with a dumb question (I guess).

SetSpawnInfo(playerid, 0, 1686.1014, -2332.1179, -2.6797, 355.4632, 0, 0, 0, 0, 0, 0); doesn't work. I have tried everything, by the way I got the coordinates from AddPlayerClass as I did /save where I wanted the spawn, but it seems like it doesn't want to work. So actually I just wondering why it doesn't work and what I can do to fix it, because that is exactly where I want all members to spawn and they shall always spawn there anyways if they have an account or they need to register one, that's the spawn!

This is the warning I am getting (I don't want any warnings):
Quote:

(292) : warning 213: tag mismatch
(292) : warning 202: number of arguments does not match definition

Line 292: SetSpawnInfo(playerid, 0, 1686.1014, -2332.1179, -2.6797, 355.4632, 0, 0, 0, 0, 0, 0);
Line 293: SpawnPlayer(playerid);

Reply
#2

Do you set their position (SetPlayerPos) when they spawn (OnPlayerSpawn)?

As for the warning, look up the parameters of SetSpawnInfo. The first three values are integers - playerid, team and skin - but your third parameter is a float (x coordinate). You're missing the team. Use NO_TEAM if you don't want to set teams.
Reply
#3

Why does this:
Quote:

0,1686.1014,-2332.1179,-2.6797,355.4632,0,0,0,0,0,0

Work and not mine? And anyways I am new in scripting so it would be a lot easier for me if you could explain where and why I should use NO_TEAM. No clue what you are talking about mate
Reply
#4

The website is lagging so bad, so I didn't notice I wrote the same thing twice, sorry for that. Please delete this comment, thanks.

SOLVED anyways.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)