Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Tech Support (https://forums.graalonline.com/forums/forumdisplay.php?f=7)
-   -   Prioritizing scripts? (https://forums.graalonline.com/forums/showthread.php?t=86926)

DustyPorViva 07-16-2009 03:13 AM

Prioritizing scripts?
 
Is there a way to control the priority of the interpretation Graal uses to run scripts, specifically weapons? For example, if I have a custom movement system, ideally I would like that weapon to be processed before other weapons, because if it is being run after, say... a custom nickname system, then the names will lag behind the player.

I know there is a way to prioritize the weapons when they're loaded, but I'm not sure if that'd work, and if that itself controls the ones in the list in any way.

Loriel 07-16-2009 03:36 AM

Put the nicknames into ganis~

fowlplay4 07-16-2009 03:59 AM

What about the..

weaponorder=

serveroption?

I assumed that made certain weapons load first and what not.

DustyPorViva 07-16-2009 04:02 AM

Quote:

Originally Posted by Loriel (Post 1507686)
Put the nicknames into ganis~

Not really the point, though :P
Same applies to most things when you're dealing with custom movement, for example. If I have custom movement, it'd be nice not to have to worry about other's scripts taking priority and not working correctly.

cbk1994 07-16-2009 06:06 AM

Quote:

Originally Posted by Loriel (Post 1507686)
Put the nicknames into ganis~

It's much less efficient to do this than have a script looping through all players in the level 20 times a second. I think Stefan's mentioned this in the past, but it's been proven on Era (Crow originally used GANI scripts for the nickname system).


Prioritizing scripts would be neat but probably hard to do if Graal's using multiple threads (which I'm pretty sure it is). Best way to get around this is calling the function in the movement system after you've moved the player.

DustyPorViva 07-16-2009 06:42 AM

Quote:

Originally Posted by cbk1994 (Post 1507715)
It's much less efficient to do this than have a script looping through all players in the level 20 times a second. I think Stefan's mentioned this in the past, but it's been proven on Era (Crow originally used GANI scripts for the nickname system).

He has.

Crow 07-16-2009 09:35 AM

Oh yea, horrible performance, really :p

Admins 07-16-2009 01:27 PM

Use weaponorder= and also add the weapons in the good order on first login. On client-side weapon scripts are executed first.

On Zone it's weaponorder=System,Movement,Tileset, which makes sure that the system and movement scripts are executed before the radar, custom nick name system etc.


All times are GMT +2. The time now is 10:18 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.