1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-11-12 22:02:49 +01:00
openrw/rwgame/game.hpp
Daniel Evans 3c665e7d2b Add many opcodes, implement some of them.
+ Fix thread-relative jumps
+ GameObject::setHeading(degrees) sets object rotation from a heading.
+ Add More GameState from opcodes.
+ Decouple game hours from the engine clock
+ Add VehicleObject::setRotation()
+ Add GameWorld::getGroundAtPosition(pos) for OpCodes
+ Fix Handling of fixed-point SCM parameters
+ Update IngameState to use GameState::player if it exists
+ Add skip-time button to skip opening cutscene (F12)
2014-07-27 00:44:21 +01:00

38 lines
902 B
C++

#ifndef GAME_HPP
#define GAME_HPP
#include <SFML/Window.hpp>
#include <SFML/Graphics.hpp>
#include <engine/GameObject.hpp>
#include <engine/GameWorld.hpp>
constexpr double PiOver180 = 3.1415926535897932384626433832795028/180;
// TODO: Move all of this stuff so it's not just lying around.
bool hitWorldRay(glm::vec3& hit, glm::vec3& normal, GameObject** object = nullptr);
bool hitWorldRay(const glm::vec3& start, const glm::vec3& direction,
glm::vec3& hit, glm::vec3& normal, GameObject** object = nullptr);
sf::Window& getWindow();
GameWorld* getWorld();
CharacterObject* getPlayerCharacter();
void setPlayerCharacter(CharacterObject* playerCharacter);
sf::Font& getFont();
/**
Set view parameters.
*/
void setViewParameters(const glm::vec3& center, const glm::vec2 &angles);
glm::vec3& getViewPosition();
glm::vec2& getViewAngles();
void skipTime(float time);
#endif // GAME_HPP