Raised This Month: $ Target: $400
 0% 

[help] cellarray.inc


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 11-15-2010 , 13:15   Re: [help] cellarray.inc
Reply With Quote #1

Quote:
The problem with CellTries is that you can't iterate through all of the keys, so a combination of both would be needed.
CellTravTrie exists for that.
__________________
Arkshine is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-15-2010 , 19:21   Re: [help] cellarray.inc
Reply With Quote #2

It looks like, to me, that he needs an array of Tries (one Trie for each player).

Depending on your actual implementation it's possible that you could just use an Enum/data structure and an array (probably best if your list of keys is not too many).

Something like this:

PHP Code:
enum KEYS {
    
KEY1[32],
    
KEY2[32]
}

new 
my_array[33][KEYS]

client_print(idprint_chatmy_array[id][KEY1]) 
Correct me if I'm wrong on the data structure.

If he uses Tries I don't think he would need to traverse it from his explaination.
__________________

Last edited by fysiks; 11-15-2010 at 19:31.
fysiks is offline
Reply



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

Forum Jump


All times are GMT -4. The time now is 11:21.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode