GameEngineUser.h 781 B

12345678910111213141516171819202122232425262728
  1. /*
  2. * GameEngineUser.h, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #pragma once
  11. class IGameEngineUser
  12. {
  13. public:
  14. ~IGameEngineUser() = default;
  15. /// Called when user presses hotkey that activates global lobby
  16. virtual void onGlobalLobbyInterfaceActivated() = 0;
  17. /// Called on every game tick for game to update its state
  18. virtual void onUpdate() = 0;
  19. /// Called when app shutdown has been requested in any way - exit button, Alt-F4, etc
  20. virtual void onShutdownRequested(bool askForConfirmation) = 0;
  21. /// Returns true if all input events should be captured and ignored
  22. virtual bool capturedAllEvents() = 0;
  23. };