Scene.pkg 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. $#include "Scene.h"
  2. static const unsigned FIRST_REPLICATED_ID;
  3. static const unsigned LAST_REPLICATED_ID;
  4. static const unsigned FIRST_LOCAL_ID;
  5. static const unsigned LAST_LOCAL_ID;
  6. class Scene : public Node
  7. {
  8. Scene(Context* context);
  9. virtual ~Scene();
  10. bool LoadXML(Deserializer& source);
  11. bool SaveXML(Serializer& dest) const;
  12. bool LoadAsync(File* file);
  13. bool LoadAsyncXML(File* file);
  14. void StopAsyncLoading();
  15. void Clear();
  16. void SetUpdateEnabled(bool enable);
  17. void SetTimeScale(float scale);
  18. void SetElapsedTime(float time);
  19. void SetSmoothingConstant(float constant);
  20. void SetSnapThreshold(float threshold);
  21. Node* GetNode(unsigned id) const;
  22. Component* GetComponent(unsigned id) const;
  23. bool IsUpdateEnabled() const;
  24. bool IsAsyncLoading() const;
  25. float GetAsyncProgress() const;
  26. const String& GetFileName() const;
  27. unsigned GetChecksum() const;
  28. float GetTimeScale() const;
  29. float GetElapsedTime() const;
  30. float GetSmoothingConstant() const;
  31. float GetSnapThreshold() const;
  32. const String& GetVarName(ShortStringHash hash) const;
  33. void Update(float timeStep);
  34. void BeginThreadedUpdate();
  35. void EndThreadedUpdate();
  36. void DelayedMarkedDirty(Component* component);
  37. bool IsThreadedUpdate() const;
  38. unsigned GetFreeNodeID(CreateMode mode);
  39. unsigned GetFreeComponentID(CreateMode mode);
  40. void NodeAdded(Node* node);
  41. void NodeRemoved(Node* node);
  42. void ComponentAdded(Component* component);
  43. void ComponentRemoved(Component* component);
  44. void SetVarNamesAttr(String value);
  45. String GetVarNamesAttr() const;
  46. void PrepareNetworkUpdate();
  47. void CleanupConnection(Connection* connection);
  48. void MarkNetworkUpdate(Node* node);
  49. void MarkNetworkUpdate(Component* component);
  50. void MarkReplicationDirty(Node* node);
  51. tolua_property__is_set bool updateEnabled;
  52. tolua_readonly tolua_property__is_set bool asyncLoading;
  53. tolua_readonly tolua_property__get_set float asyncProgress;
  54. tolua_property__get_set const String& fileName;
  55. tolua_readonly tolua_property__get_set unsigned checksum;
  56. tolua_property__get_set float timeScale;
  57. tolua_property__get_set float elapsedTime;
  58. tolua_property__get_set float smoothingConstant;
  59. tolua_property__get_set float snapThreshold;
  60. tolua_readonly tolua_property__is_set bool threadedUpdate;
  61. tolua_property__get_set String varNamesAttr;
  62. };