Turn based map: Test

Solu9

You can change this now in User CP.
Reaction score
216
I have always enjoyed the turned based battle system of the Final Fantasy series, so I thought I would try and mimic it using the Warcraft 3 Editor.

Although small in scale, my idea has been realized to my level of WC3: Editor skills.

How it works:

You control 3 heroes and fight 4 enemies.
While I would love to have had a turn based system where you could predict which unit was the next to attack I was not able to create such. So the next unit in the attack sequence will be chosen randomly after a unit has used it's turn.

When one of your heroes has been selected you can either chose to do a normal attack or use magic/item.
If attack is chosen you pick an enemy to attack and your unit will automatically attack said unit.
If magic/item is chosen you may choose one of the abilities of the selected hero or use an item.

You don't have to worry about turns, the game will by it self chose another unit when you are done.

To begin the turned based fight type -start

Known problems:
-You can't go back to the "Choose Action Menu" at the moment - Fixed
-You have no way of knowing what unit is next, thus you can't use that tactically
-Since units are picked randomly you can get unlucky with the selection - Fixed
-If you choose to cast a spell you can (if you are fast) use an item as well in the same round, which is both not meant to be and can mess up the whole rotation
-(Not a problem, but rather a nice side effect) Spells that effects the target over a period of time like the Paladin's Storm Bolt seems at first glance that it gets stuck in an endless loop. This is not the case though. The unit is paused when it is not its turn. Therefore the debuff timer is also paused and only counts towards 0 when it is said unit's turn. The nice side effect in this scenario is that you don't waste the timer when you or the other enemy units are taking their turn.

-I have not found a method for making enemy units cast spells. I know how I can implement this relatively easy by coding each unit. The problem with this is that the battle system is meant to be used in a RPG where you fight a lot of different enemies with a lot of different skills.

Im not exactly asking for help, just wanted to upload this small test map as a part of experimenting and learning more about the editor.
Of course if you have ideas/fixes or find bugs by all means post them here.

Thanks for reading :)


I have attached the map to this post.

Edit: I thought I missed something. To start the turn based fight type -start

Update 1:
Major Fixes:
-When a unit from one of the parties takes an action the game will automatically pick a unit from the other party as the next selected unit.
-Possible to go back to the main menu if you press the attack button
-Added a change party member button, which will, when pressed, pick a random unit from your party. If you are unhappy with the new selection as well just click the change party member button again.
Minor fixes:
-Chain Lightning reduces damage by 15% per jump as in the normal game
-Holy Light heals 200 up from 100
-Enemies does ~100 damage up from 50

Update 2:
Major Changes:
-All units now have timers for when their next turn activates. So instead of just switching sides, the game now only controls the time of who's turn is next. Timers are shown only for your heroes. This makes the battle much more fluidly and heroes and enemies can attack at the same time. There are still problems with this system though, read further down.
-Shadow Strike has been redesigned to only give initial damage, it fixes the instant death bug

New DL map has been attached.



Known problems:
-You can't go back to the "Choose Action Menu" at the moment - Fixed
-You have no way of knowing what unit is next, thus you can't use that tactically
-Since units are picked randomly you can get unlucky with the selection - Fixed
-If you choose to cast a spell you can (if you are fast) use an item as well in the same round, which is both not meant to be and can mess up the whole rotation
- Apparently if Shadow Strike is applied to a unit it will get instantly killed when it is said unit's turn. And I have no idea why.
- If one of your heroes die and gets selected the game will crash
-For some reason the enemy units sometimes get stuck when they attack and only move back to their initial spot when it is their turn again.
-There is a really annoying problem with the hero timers. Sometimes when a hero timer hits 0 and it is his turn to act the timer jumps back to 3 seconds instead of resetting to 15 seconds. (Inputs are welcome!)
 

Attachments

  • Turn Based Battle Test -2.w3x
    42.6 KB · Views: 201

Solu9

You can change this now in User CP.
Reaction score
216
Actually now that I think of it, it would be very nice if some of you would try the map out, perhaps even look at the triggers and give some feedback. If you like it, what could be changed and the general feel of the system.

If you decide to try it out please remember:
- type -start to begin the fight
- if you click the "Magic / Item" button in the command menu and casts a spell do NOT use an item in the same round as it will screw up the map

Thank you
 

Imp Midna

