Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
I've been stuck thinking about the fight system in my project Middlemoon.
The RPG Maker MZ combat system really didn't fit well in a dark modern adventure that winks to Chronicles Of Darkness.

At first I thought about using a plugin to run a Parallel Event through the Battle while storing the Variables of Attackers, Target, Skill and so on, to be able to create completely new skills (using the D10 dice system).

But when it was the time to code a fight I was left with a MEH feeling.

So I decided to up my game, I decided to create my most complex plugin so far (probably laughable by hardcore programmer but everyone has his own skillset ^^')
A plugin that once called on the map would overlay a deck-building based fighting style, moving events on the map and setting bonduaries to the Battle Area.

It's a ton of work for someone used to do Plugins that could be coded in a week max.
I'm trying to keep everything in an ordered fashion but each function, needs a function that calls a function that server 3 more other functions...

Still I'm confident, it won't be fast, it won't be easy, but I can do it!

Basic goals set:
  • A functional deck building based combat system
  • A JSON file in data to easily create all the possible cards
  • As usual, an high costumization rate
  • Combo work with my other plugin "RPG Style Stats and Skill", that's for me mostly as I need a Chronicle Of Darkness vibe to the fight
  • Decent battle AI behaviour
Ideal but not critical:
  • Ease of use (right now setting up a battle isn't really straightforward, especially if there are obstacles on the map)
  • Graphic effects (cards dealing, card use, etc..)

For now I just create part of the backbone, the plugin successfully load from the parameters of the user who is in the battle and sort them in initiative order (for now only in combo mode with the other plugin) as well as sets the AP, HP, search the player deck, shuffles it and deals the cards. (except for the initiative order all Allied and Enemies actions aren't built yet)

Now it comes the difficult part, we have our deck, we have our hand of cards, it's time to chose the card and do some action!

Screenshot 2023-08-06 17.54.32.png


 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
Small steps, but steps forward nonetheless. Now the cycle of draw card, show card, select card, choose action and back via cancel is done!

 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
It has been a while and it seem I've gone silent

But I'm not!

This plugin is honestly huge compared to the others I made and it will take a lot of time, around every corner there is a thing to fix or several new function that I need to add.

At least I'm steadly making progress! Here is a video of the ongoing progress:



Please don't mind the lack of graphic/SE, I'm focusing on getting the flow of functions working. I'll refine the looks when it's functioning.

The action/attack selector is almost done, at least the most compicated function, the translator that uses the code in the card, takes the actors parameters and decide hit and damage results.



I hope to give more news soon!
 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
AI Logic is painfuuuuuullll

I've reached the most difficult part of the plugin, I've tried to postpone it as longest as possible T_T
It's great to have a my player select cards and use them but it's pretty useless against inactive opponents and without the help of your allies.

So here we are, we need to introduce the artificial intelligence logics in the opponents and allies.
It has been 3 days I'm working on it, it's not "difficult" but it's incredibly long and nested.

How is the battle situation?
Is your team winning? Or your ass is getting whooped?
Based on the behaviour preset, the general situation, your health and your card, what's the order you prefer to play them?
But do you have the Action Points to do so? MP? TP?
You want to attack? Nice!
Are you in range? No? Can you move with your current card or with another card in range?
Great! You choose an AOE card?
Ohhh... but your allies are in the AOE
Can you avoid them?

And so on! Every step has a lot of checks... but I hope to come to an end sooner or later!
 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
After a LOT of coding the first AI steps are here!

In this video our allied Lily does the following:
  • Decide what type of card she wants, she prefer range
  • There is no range card in her hand, there is no need to heal and she doesn't have buff cards
  • Looks like she need to use an aggro card!
  • All the aggro card in her hand don't have enough range to hit an enemy
  • She checks if she has the AP to use a card to move closer and then a card to attack
  • She decide for the card with move moment and less aggro as "support" card then for the card with most aggro as "attack" card
  • And she goes!

After this I'll have to fix the AP management and loop the actions to make a complete turn for the AI battlers but this is the easiest part of the work

The next complex part will be to complete the action card resolver function, for now it handles only single target cards, I need to make it work for every type of damage (AOE, Whole field, tile)

Then there will be a LOT of debug, as the code is way more complex than what is shown in the video, it handles friendly fire, decisions for getting closer or pulling away from enemies, etc..

 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
Finally we have a full turn played out!



There is still a lot to do, like making a full battle run, adding buff and debuff, upgrading the animations, improving the AI and so on but after today I feel that the hardest part of the plugin is behind me.

 

Winthorp

Winter Dream Game Creator
Regular
Joined
Jun 12, 2023
Messages
69
Reaction score
30
First Language
Italian
Primarily Uses
RMMZ
And here is a battle!

Finally an update!

It took me a while but when you lose a single typo that changes a crucial variable value in a 15.000+ lines code is not easy to find it... and absolutely the new game released that we will call Baldurs G. for privacy has NOOOTTTTHHIINNG to do with this delay.

Anyway, on a serious note, this is an important milestone for the plugin!
A battle finished, from the start to the end!

There are still A LOT of things to do, like adding some AI logic (for example in this battle the Black Knight switched from a wounded Lily to a more healty Reid and it's not ideal. Truth is I put the focus on the player for the AI attacks but a "Who will go down first" logic is in order), polishing the animations, let the plugin transfer the HP, MP and TP remaining to the editor once the battle is over... But still, we are there! This proves I'm on the right path!

 

Latest Threads

Latest Posts

Latest Profile Posts

Mike Final Breaker.png
that time I drew Mike doing Hugo from Street Fighter 3's Shootdown Backbreaker...
So I was thinking about putting in Weapon Synthesis like the Cooking system I got going but after all these recipes I've been putting in the item log and common events for the past week and a half I'ma say no on that one chief

those shops and chests are working just fine lmao
Just watched Godzilla Minus One.
As a Godzilla fan, I loved it. Acting was a little rough, and I thought the ending was cheap, but overall, great!
Could have used more plot.
Plot. I demand more fanservice!
giphy-downsized.gif
I should do a Photoshop with "Everyone Loves Reimond" and just stick Rei in the middle where Raymond's face would be.
Non-rare second status post but we closed the Third and Final Cameo Battle
Reveal_3&4_F.png

Forum statistics

Threads
136,637
Messages
1,268,274
Members
180,323
Latest member
fruy229
Top