SceneEditor3DEvents.h 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. //
  2. // Copyright (c) 2014-2016 THUNDERBEAST GAMES LLC
  3. //
  4. // Permission is hereby granted, free of charge, to any person obtaining a copy
  5. // of this software and associated documentation files (the "Software"), to deal
  6. // in the Software without restriction, including without limitation the rights
  7. // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  8. // copies of the Software, and to permit persons to whom the Software is
  9. // furnished to do so, subject to the following conditions:
  10. //
  11. // The above copyright notice and this permission notice shall be included in
  12. // all copies or substantial portions of the Software.
  13. //
  14. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  15. // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  16. // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  17. // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  18. // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  19. // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  20. // THE SOFTWARE.
  21. //
  22. #pragma once
  23. #include <Atomic/Core/Object.h>
  24. namespace AtomicEditor
  25. {
  26. /// Variable timestep scene update.
  27. EVENT(E_GIZMOEDITMODECHANGED, GizmoEditModeChanged)
  28. {
  29. PARAM(P_MODE, Mode); // int
  30. }
  31. EVENT(E_GIZMOAXISMODECHANGED, GizmoAxisModeChanged)
  32. {
  33. PARAM(P_MODE, Mode); // int
  34. }
  35. EVENT(E_GIZMOMOVED, GizmoMoved)
  36. {
  37. }
  38. EVENT(E_SCENENODESELECTED, SceneNodeSelected)
  39. {
  40. PARAM(P_SCENE, Scene); // Scene
  41. PARAM(P_NODE, Node); // Node
  42. PARAM(P_SELECTED, Selected); // bool
  43. PARAM(P_QUIET, Quiet); // bool (don't record edit event)
  44. }
  45. EVENT(E_SCENEEDITBEGIN, SceneEditBegin)
  46. {
  47. PARAM(P_SCENE, Scene); // Scene
  48. }
  49. EVENT(E_SCENEEDITNODEREPARENT, SceneEditNodeReparent)
  50. {
  51. PARAM(P_NODE, Node); // Node
  52. PARAM(P_ADDED, Added); // Boolean
  53. }
  54. EVENT(E_SCENEEDITEND, SceneEditEnd)
  55. {
  56. PARAM(P_SCENE, Scene); // Scene
  57. }
  58. EVENT(E_SCENEEDITSTATECHANGESBEGIN, SceneEditStateChangesBegin)
  59. {
  60. }
  61. EVENT(E_SCENEEDITSTATECHANGE, SceneEditStateChange)
  62. {
  63. PARAM(P_SERIALIZABLE, Serializable); // Serializable
  64. }
  65. EVENT(E_SCENEEDITSTATECHANGESEND, SceneEditStateChangesEnd)
  66. {
  67. }
  68. /// A child node has been added to a parent node.
  69. EVENT(E_SCENEEDITNODECREATED, SceneEditNodeCreated)
  70. {
  71. PARAM(P_NODE, Node); // Node pointer
  72. }
  73. /// A child node has been added to a parent node.
  74. EVENT(E_SCENEEDITNODEADDED, SceneEditNodeAdded)
  75. {
  76. PARAM(P_SCENE, Scene); // Scene pointer
  77. PARAM(P_PARENT, Parent); // Node pointer
  78. PARAM(P_NODE, Node); // Node pointer
  79. }
  80. /// A child node is about to be removed from a parent node.
  81. EVENT(E_SCENEEDITNODEREMOVED, SceneEditNodeRemoved)
  82. {
  83. PARAM(P_SCENE, Scene); // Scene pointer
  84. PARAM(P_PARENT, Parent); // Node pointer
  85. PARAM(P_NODE, Node); // Node pointer
  86. }
  87. /// A child node has been added to a parent node.
  88. EVENT(E_SCENEEDITCOMPONENTADDEDREMOVED, SceneEditComponentAddedRemoved)
  89. {
  90. PARAM(P_SCENE, Scene); // Scene pointer
  91. PARAM(P_NODE, Node); // Node pointer
  92. PARAM(P_COMPONENT, Component); // Component pointer
  93. PARAM(P_REMOVED, Removed); // bool
  94. }
  95. EVENT(E_SCENEEDITPREFABSAVE, SceneEditPrefabSave)
  96. {
  97. PARAM(P_NODE, Node); // Node pointer
  98. }
  99. EVENT(E_SCENEEDITPREFABREVERT, SceneEditPrefabRevert)
  100. {
  101. PARAM(P_NODE, Node); // Node pointer
  102. }
  103. EVENT(E_SCENEEDITPREFABCOPY, SceneEditPrefabCopy)
  104. {
  105. PARAM(P_NODE, Node); // Node pointer
  106. }
  107. EVENT(E_SCENEEDITPREFABPASTE, SceneEditPrefabPaste)
  108. {
  109. PARAM(P_NODE, Node); // Node pointer
  110. }
  111. EVENT(E_SCENEEDITPREFABBREAK, SceneEditPrefabBreak)
  112. {
  113. PARAM(P_NODE, Node); // Node pointer
  114. }
  115. EVENT(E_SCENEEDITCOMPONENTCOPY, SceneEditComponentCopy)
  116. {
  117. PARAM(P_COMPONENT, Component); // Component pointer
  118. }
  119. EVENT(E_SCENEEDITCOMPONENTPASTE, SceneEditComponentPaste)
  120. {
  121. PARAM(P_COMPONENT, Component); // Component pointer
  122. PARAM(P_END, End); // bool
  123. }
  124. EVENT(E_SCENEEDITADDREMOVENODES, SceneEditAddRemoveNodes)
  125. {
  126. PARAM(P_END, End); // bool
  127. }
  128. EVENT(E_SCENEEDITSCENEMODIFIED, SceneEditSceneModified)
  129. {
  130. }
  131. EVENT(E_CUBEMAPRENDERBEGIN, CubemapRenderBegin)
  132. {
  133. }
  134. EVENT(E_CUBEMAPRENDEREND, CubemapRenderEnd)
  135. {
  136. }
  137. }