One question
#1

Hi, guys!
I have one question for you. Well, I want that every two minutes the message says "If you want to get a driving license, you should to go to the teachers (teacher name)" or something like that. All I want is how to do that in teacher name it says player name which works in driving school? I hope you understand me. Thanks, anyway. Sorry for my bad english, i'm Lithuanian.
Reply
#2

So you want you're server to say a random message every two minutes saying "If you want a driving license, you should go see driving teacher (name)." ?


You would have to create a 2 minute timer that keeps repeating.

Код:
forward TwoMinutePublic();
Код:
new stock TwoMinuteTimer();
Код:
public TwoMinutePublic()
{
     new id;
     SendClientMessageToAll(WHITE, "If you want to get a driving license, visit driving teacher (name)");
     return 1;
}
Код:
public OnGameModeInit()
{
     TwoMinuteTimer = SetTimer("TwoMinutePublic", 120000, true);
     return 1;
}
I dont really know if this helps you much because i dont really know what you're trying to ask, hopefully i helped you. If you have any questions please PM me and i can most likely help you with any scripting issues you might have. Have a nice day (;
Reply
#3

Ok, thanks, but For example in game my name is Jack_Delson and I am a teacher. And here is the message: "If you want a driving license, you should go see driving teacher (my name (Jack_Delson or other teacher name)." So how to do that in "name" should show my name or other teacher name? Thanks for any advice
Reply
#4

To make it you're name just change the thing in the filterscript from this
Код:
SendClientMessageToAll(WHITE, "If you want to get a driving license, visit driving teacher (name)");
to this

Код:
SendClientMessageToAll(WHITE, "If you want to get a driving license, visit the driving teacher Jack_Delson");
If this is not what you;re looking for please try to give a little more information on what you need. I have every intention of getting you to you're point of interest.
Reply
#5

Loop through all player who are set to driving license teacher and just include their names in the SendClientMessage function. (There should be a variable which shows who are driving license teacher or not)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)