Greetings,
I just have to ask about something I have always wanted to learn how to do myself, when it comes to scripting.
I am not very experianced on writing scripts myself, but I have been working for along time whit plugin development, such as “Bukkit, for Minecraft”! Which brings me to my question…
When I scripted to make plugins, whit the use of the “Bukkits API”, there was some methods I cant seem to understand how to make, nor can I seem to find help to learn how to make these, since I have no clue what they are called… Let me give you an example code I would be able to use;
something.getLocation(); // this would return an Vector3
something.getLocation().getWorld(); // this would return the string for the world name!
What is this called, and how can I make them in my game? I dont even know how to make something return anything else then true or false! (bool)!
It just dont make sense to be, I see why the first example can return Vector3 (even though I dont know how), but the second line? How can it suddenly return this string?
I hope someone can help me, so that I in my game can make something like this;
players.getExperiance().getCurrentExperiance(); // this then returns the current exp of the players!
Thanks,
Winsjansen
EDIT; also, in the API, I could do this;
if(something.getLocation().getWorld == “somewhere”){. // returns true if the world have that name!