I want to create an abstraction layer between my Jython Script objects and my Game Objects. I am not making the all of the engine in Jython. Most of my game logic is in Java. I just want to expose high level functionality. I am thinking of using these classes.
Jython Objectis created using a Jython class and a Java interface that is coerced into java.
Abstraced Mapare objects with get() functions that limit the exposure of the underlying Game Map and Game Object.
Game Mapare the underlying Java objects. They are wrapper classes for a component based system.
Action Factoryprovide functionality to
Jython Object. My game is a turn based tactic, so any change in the game board is done by a set of generic actions (move, damage, apply buff, etc).
This is the first time I have tried to implement a scripting system. The goal is be able to design objects and abilities in Jython. Also create a modding system. I have read several places that creating an abstraction layer is a good idea. I am just not sure how to do it.