The function for this?
#1

I've forgotten what function is used for this,
Ok so i will explain it so you can tell me because i cant remember it,
If i press shift it does the action: [pawn]print("Player pressed shift");[pawn]
Whats the function for that?
Reply
#2

Quote:
Originally Posted by Torran
I've forgotten what function is used for this,
Ok so i will explain it so you can tell me because i cant remember it,
If i press shift it does the action: [pawn]print("Player pressed shift");[pawn]
Whats the function for that?
Prints a string to the server console. In server window (samp-server.exe).
Reply
#3

If you read it a bit better,
I want the bit to detect when i press shift,
Reply
#4

I believe it should be something like this:
pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
   if(newkeys & 8) && !(oldkeys & 8)
   {
      printf("%s pressed the sprint key"); //assuming the shift key is your sprint key
      return 1;
   }
   return 1;
}
But I haven't tested it.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)