Turn based grid system

Gamewolf3000

Member
Reaction score
1
So I am working on a project which is going to use a battle system similair to the one that might and magic uses ( you have your units in a grid and take your turns moving, attacking and stuff). But I have barely any idea of how to do this in the editor. First of all the units need to have standard movement and attack disabled so they don't start running around and/or attacking at random, but also i need some sort of turn system, for things like buffs and stuff (for example an attack buff that lasted for 3 turns).

All and any help is very much appreciated.
 

Solu9

You can change this now in User CP.
Reaction score
216
Not to be rude.
But you are kinda asking for a whole system. I don't think anybody is going to guide you through that unless you have a sketch of the system ready.
 

death_knight

Dark is the heart of a corrupted man.
Reaction score
24
Solu9 is right: it does sound like that and nobody will make a complete system for you.

I must warn you though that this system is likely to be very large, difficult and very inter-dependent with other aspects of your map. This will make it inherently complicated. So before trying to implement it, sort out the other aspects of your map and try and have an idea of what your going to be doing, otherwise you'll have no hope of being able to doing this.

That being said, I would assume that a major component of doing a turn-based battle system in WC3 would be disabling user control for all players except the one whose turn it is.

Good luck with it! And I hope you manage to complete it! :)
 

KaerfNomekop

Swim, fishies. Swim through the veil of steel.
Reaction score
613
Ward classification and/or pausing units would help with this.
 

Ayanami

칼리
Reaction score
288
I'm currently working on a map that uses grid-based system as well. For the grid, I basically used a struct with 4 "pointers", pointing north east south and west. It isn't too complicated as long as you have some experience with programming.

The actual tough part is the path generation algorithm. You need to take account of how the units will actually travel throughout the grid and detect obstructions, etc. I found A* algorithm especially useful for this part; pretty simple and efficient.

Do note that all these grid-generation code can be quite heavy in terms of operation, thus can lead to the operation limit if you're not careful.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top