Hello fellow Rpg Makers,
I'm only a novice coder, (at best) and have just started to take a stab at java script, but so far the syntax has me muddled quite profoundly.
My game has various locations that need defending. I need a way to send party members to various locations. The game needs know where each party member is, and whether the location their sent to is full or not. So far I've done this through eventing + variables, but I believe this can be done far easier through coding with an array or something.
What I've done essentially looks like this;
Locations; (These are just written down on paper, not actually variables in the game.)
0 = dead
1 = castle
2 = town
3 = tower
4 = mine
My game has many playable characters. I've made variables each of them, and when they change locations I set set their variables accordingly.
Characters;
Tom = 0
Dick = 1
Harry = 2
So by this Tom is dead, Dick is at the castle, and Harry's having a pint in the town's pub.
Pretty straightforward up to here, but when I begin to put in a method to check whether a locations is 'full', or when a certain location is attacked, to know who should be in that particular party to defend it, things get more complicated. After much head scratching, I think I've found ways to accomplish most of this through events and variables, but it's quite tedious and I thought it would be good opportunity to try and learn some java script.
I'm not sure if I need to build a plugin, or if I can get away with calling script through an event. Any advice on how to proceed would be infinitely appreciated. Cheers
I'm only a novice coder, (at best) and have just started to take a stab at java script, but so far the syntax has me muddled quite profoundly.
My game has various locations that need defending. I need a way to send party members to various locations. The game needs know where each party member is, and whether the location their sent to is full or not. So far I've done this through eventing + variables, but I believe this can be done far easier through coding with an array or something.
What I've done essentially looks like this;
Locations; (These are just written down on paper, not actually variables in the game.)
0 = dead
1 = castle
2 = town
3 = tower
4 = mine
My game has many playable characters. I've made variables each of them, and when they change locations I set set their variables accordingly.
Characters;
Tom = 0
Dick = 1
Harry = 2
So by this Tom is dead, Dick is at the castle, and Harry's having a pint in the town's pub.
Pretty straightforward up to here, but when I begin to put in a method to check whether a locations is 'full', or when a certain location is attacked, to know who should be in that particular party to defend it, things get more complicated. After much head scratching, I think I've found ways to accomplish most of this through events and variables, but it's quite tedious and I thought it would be good opportunity to try and learn some java script.
I'm not sure if I need to build a plugin, or if I can get away with calling script through an event. Any advice on how to proceed would be infinitely appreciated. Cheers

