How to make anything like this
#1

I saw in some threads a function like this

pawn Код:
something OnSomethingHappens()
{
}
I hope you unterstand what i want to do, if not, post, and i will try to explain :P
Reply
#2

Um.. What?

pawn Код:
public OnTimerName()
{
   //stuff here
}
is all i know
Reply
#3

This must be a public function which is called by a Timer.

pawn Код:
SetTimer("GlobalTimer", 1000, true);

forward GlobalTimer();
public GlobalTimer()
{
     return 1;
}
Reply
#4

Quote:
Originally Posted by SnG.Scot_MisCuDI
Посмотреть сообщение
Um.. What?

pawn Код:
public OnTimerName()
{
   //stuff here
}
is all i know
What's the point of the thread, I'm getting confused you could explain what you wan't to do with it.
Anyway it looks like it's made to process player actions, etc. You could set a timer to that function, for every 1 second it will check if a player typed the /ad (adversite) cmd more than 10 times and warn him, to stop spamming the cmd.And a bunch of other things use your imagination
Reply
#5

i know how to call the functions, but how to make NOT public functions?
something OnSomethingHappens()
Reply
#6

pawn Код:
stock OnSomethingHappens( )
{
    // Do Something
    return 1;
}
Reply
#7

pawn Код:
forward OnSomethingHappens();
public OnSomethingHappens()
{
}
Reply
#8

"function" "stock" can be used for this, throught I'm not sure if the timer will call the funtion, you can try yourself
Reply
#9

Misread...
Reply
#10

NOT a Public Function!!! Can you read?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)