public SceneManager() { IsSceneInitialized = false; CmdBinder.AddBinding <ChangeSceneCmd>(OnChangeScene); CmdBinder.AddBinding <SceneLoadedCmd>(OnSceneLoaded); CmdBinder.AddBinding <LoadNextSceneCmd>(OnLoadNextScene); Factory.Factory.SetConstructor <SceneView>(ConstructSceneView); }
public void Initialize() { // check for configuration file if (!LoadFromConfig()) { CreateDefaultOptions(); } CmdBinder.AddBinding <ApplyOptionsCmd>(OnApplyOptions); Framework.PushCommand(new ApplyOptionsCmd()); }
/// <summary> /// Implement IDestroyable to remove bindings on scene exit /// </summary> public void Destroy() { CmdBinder.RemoveBinding <PlayerEquipItemRequestCmd <TrinketItem> >(OnEquipItemRequest <TrinketItem>); CmdBinder.RemoveBinding <PlayerEquipItemRequestCmd <WeaponItem> >(OnEquipItemRequest <WeaponItem>); CmdBinder.RemoveBinding <PlayerEquipItemRequestCmd <ArmorItem> >(OnEquipItemRequest <ArmorItem>); }
public Player() { CmdBinder.AddBinding <PlayerEquipItemRequestCmd <TrinketItem> >(OnEquipItemRequest <TrinketItem>); CmdBinder.AddBinding <PlayerEquipItemRequestCmd <WeaponItem> >(OnEquipItemRequest <WeaponItem>); CmdBinder.AddBinding <PlayerEquipItemRequestCmd <ArmorItem> >(OnEquipItemRequest <ArmorItem>); }
/// <summary> /// /// </summary> /// <param name="diskAccess">If diskAccess is false EngineOptions will initialize to it's default values /// and never write or read itself from the disk (for web platform)</param> public App() { CmdBinder.AddBinding <ApplyOptionsCmd>(OnApplyOptions); }