![]() |
Need help with player.attr sorting/queueing system.
Well, ~20 to a little less than 30 attributes don't really work for me. Especially if it requires dedicating certain ganis to each slot (and memorizing/documenting them..). SO I've developed a system that, when told, will actively search for a free slot within a range of slot numbers (in this case, 10-29. assuming there is no [30] as I hear it's 30 slots, and 0-29 is 30 slots.), and if it finds one, will place a gani into a client.attr slot (Then will use that list to place ganis into player.attr). And when told, will search for any ganis within that range and remove them. As well as storing an internal queue if slots 10-29 are full, and as soon as a slot opens up, places the next gani in line into the queue.
edit for clarification (and cuz I dont feel like editing the entire paragraph above :p): it actually searches between client.attr 0-19, then offsets the difference by +10 when applying it to player.attr. I excecute the add gani command with AttrSys.addAttr(<ganiname>) and oddly enough, this was somewhat working (displaying the ganis) when I accidentally had it set up as player.attr[11] = AttrSys.addAttr(ganiname). But as of fixing that, the ganis stopped displaying when I try setting them. So I'm not sure what's up with that. So here's my script. Can anyone figure out what I'm doing wrong this time? PHP Code:
|
Typically you aren't/shouldn't be going over more than 10 effects.
PHP Code:
|
Ah, alright. Thanks. However, although the player.attr is being set, the particle still refuses to show.
I can do player.chat = player.attr[i], and it'll return the correct name of the gani. I've even tried setting player.attr[11] in onCreated() with the system I posted above (making sure to disable the rest of the script from clearing anything) and for some reason it STILL won't show again. Am I forgetting something? |
Post the gani, and what the attr is getting set to exactly. I.e:
player.attr[11] = "idle.gani"; should display a gani idle on the player. |
Quote:
And remembering something else: since I had been reserving player.attr[11] in the past and it's on a loop that clears it as soon as it's a variable stops showing up in the bufflist, would explain why It was not showing up normally during the tests. And would explain why just now testing player.attr 12 and up worked fine. Man I feel like an idiot.. Thanks for your help though :) |
All times are GMT +2. The time now is 10:51 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.