Use javascript to draw an array of tiles etc...

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
Hello, haven't posted here in a while and I'm working on another project (finished my first, need money to upload to steam) but anyways, what I'm doing right now is working on a custom battle system which I can't seem to get working. I have looked around but seen no examples so far so I'm attempting and not so successfully trying to make a new script for grid type movement during battle in which the players can use the arrow keys to move the character during combat or during turn process which they can use to actively reposition themselves in battle rather than just remain static.

Is this possible in RPG Maker?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,433
Reaction score
7,712
First Language
German
Primarily Uses
RMMV
Theoretically anything is possible in MV because the entire engine is open.
Unfortunately some things are more difficult than others...

Tactical battle systems are among the most complex tasks possible (at least if you want the computer enemies to be more than cannon fodder)...

That said, I suggest you use a map instead of the battle screen for it. Save the current player position and map data when a battle initiates and have them transfer at that moment to a predefined battlemap. On that map turn the party into a cursor for selecting events that pretend to be the actors and enemies.
That would solve a few steps toward a tactical battle system, but the rest will still be a lot of work (there is a reason why there is only one TBS for Ace and none (yet) for MV...)
 

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
Theoretically anything is possible in MV because the entire engine is open.
Unfortunately some things are more difficult than others...

Tactical battle systems are among the most complex tasks possible (at least if you want the computer enemies to be more than cannon fodder)...

That said, I suggest you use a map instead of the battle screen for it. Save the current player position and map data when a battle initiates and have them transfer at that moment to a predefined battlemap. On that map turn the party into a cursor for selecting events that pretend to be the actors and enemies.
That would solve a few steps toward a tactical battle system, but the rest will still be a lot of work (there is a reason why there is only one TBS for Ace and none (yet) for MV...)
Ah I really wanted the battle to occur on the battle instance rather than n the map itself, rather I wanted the game to accept player input during the process turn phase of the battle.
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
Not sure if that's what you're after, but I have a similar custom battle system in my game. It's still a work in progress though. I'm not done with it, since I made it a lot more complex (with skill abilities and hero abilities that you can level, different AoE patterns, etc.)

 

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
Not sure if that's what you're after, but I have a similar custom battle system in my game. It's still a work in progress though. I'm not done with it, since I made it a lot more complex (with skill abilities and hero abilities that you can level, different AoE patterns, etc.)

Yeah definitely something like the green tiles you have there but the mechanic I'm thinking of is that characters can move about whilst the guage is building up.

Similar to this: But I have a few adjustments in mind. Though at this point, I'm considering learning something more advanced z.z
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
So there would no other party members? Unless you could switch between them.
 

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
So there would no other party members? Unless you could switch between them.
There would be switching but no other party members. It'd make the game battle scenes too confusing.
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
Okay, I got the general idea of your battle system. So what exactly is your problem in coding it?

Personally, I would create a grid function in which each grid is assigned a number (0 to 31 for a 4x4 grid for enemies and actors). You'll need to modify your character sprite class to add a variable representing the "grid position". Using the arrow keys modify your "grid position" property. Last thing that needs to be done is to add a function that constantly updates the characters' position on the screen based on their current "grid position" property.
 

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
Okay, I got the general idea of your battle system. So what exactly is your problem in coding it?

Personally, I would create a grid function in which each grid is assigned a number (0 to 31 for a 4x4 grid for enemies and actors). You'll need to modify your character sprite class to add a variable representing the "grid position". Using the arrow keys modify your "grid position" property. Last thing that needs to be done is to add a function that constantly updates the characters' position on the screen based on their current "grid position" property.
My complete newness to javascripting from scratch (I am familiar with coding in general).

Hence I was asking if the game engine could facilitate something like this before seriously attempting it. Don't want to make the extra effort to learn javascript when I'm already learning C++ for a rather extreme project...
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
Ohh, unfortunately I don't think there's something in the basic engine that builds something similar. I mean, you could modify the Sprite_Actor, but you'll still have to create a new scene for that.

To give you an idea, I built the basic functionality of my battle system (for it to work, only attacking and turns) in about 4000 lines in 2-3 days. It's now a bit above 10000+ lines (since I need to program individually each skills, abilities, enemy AI, etc.). So yeah, it can take a lot of work, but if you keep it simple, it shouldn't be too long (if you put the effort lol).
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
And also, javascript is extremely easy compared to C++. If you know C++, in 2-3 days of playing with Javascript you'll be good enough to build your battle system.
 

Solwern

Dead person.
Veteran
Joined
Jul 27, 2016
Messages
134
Reaction score
68
First Language
English
Primarily Uses
RMMV
Ohh, unfortunately I don't think there's something in the basic engine that builds something similar. I mean, you could modify the Sprite_Actor, but you'll still have to create a new scene for that.

To give you an idea, I built the basic functionality of my battle system (for it to work, only attacking and turns) in about 4000 lines in 2-3 days. It's now a bit above 10000+ lines (since I need to program individually each skills, abilities, enemy AI, etc.). So yeah, it can take a lot of work, but if you keep it simple, it shouldn't be too long (if you put the effort lol).
Why not call the notetags from the database and program preset actions in your code? (referencing yanfly's action sequences) That should reduce your effort a great deal.

Otherwise, learning Javascript isn't the problem, it's the coupling with HTML and SQL that most tutorials seem to do that is. Heck, reading through some javascript codes, I can more or less get the gist of how they operate other than how they call specific classes outside their file... I don't get that part too well yet otherwise I gather I'd be more or less en-route about now z.z
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,685
First Language
English
Primarily Uses
RMMZ
Why not call the notetags from the database and program preset actions in your code? (referencing yanfly's action sequences) That should reduce your effort a great deal.

Otherwise, learning Javascript isn't the problem, it's the coupling with HTML and SQL that most tutorials seem to do that is. Heck, reading through some javascript codes, I can more or less get the gist of how they operate other than how they call specific classes outside their file... I don't get that part too well yet otherwise I gather I'd be more or less en-route about now z.z
Oh, I just wanted the pride to be able to say "here's a good game without any Yanfly plugins" lol. Also, I wanted the experience of building every element of my battle system. I've made every thing highly customizable. Skills can have have multiple animations, multiple hit with different targets, elements, power, variance, critical, etc., add flash effect wherever I want, add custom abilities that can be leveled to deal more dmg, increase % to inflict a state, add extra hits, etc. I needed to redo everything and build from the ground up for that level of control.

Also, why do you need to meddle with HTML and SQL in order to build your battle system? Javascript is enough to make run in the RPG Maker. What you are trying to accomplish is a lot easier than my battle system, and even a tactical battle system.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Day 9 of giveaways! 8 prizes today :D
He mad, but he cute :kaopride:

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.

Forum statistics

Threads
106,040
Messages
1,018,476
Members
137,824
Latest member
dobratemporal
Top