Thread: [Guide] Scripting in Essentials 101
View Single Post
Old December 15th, 2012 (10:42 PM).
zingzags's Avatar
zingzags zingzags is offline
PokemonGDX creator
    Join Date: Jan 2009
    Location: Boston
    Age: 23
    Nature: Adamant
    Posts: 562
    When you are using " $[0]", you are referring to the array party, which lies in the Trainer class "I think", remember computers start from 0, not from one. So when you are programming it is important to know that you always start at 0. But lets say you are trying to initialize an array, in lets say java or c++, what you would do is array_name[number of elements]. So for example pokemon[10], you will have 10 elements which can be used to hold a value. But as I said before to get the first value in the array, you would use pokemon[0].

    $ is the size of the array, so as Luka said before is true.
    Check out the Pokemon Game Engine I am working on:
    Reply With Quote