I've been spending the last few days thinking on how to best implement the spells in the game I'm working on. This might or might not be a waste of time, but I want to make sure I dont design and code something that will cause me headaches later on.
Basically, most actions the user or AI performs in my game are "abilities" that are executed. Opening the map executes the OpenMapAbility::Execute(), moving on the battle map executes MoveAbility::Execute() and so forth.
My worry with this design is that while having the game actions performed by each of the abilities classes (inside their Execute() function), they require access to only part of the game core they modify/use, but I foresee a lot of maintenance using this system, as changes to the core game might require modifying tons and tons of classes in order to handle the changes.
Another way to do it would be to use a super class that takes as input the ability to cast, which seems like a better way to manage things, but then the class becomes very large, and instead of requiring just a few dependencies, it requires much more access to the game world.
I guess my question is, what would be the best way to manage a pretty extensive set of abilities/game actions, allowing for easy changes to be made, and given the fact that I quite inexperienced, I need to implement a system that wont be a nightmare.
Sorry for my not so amazing English, and thanks for any inputs, my searches on Google were of no help!