Text problem
#2

Quote:
Originally Posted by The Woody
Посмотреть сообщение
Okay i have this text. But i need a timer so every seconds the text changes to another text. I know how to make a timer. But isnt there a easyer way to change the text instead of making a whole new text earch time.

Ex:

1 second: 20
2 second: 19
3 second: 18
...

pawn Код:
TextTimer = TextDrawCreate(550.000000,402.000000,"20");
TextDrawAlignment(TextTimer,0);
TextDrawBackgroundColor(TextTimer,0x000000ff);
TextDrawFont(TextTimer,2);
TextDrawLetterSize(TextTimer,0.599999,2.100000);
TextDrawColor(TextTimer,0xff000099);
TextDrawSetProportional(TextTimer,1);
TextDrawSetShadow(TextTimer,1);
So isnt there another way instead of creating a new text earch time.
Something like this? or not? :P

pawn Код:
public OnGameModeInit()
{
    SetTimer("SendRandomMessageToAll", 120000, 1);
    return 1;
}
public SendRandomMessageToAll()
{
    switch(random(4))
    {
        case 0: TextDrawSetString(TextTimer, "Apple pie for everyone!");
        case 1: TextDrawSetString(TextTimer, "ID 0 is nub!");
        case 2: TextDrawSetString(TextTimer, "Everyone gonna be banned soon!");
        case 3: TextDrawSetString(TextTimer, "Hacking is ALLOWED!");
    }
    return 1;
}
Reply


Messages In This Thread
Text problem - by The Woody - 08.04.2011, 22:49
Re: Text problem - by Unknown123 - 08.04.2011, 22:56
Re: Text problem - by The Woody - 08.04.2011, 22:57
Re: Text problem - by The Woody - 08.04.2011, 23:11

Forum Jump:


Users browsing this thread: 2 Guest(s)