Active Member
Reaction score
52
its 1:30 over here (year, a.m.) so this could get some kind of random.
Random critique flowing through my mind:
- Its quite annyoing that your hero is picked randomly.
- horray if the enemy doesnt return for your ranger shall attack twice
- i belive the object editor spells are there because this is a test map. i'd highly recommend not using anything time based in sutch a map and rather trigger the effects turn based
- i feel like a lot in the triggers is just a copy with one replaced varaible. The 7 ifs in the Unit Rotate Trigger eg only really differ in the Set SelectedUnit thingy that could easily be put in the thery beginning in small if then else blocks (not multiple action ones) so that only 2 ifs (enemy or players turn) are needed
- Same goes for the Attack Target X Triggers
- Speaking about those Attack Target Triggers, i often saw units not returning entirely. I guess working with events like unit takes damage etc would be safer then using waits
- the mana kinda confused me. If you palas mana drops to like 10 and he doesnt have an item either and you forgot about it, trying to use stormbolt, you gotta wait for like 1 minute till you have enough mana to do so for no appearent reason. Either have infinite mana or deactivate the mana regeneration entirely, not allowing to use spells when you dont have the mana to do so
- also, units tend not to attack what i told them but rather units on their way
- you can attack dead units. well, you cant. thats the problem.
- no epic win music? *cry*
- you really need to get rid of the 2 spells + item bug
- im not a really fan of this kind of games in general, but the fight seemed a bit long to me ^.^ (i guess you can ignore this one, its 1:30...)

Random suggestions or ideas:
- Keep your Triggers in sutch a way that you dont have to copy all to mutch. it keeps things clearer and, more importantly, if you ever have to change something, you only have to change it once
- If a unit is dead, dont show the option to attack it
- think about a selection based system. it would be more like the modern games of this kind then i guess
- afaik this is a system. i'd not split a system in different folders
- the show-damage-over-units-head-thingy would be awsome
- if this is going to be a system that is used with more units, add an interface for letting cpu-units cast spells.
- so dead heros are outa the game? revive chances?

If i like it:
- The general system seems neat and i would really like to see a map like this in the map list (which would be a welcomed alternative to dota, hlw and vampirism...)
- So do the attack times
- Neat looking area
- its satisfying as hell do get a god damned crit :D
- i feel like theres a lot of potencial for tactics if you create good matching skills and items.

(hurray, now its 1.50. im so gonna sleep now)
 

Solu9

You can change this now in User CP.
Reaction score
216
Oh that was a lot more feedback than I had imagined and thank you for that! :)

To reply on some of your points:


- Its quite annyoing that your hero is picked randomly.
Indeed and this was only to add the ability to actually change. It will be fixed.


- i feel like a lot in the triggers is just a copy with one replaced varaible. The 7 ifs in the Unit Rotate Trigger eg only really differ in the Set SelectedUnit thingy that could easily be put in the thery beginning in small if then else blocks (not multiple action ones) so that only 2 ifs (enemy or players turn) are needed

That is true. I'll try your suggestion out.

- the mana kinda confused me. If you palas mana drops to like 10 and he doesnt have an item either and you forgot about it, trying to use stormbolt, you gotta wait for like 1 minute till you have enough mana to do so for no appearent reason. Either have infinite mana or deactivate the mana regeneration entirely, not allowing to use spells when you dont have the mana to do so

Yup that is also a problem. I had added the "Change member ability" to each hero in exactly the case you describe. But I forgot to make it visible (it's based on Channel).

- im not a really fan of this kind of games in general, but the fight seemed a bit long to me ^.^ (i guess you can ignore this one, its 1:30...)

For testing purpose only :) If implemented into a real map the enemies would have less HP.

- afaik this is a system. i'd not split a system in different folders

You mean the folders in the editor? I agree, the reason I spilt it into several folders was for better overview. For my self anyway :)

- if this is going to be a system that is used with more units, add an interface for letting cpu-units cast spells.

Im working on this. I was thinking another integer variable with an if-then-else. Thoughts?

- Neat looking area

I thought so ;)

Again thanks a lot for the feedback. Made a lot of thought going through my head.

And of course if anyone else has suggestions feel free to post them!
 

Imp Midna

Active Member
Reaction score
52
Im working on this. I was thinking another integer variable with an if-then-else. Thoughts?
With a shittons of unit types hashtables is what i would go with. You could even put more complex information into it on this way. E.g:
1: Unit kind (healer, melee, magican, ranger etc)
2: prefered attack target kind
3: attack chance
4: spell 1 chance
5: spell 1 prefered attack target kind
6: spell 1
7: spell 2 chance
8: spell 2 prefered attack target kind
9: spell 2 chance
etc...

Using the unit kinds you could also give prioritys (eg a unit with mana burn on its attack may want to primary attack magican units). You can of corse put any information in any structure in there. Its just how i would go i guess.
Remember that you need to use a custom script to write the unit types into an integer variable so you can use it as a hashtable index cause the GUI itself cant convert a unit type into an integer.
 

Solu9

You can change this now in User CP.
Reaction score
216
^yeaaaah... I have not experimented with hashtables yet so Ill leave that for now. I want the general system to work fluidly first. Which brings me further.
I have revamped the pick-turn system and I think it works better and is more simple.
The system works very well with some minor problems which I can't figure out to solve.

You have to look a the map to understand these problem but here they are:
1-The random timer number the different units get in the beginning of the fight screws up the turns BUT ONLY IF the random number is the same thus they will get their turn at the exact same time. I need to detect if the numbers are the same and tweak one of them by 1 point or so. Don't know how yet.
2-For some odd reason the units (after they have attacked) is given another attack order and they run towards their target EVEN THOUGH they first were ordered to run back, their acquisition range is 0, they are paused (even twice). I have searched and searched for the problem but can't find it.

