Saturday 27 February 2016

Continuing with A*

Continuing on from my last post, Further Implementing A*, I have continued to refine its implementation into the game.

I have now got units following the path given to them, with the path being fixed upon starting movement. The unit will now appear at the end of the path, moving to each position, currently instantaneously, so there is no visual representation of movement displayed. 


Units now have a movement limit. While a path can be drawn across the grid, the unit will only move as many spaces as its move limit allows it to.


I am still having issues with diagonal movement. I believe that I will need to adjust the neighbours being found in the grid class, and the values being assigned for movement in the pathfinding class. While I have looked online for various solutions, e.g. Stack Overflows answers (A star algorithm without diagonal movement) but so far have been unable to find anything that I can grasp and adapt to my current code.


Now that I have the units moving along their given path, I feel I have a couple of choices on how to progress:



  • Continue with the pathfinding
    • Pros
      • Attempt to remove diagonal movement
      • Create visualisation of unit paths and movement
    • Cons
      • Been previously delayed by pathfinding issues, do not want to repeat
      • Could cause further delays in timeline
  • Implement AI
    • Pros
      • Get back on track with timeline
      • Potentially make progress on a personally worrying aspect of the project
      • A fresh aspect of the project to break me away from pathfinding
    • Cons
      • Would need to refine later down the road once weaponry have been implemented
  • Implement weaponry and inventory
    • Pros
      • A fresh aspect of the project to break me away from pathfinding
      • Ready for AI implementation
    • Cons
      • Takes focus away from other key areas of the project
I believe, when broken down, my best bet would be to look towards weaponry implementation now. I add " A fresh aspect of the project to break me away from pathfinding" as a pro, as I believe that if I focus too much time and effort into this singular aspect, a mountain will be made out of a molehill, and I will be less and less inclined to work on the project out of fear/panic. 

By shifting away from pathfinding, even if it's for just one week, I will be able to approach it again from a fresh angle, that will aid me in finalising it. While there are still more Pros leaning towards AI implementation, I feel the extra work that would be required later down the road, to alter the AI to work with weaponry, is completely unneeded extra work. 

Should I implement weaponry now, shifting the Rock-Paper-Scissor system over onto that, I will be able to focus much more heavily on the AI, without having to overhaul it later on. While it does throw off the order of my timeline, I should be able to end up in the same position as I would be following my current order, whereas I worry that AI implementation or continuing pathfinding will delay me further.


Week
Timeline
New Timeline Milestones
15
Refine the RPS system, and introduce weapons that break away from the base system
Implement what I have learnt about A* into the current build of the game, so player units move using the A* pathfinding
16
Refine AI within the game, so they can intelligently attack units based on position and weapon
Ensure that the A* pathfinding is correctly implemented, and look to implementing terrain modifiers within the map
17
Continue to refine AI
Research further and implement AI into the game, ideally with refined goal-seeking mechanics
18
Implement an inventory system, allowing units to equip different weapons, and the use of a health potion item
Ensure the AI is functioning to an optimal level, able to seek out the most efficient target
19
Look into a levelling system, and how this can be implemented
Implement a weapons system to take on the RPS system
20
Implement the levelling system, and start refining stats mechanics
Ensure the weapons system functions correctly, and research into levelling mechanics
Easter Break
Refine the unique support concept, creating a document outlining the mechanic, and its uses
Refine the unique support concept, creating a document outlining the mechanic, and its uses
Easter Break
Continue to refine the support mechanic, and start implementation if possible
Continue to refine the support mechanic, and start implementation if possible
21
Ensure the AI, movement, levelling, and combat mechanics are operating as desired
Finalise support mechanic implementation, and refine stats for combat mechanics
22
Start looking into a mobile conversion, and implement if possible
Ensure that any map modifiers are functioning correctly, and AI is functioning efficiently
23
Start or continue to implement mobile conversion
Look to start moible conversion
24
Finalise mobile conversion
Finalise mobile conversion


No comments:

Post a Comment