NEED HELP! GameText Tutorial In-Game Help
#1

You probably know Redgie's RP's short tutorial ingame with GameText. The player gets to see a spot and you will get a small tutorial in GameText-style.

I want to do a bit similar stuff, I want to freeze the player for 15 seconds and then put a GameText on their screen like this:

~r~Do not deathmatch, revenge kill, bug abuse or hack.~n~
~r~You are also not allowed to metagame or powergame.~n~
~r~Have fun!

This is the player spawn part:

Код:
public OnPlayerSpawn(playerid)
{
	if(gPlayerLogged[playerid])
	{
		SetPlayerSpawn(playerid);
	}
	return 1;
}
Help me!
Reply
#2

use TogglePlayerControllable, GameTextForPlayer, SetTimer and again TogglePlayerControllable.
Reply
#3

I'm sorry but I'm a big n00b. Could you please explain?
Reply
#4

Search on the functions he gave on this forum and Wiki.
Reply
#5

Quote:
Originally Posted by Rk_
Search on the functions he gave on this forum and Wiki.
would people just stop repling to just say " search , look up in wiki , etc..?" com on now.. just dont reply because saying to "search" wont help. if ur going to reply help the person :S , at least thats my opinion.
Reply
#6

They're supposed to learn
Reply
#7

i know but telling them to search isnt learning , mayby explaning things and how its done would be..
Reply
#8

Can someone please help me with this, I searched this up but I can't seem to get it right. Can someone please show me an example of how a tutorial like this is done?
Reply
#9

Top of your script:
Код:
forward timeleft();
Onplayerspawn
Код:
public OnPlayerSpawn(playerid)
{
	if(gPlayerLogged[playerid])
	{
		SetPlayerSpawn(playerid);
	}
    TogglePlayerControllable(playerid,0);
    SetTimer("timeleft",1000,false); // On the place where is standing: 1000 = 1 second
    GameTextForPlayer(playerid, "~r~Do not deathmatch, revenge kill, bug abuse or hack.~n~", 3000, 4);
    GameTextForPlayer(playerid, "~r~You are also not allowed to metagame or powergame.~n~", 3000, 4);
    GameTextForPlayer(playerid, "~r~Have fun!", 3000, 4);
	return 1;
}
Somewhere else in your script:
Код:
public timeleft()
{
	TogglePlayerControllable(playerid,1);
}
Reply
#10

Thanks for the help but I got some errors!

Код:
C:\Users\Dol\Desktop\SA-MP Server\gamemodes\reverserp.pwn(1490) : warning 217: loose indentation
C:\Users\Dol\Desktop\SA-MP Server\gamemodes\reverserp.pwn(1495) : warning 217: loose indentation
C:\Users\Dol\Desktop\SA-MP Server\gamemodes\reverserp.pwn(16737) : error 017: undefined symbol "playerid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)