Raised This Month: $ Target: $400
 0% 

[help] cellarray.inc


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Lightokun
Member
Join Date: Oct 2009
Old 11-15-2010 , 08:57   [help] cellarray.inc
Reply With Quote #1

Hello again.
Now i need help with cellarray.inc.

I want to store data (like id, key=> value) in array and easy access to it.
But i wasted a lot of time trying to do it myself.

I need to create array for each player like this to retrieve data ("key" and "value")
Code:
player_id => array(
        string_key => string_value,
        another_string_key => another_string_value
),
another_player_id =>
        string_key => string_value,
        another_string_key => another_string_value
So, anybody can explain or write a code how to create dynamic array with 32 cells which contains data like "key"=>"value" n times?

Basically i want to store for each player id their settings on connect in array like: nvg color, language, hat and etc. data which is loading from DB and i don't want to create a lot of arrays for this (data can be dynamic, like some player have "nvg" key, another don't)
__________________

Last edited by Lightokun; 11-15-2010 at 09:03.
Lightokun is offline
 



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