SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 10/05/2019, 06:59 PM   #1
ElMaestro123
Big Clucker
 
Join Date: Feb 2017
Location: Stuck in the middle of nowhere.
Posts: 105
Reputation: 0
Default Assign callback priority

Hey, I've been into SA:MP scripting for a while and I've never seen anything regarding assigning callback priorities. For example, I start a race event and I want my server to set OnPlayerEnterCheckpoint callback priority to high so it can be called way more frequently and to make it respond from the client faster. Is it possible using 3rd party plugins or is it hidden inside current functions of SA:MP or is it just not possible at the moment? Thanks in advance.
ElMaestro123 is offline   Reply With Quote
Old 10/05/2019, 07:06 PM   #2
KeyOfKey
Huge Clucker
 
KeyOfKey's Avatar
 
Join Date: Apr 2019
Location: Italy
Posts: 427
Reputation: 16
Default Re: Assign callback priority

What?

pawn Code:
print("I run first");
print("I run second after the first");
print("I'm the last one :(");

This code:

pawn Code:
public OnPlayerDeath(playerid, killerid, reason)
{
    SendDeathMessage(killerid, playerid, reason);
    kills++;
    return 1;
}

First sends the death message then adds +1 to the kills variable.

Backwards:

pawn Code:
public OnPlayerDeath(playerid, killerid, reason)
{
    kills++
    SendDeathMessage(killerid, playerid, reason);
    return 1;
}

Pawno follows your scripting order.
KeyOfKey is online now   Reply With Quote
Old 11/05/2019, 09:30 PM   #3
ElMaestro123
Big Clucker
 
Join Date: Feb 2017
Location: Stuck in the middle of nowhere.
Posts: 105
Reputation: 0
Default Re: Assign callback priority

Are you joking? Learn to read before writing any non-sense.
ElMaestro123 is offline   Reply With Quote
Old 12/05/2019, 12:43 AM   #4
BlackBank
Gangsta
 
Join Date: Dec 2010
Location: The Netherlands
Posts: 524
Reputation: 437
Default Re: Assign callback priority

What do you exactly mean with "callback priorities"?
BlackBank is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
High priority fixes/very desired suggestions Dr.Einstein Scripting Help 32 11/02/2014 08:23 AM
Priority-Issue Anti-Hack GiS Scripting Help 6 20/06/2013 08:28 PM
Notepad++ - EXEC plugin running pawncc.exe with realtime priority chormi Scripting Help 3 03/01/2013 01:13 AM
[Tutorial] Hooking CallBack(s) - How to Hook any callback Swimor Tutorials 6 19/10/2012 09:32 PM
How to assign a value zack3021 Help Archive 15 10/09/2010 12:06 AM


All times are GMT. The time now is 12:48 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.