diff --git a/GameEngine/resources/GameEngineTest.model b/GameEngine/resources/GameEngineTest.model new file mode 100644 index 0000000..4b5a525 --- /dev/null +++ b/GameEngine/resources/GameEngineTest.model @@ -0,0 +1,39 @@ +channel KeyEvent { + out state(curState:Int,keyEvent(nextState)) = nextState +} +channel SceneUpdateEvent { + out time(time:Long,updateEvent(dt:Long)) = (time+dt) +} +channel TimerEvent { + out count(count:Long,tick()) = (count+1) +} +channel EntitySpriteUpdate { + in mesh(curMesh:Json,updateSprite(spritePath:Str)) = {"sprite": spritePath, "type": "sprite"} +} +channel EntityScaleUpdate { + in scale(curScale:Json,updateScale(nextScale.{x},nextScale.{y},nextScale.{z})) = nextScale +} +channel EntityPositionUpdate { + in position(curPos:Json,updatePosition(nextPos.{x},nextPos.{y},nextPos.{z})) = nextPos +} +channel CameraProjectionUpdate { + in projection(curProj:Json,updateProjection(curProj,nextProj)) = nextProj +} +channel TimersUpdated { + in timers(curTimers:Map,update(curTimers,nextTimers)) = nextTimers +} +channel CameraPositionUpdate { + in position(curPos:Json,updatePosition(nextPos.{x},nextPos.{y},nextPos.{z})) = nextPos +} +channel SceneUpdate { + in scene(curSc:Json,update(curSc,nextSc)) = nextSc +} +channel CameraScaleUpdate { + in scale(curScale:Json,updateScale(nextScale.{x},nextScale.{y},nextScale.{z})) = nextScale +} +channel EntityRotationUpdate { + in rotation(curRot:Json,updateRotation(nextRot.{x},nextRot.{y},nextRot.{z})) = nextRot +} +channel CameraRotationUpdate { + in rotation(curRot:Json,updateRotation(nextRot.{x},nextRot.{y},nextRot.{z})) = nextRot +}