How to properly use arrays?
#8

To explain it with fishing areas.

The first [] is the fishing area, in this case you want 2 fishing areas so placing MAX_FISH_AREAS inside the first [] is basically saying that you want two fishing areas.

(MAX_FISH_AREAS is the same as 2, so [MAX_FISH_AREAS] is the same as [2])

Then the second [] would be the fishing area coordinates but because there is 3 coordinates for each fishing area, you need the second [] to have [3] inside it.

The reason the first [] has MAX_FISH_AREAS is because you can easily change it just by changing the value of the #define.

I hope that explains it enough xD
Reply


Messages In This Thread
How to properly use arrays? - by rangerxxll - 30.03.2014, 02:07
Re: How to properly use arrays? - by EiresJason - 30.03.2014, 03:00
Re: How to properly use arrays? - by rangerxxll - 30.03.2014, 03:04
Re: How to properly use arrays? - by EiresJason - 30.03.2014, 03:30
Re: How to properly use arrays? - by newbie scripter - 30.03.2014, 03:38
Re: How to properly use arrays? - by rangerxxll - 30.03.2014, 03:38
Re: How to properly use arrays? - by RoboN1X - 30.03.2014, 03:43
Re: How to properly use arrays? - by EiresJason - 30.03.2014, 03:44
Re: How to properly use arrays? - by rangerxxll - 30.03.2014, 03:50
Re: How to properly use arrays? - by RoboN1X - 30.03.2014, 03:52

Forum Jump:


Users browsing this thread: 3 Guest(s)