Map with the new system has been attached to this post.

EDIT:
I have discovered that problem number 2 occurs if the unit is ordered to attack two turns in a row. Still I have no idea why.
 

Attachments

  • Turn Based Battle Test -2.w3x
    35.5 KB · Views: 181

thorhunter

You can change this now in User CP.
Reaction score
32
For this to work you must get rid of the vanilla contents. Disable attack on units, make it triggered as spell, add animations, special effects, dummy units. Same for other abilities, trigger each effect and damage (or expect bugs like unit being invunerable because its paused and casted sleep upon itself, because it makes it invunerable for a second. It's good pausing unit sustains buffs for this case, but there are many abilities and many unexpected complications they can cause.)

As I mentioned before, make every action with 'unit starts an effect of ability', trigger the rest (unit animations, damage, mana loss). This way you will avoid 'waits' in triggers and therefore disable multiple actions for units per turn.

The timer trigger could use some work. Instead of multiple variables you could use array (I don't think you need to distinguish enemies form allies, atleast not at this point, not in this trigger) and put everything into one loop. Additionally, make 'if/then/else statement' above all that will check the loop again if the timer isn't 100 for anybody before increasing timer values for each unit, this will prevent skipping someone if there are more than one units with timer value at 100 at the same time.

Overall, at this point this system can't be effectively used by any map, but looking how it vastly improved from the first version, you can probably address the issues pretty effectively.

PS: I'm a fan of Final Fantasy series and even thought about making a map with similar mechanics myself, but I had other projects around and it seems like I'm better in constructing effective systems rather than actual content, so it would take forever. You should try Final Fantasy Forever map if you haven't yet, just I just threw it there because it's really great map.
 

Solu9

You can change this now in User CP.
Reaction score
216
@thorhunter.
Thanks for the feedback.

You suggestion about making every action triggered have crossed my mind. But I have stalled it for the time being. Though I think the idea is good and you are definitely right in saying it will solve some of the bugs.
I'll look into it later on in the system progress.

I have revamped, or evolved if you wish, the turn system even further now.
-Every unit has its own timer and therefore its possible for different units to attack at the same time.
-Added a "show timer" multiboard (for bug finding) so you can see who's turn is up next.
-The number beneath the timer is the timer cooldown for the ranger to see if the altered timer worked with the cheese item in the inventory. (It does work)
-The system "should" work with no problems. I realize if stun etc. abilities are used there will still be possible bugs occurring.*
-The attack trigger has been simplified.
-Please note that the battle camera can now be shown from four different angles ;) (Just because it's awesome).
-The Spider and Murloc will sometimes not attack even though they reach their target.

I know that most of the triggers for attacking/timer/set unit and so on are merely copy/paste. I did it in this fashion to make it easier for myself to view and change.

*Even though this is merely a system and not a map I did plan on using it in a map at some point. In said map there were not going to be any "real" stun abilities or the like
(fx. sleep). I DID have a sleep spell planned but this was going to stop the targeted unit's timer rather than the unit itself, same would go for the spell "Stop" (kinda like storm bolt(stuns)) where it would merely stop the timer instead of actually stunning the target.

I have attached a new map with the (hopefully) improvements. Map version 3.

Note. As usual feedback is more than welcome.

Edit:
I know the timers are a bit slow. Again, this is merely for easy bug finding.
 

Attachments

  • Turn Based Battle Test -3.w3x
    55.8 KB · Views: 205
General chit-chat
Help Users
  • The Helper The Helper:
    I just got to watch the video because even though I was there I was trying to work out tech problems with the chat since I was the social media guy so I was distracted but check it out guys the video is super fucking great!
    +1
  • WildTurkey WildTurkey:
    is there a stephen green in the house?
    +1
  • The Helper The Helper:
    What is up WildTurkey?
  • The Helper The Helper:
    Looks like Google fixed whatever mistake that made the recipes on the site go crazy and we are no longer trending towards a recipe site lol - I don't care though because it motivated me to spend alot of time on the site improving it and at least now the content people are looking at is not stupid and embarrassing like it was when I first got back into this like 5 years ago.
  • The Helper The Helper:
    Plus - I have a pretty bad ass recipe collection now! That section of the site is 10 thousand times better than it was before
  • The Helper The Helper:
    We now have a web designer at my job. A legit talented professional! I am going to get him to redesign the site theme. It is time.
  • Varine Varine:
    I got one more day of community service and then I'm free from this nonsense! I polished a cop car today for a funeral or something I guess
  • Varine Varine:
    They also were digging threw old shit at the sheriff's office and I tried to get them to give me the old electronic stuff, but they said no. They can't give it to people because they might use it to impersonate a cop or break into their network or some shit? idk but it was a shame to see them take a whole bunch of radios and shit to get shredded and landfilled
  • The Helper The Helper:
    whatever at least you are free
  • Monovertex Monovertex:
    How are you all? :D
    +1
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top