fps_example.tscn 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601
  1. [gd_scene load_steps=26 format=2]
  2. [ext_resource path="res://addons/sade/editor_gizmo_texture.png" type="Texture2D" id=1]
  3. [ext_resource path="res://button_change_scene.gd" type="Script" id=2]
  4. [ext_resource path="res://fps/example_player.gd" type="Script" id=3]
  5. [ext_resource path="res://addons/sade/ik_look_at.gd" type="Script" id=4]
  6. [ext_resource path="res://addons/sade/ik_look_at.png" type="Texture2D" id=5]
  7. [ext_resource path="res://addons/sade/ik_fabrik.gd" type="Script" id=6]
  8. [ext_resource path="res://addons/sade/ik_fabrik.png" type="Texture2D" id=7]
  9. [ext_resource path="res://fps/weapon_pistol.dae" type="PackedScene" id=8]
  10. [ext_resource path="res://fps/gun_color.tres" type="Material" id=9]
  11. [ext_resource path="res://fps/gun_emission.tres" type="Material" id=10]
  12. [ext_resource path="res://model/godot_battle_bot.dae" type="PackedScene" id=11]
  13. [ext_resource path="res://model/battle_bot_color.tres" type="Material" id=12]
  14. [ext_resource path="res://model/battle_bot_emission.tres" type="Material" id=13]
  15. [sub_resource type="PlaneMesh" id=1]
  16. size = Vector2(40, 40)
  17. [sub_resource type="StandardMaterial3D" id=2]
  18. albedo_texture = ExtResource( 1 )
  19. roughness = 0.2
  20. uv1_scale = Vector3(0.25, 0.25, 0.25)
  21. uv1_triplanar = true
  22. [sub_resource type="BoxShape3D" id=3]
  23. extents = Vector3(20, 1, 20)
  24. [sub_resource type="BoxMesh" id=4]
  25. size = Vector3(4, 4, 4)
  26. [sub_resource type="StandardMaterial3D" id=5]
  27. albedo_color = Color(0.148438, 1, 0, 1)
  28. albedo_texture = ExtResource( 1 )
  29. uv1_triplanar = true
  30. [sub_resource type="BoxShape3D" id=6]
  31. extents = Vector3(2, 2, 2)
  32. [sub_resource type="StandardMaterial3D" id=7]
  33. albedo_color = Color(0, 0.882813, 1, 1)
  34. albedo_texture = ExtResource( 1 )
  35. uv1_triplanar = true
  36. [sub_resource type="CapsuleShape3D" id=8]
  37. radius = 4.0
  38. height = 6.0
  39. [sub_resource type="Curve3D" id=9]
  40. _data = {
  41. "points": PackedVector3Array(0, 0, 0, 0, 0, 0, -2.43129, -0.955339, 0, 0, 0, 0, 0, 0, 0, -0.670561, 0.183959, 0, 0, 0, 0, 0, 0, 0, 0.64629, 0.228347, 0, 0, 0, 0, 0, 0, 0, 2.31825, -0.925747, 0),
  42. "tilts": PackedFloat32Array(0, 0, 0, 0)
  43. }
  44. [sub_resource type="Animation" id=10]
  45. tracks/0/type = "value"
  46. tracks/0/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:position")
  47. tracks/0/interp = 1
  48. tracks/0/loop_wrap = true
  49. tracks/0/imported = false
  50. tracks/0/enabled = true
  51. tracks/0/keys = {
  52. "times": PackedFloat32Array(0, 1),
  53. "transitions": PackedFloat32Array(1, 1),
  54. "update": 0,
  55. "values": [Vector3(0.570504, -2.2654, 2.93826), Vector3(0, -1.36445, 3.78817)]
  56. }
  57. tracks/1/type = "value"
  58. tracks/1/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:rotation_degrees")
  59. tracks/1/interp = 1
  60. tracks/1/loop_wrap = true
  61. tracks/1/imported = false
  62. tracks/1/enabled = true
  63. tracks/1/keys = {
  64. "times": PackedFloat32Array(0, 1),
  65. "transitions": PackedFloat32Array(1, 1),
  66. "update": 0,
  67. "values": [Vector3(0, -2, 0), Vector3(0, 0, 0)]
  68. }
  69. tracks/2/type = "value"
  70. tracks/2/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/Camera3D:fov")
  71. tracks/2/interp = 1
  72. tracks/2/loop_wrap = true
  73. tracks/2/imported = false
  74. tracks/2/enabled = true
  75. tracks/2/keys = {
  76. "times": PackedFloat32Array(0, 1),
  77. "transitions": PackedFloat32Array(1, 1),
  78. "update": 0,
  79. "values": [80.0, 60.0]
  80. }
  81. [sub_resource type="Animation" id=11]
  82. tracks/0/type = "value"
  83. tracks/0/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/Camera3D:fov")
  84. tracks/0/interp = 1
  85. tracks/0/loop_wrap = true
  86. tracks/0/imported = false
  87. tracks/0/enabled = true
  88. tracks/0/keys = {
  89. "times": PackedFloat32Array(0, 1),
  90. "transitions": PackedFloat32Array(1, 1),
  91. "update": 0,
  92. "values": [60.0, 80.0]
  93. }
  94. tracks/1/type = "value"
  95. tracks/1/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:position")
  96. tracks/1/interp = 1
  97. tracks/1/loop_wrap = true
  98. tracks/1/imported = false
  99. tracks/1/enabled = true
  100. tracks/1/keys = {
  101. "times": PackedFloat32Array(0, 1),
  102. "transitions": PackedFloat32Array(1, 1),
  103. "update": 0,
  104. "values": [Vector3(0, -1.36445, 3.78817), Vector3(0.570504, -2.2654, 2.93826)]
  105. }
  106. tracks/2/type = "value"
  107. tracks/2/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:rotation_degrees")
  108. tracks/2/interp = 1
  109. tracks/2/loop_wrap = true
  110. tracks/2/imported = false
  111. tracks/2/enabled = true
  112. tracks/2/keys = {
  113. "times": PackedFloat32Array(0, 1),
  114. "transitions": PackedFloat32Array(1, 1),
  115. "update": 0,
  116. "values": [Vector3(0, 0, 0), Vector3(0, -2, 0)]
  117. }
  118. [sub_resource type="Animation" id=12]
  119. tracks/0/type = "value"
  120. tracks/0/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:position")
  121. tracks/0/interp = 1
  122. tracks/0/loop_wrap = true
  123. tracks/0/imported = false
  124. tracks/0/enabled = true
  125. tracks/0/keys = {
  126. "times": PackedFloat32Array(0),
  127. "transitions": PackedFloat32Array(1),
  128. "update": 0,
  129. "values": [Vector3(0.570504, -2.2654, 2.93826)]
  130. }
  131. tracks/1/type = "value"
  132. tracks/1/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos:rotation_degrees")
  133. tracks/1/interp = 1
  134. tracks/1/loop_wrap = true
  135. tracks/1/imported = false
  136. tracks/1/enabled = true
  137. tracks/1/keys = {
  138. "times": PackedFloat32Array(0),
  139. "transitions": PackedFloat32Array(1),
  140. "update": 0,
  141. "values": [Vector3(0, -2, 0)]
  142. }
  143. tracks/2/type = "value"
  144. tracks/2/path = NodePath("LeanPath/PathFollow3D/IK_LookAt_Chest/Camera3D:fov")
  145. tracks/2/interp = 1
  146. tracks/2/loop_wrap = true
  147. tracks/2/imported = false
  148. tracks/2/enabled = true
  149. tracks/2/keys = {
  150. "times": PackedFloat32Array(0),
  151. "transitions": PackedFloat32Array(1),
  152. "update": 0,
  153. "values": [80.0]
  154. }
  155. [node name="FPSExample" type="Node3D"]
  156. [node name="Level" type="Node3D" parent="."]
  157. [node name="Floor" type="MeshInstance3D" parent="Level"]
  158. transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0)
  159. mesh = SubResource( 1 )
  160. surface_material_override/0 = SubResource( 2 )
  161. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Floor"]
  162. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Floor/StaticBody3D"]
  163. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.956119, 0)
  164. shape = SubResource( 3 )
  165. [node name="Walls" type="Node3D" parent="Level"]
  166. [node name="LargeWall" type="MeshInstance3D" parent="Level/Walls"]
  167. transform = Transform3D(1, 0, 0, 0, 10, 0, 0, 0, 10, -39.9997, 20.0003, 20.0002)
  168. mesh = SubResource( 4 )
  169. surface_material_override/0 = SubResource( 5 )
  170. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall"]
  171. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall/StaticBody3D"]
  172. shape = SubResource( 6 )
  173. [node name="LargeWall2" type="MeshInstance3D" parent="Level/Walls"]
  174. transform = Transform3D(1, 0, 0, 0, 10, 0, 0, 0, 10, -39.9997, 20.0003, -19.9998)
  175. mesh = SubResource( 4 )
  176. surface_material_override/0 = SubResource( 5 )
  177. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall2"]
  178. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall2/StaticBody3D"]
  179. shape = SubResource( 6 )
  180. [node name="LargeWall3" type="MeshInstance3D" parent="Level/Walls"]
  181. transform = Transform3D(-4.37114e-08, 0, -10, 0, 10, 0, 1, 0, -4.37114e-07, -18.9997, 20.0003, -40.9998)
  182. mesh = SubResource( 4 )
  183. surface_material_override/0 = SubResource( 5 )
  184. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall3"]
  185. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall3/StaticBody3D"]
  186. shape = SubResource( 6 )
  187. [node name="LargeWall4" type="MeshInstance3D" parent="Level/Walls"]
  188. transform = Transform3D(-4.37114e-08, 0, -10, 0, 10, 0, 1, 0, -4.37114e-07, 21.0003, 20.0003, -40.9998)
  189. mesh = SubResource( 4 )
  190. surface_material_override/0 = SubResource( 5 )
  191. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall4"]
  192. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall4/StaticBody3D"]
  193. shape = SubResource( 6 )
  194. [node name="LargeWall5" type="MeshInstance3D" parent="Level/Walls"]
  195. transform = Transform3D(-1, 0, 8.74228e-07, 0, 10, 0, -8.74228e-08, 0, -10, 41.0003, 20.0003, -19.9998)
  196. mesh = SubResource( 4 )
  197. surface_material_override/0 = SubResource( 5 )
  198. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall5"]
  199. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall5/StaticBody3D"]
  200. shape = SubResource( 6 )
  201. [node name="LargeWall6" type="MeshInstance3D" parent="Level/Walls"]
  202. transform = Transform3D(-1, 0, 8.74228e-07, 0, 10, 0, -8.74228e-08, 0, -10, 41.0003, 20.0003, 20.0002)
  203. mesh = SubResource( 4 )
  204. surface_material_override/0 = SubResource( 5 )
  205. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall6"]
  206. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall6/StaticBody3D"]
  207. shape = SubResource( 6 )
  208. [node name="LargeWall7" type="MeshInstance3D" parent="Level/Walls"]
  209. transform = Transform3D(1.31134e-07, 0, 10, 0, 10, 0, -1, 0, 1.31134e-06, 21.0003, 20.0003, 40.0002)
  210. mesh = SubResource( 4 )
  211. surface_material_override/0 = SubResource( 5 )
  212. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall7"]
  213. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall7/StaticBody3D"]
  214. shape = SubResource( 6 )
  215. [node name="LargeWall8" type="MeshInstance3D" parent="Level/Walls"]
  216. transform = Transform3D(1.31134e-07, 0, 10, 0, 10, 0, -1, 0, 1.31134e-06, -18.9997, 20.0003, 40.0002)
  217. mesh = SubResource( 4 )
  218. surface_material_override/0 = SubResource( 5 )
  219. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/LargeWall8"]
  220. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/LargeWall8/StaticBody3D"]
  221. shape = SubResource( 6 )
  222. [node name="Wall" type="MeshInstance3D" parent="Level/Walls"]
  223. transform = Transform3D(7.54979e-08, 0, 4, 0, 4, 0, -1, 0, 3.01992e-07, -9.9997, 8.00032, 22.0005)
  224. mesh = SubResource( 4 )
  225. surface_material_override/0 = SubResource( 7 )
  226. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall"]
  227. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall/StaticBody3D"]
  228. shape = SubResource( 6 )
  229. [node name="Wall2" type="MeshInstance3D" parent="Level/Walls"]
  230. transform = Transform3D(1, 0, -4.76837e-07, 0, 4, 0, 1.19209e-07, 0, 4, -19.9997, 8.00032, 16.0005)
  231. mesh = SubResource( 4 )
  232. surface_material_override/0 = SubResource( 7 )
  233. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall2"]
  234. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall2/StaticBody3D"]
  235. shape = SubResource( 6 )
  236. [node name="Wall3" type="MeshInstance3D" parent="Level/Walls"]
  237. transform = Transform3D(1, 0, -3.57627e-07, 0, 4, 0, 1.19209e-07, 0, 3, -19.9997, 8.00032, 2.00049)
  238. mesh = SubResource( 4 )
  239. surface_material_override/0 = SubResource( 7 )
  240. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall3"]
  241. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall3/StaticBody3D"]
  242. shape = SubResource( 6 )
  243. [node name="Wall4" type="MeshInstance3D" parent="Level/Walls"]
  244. transform = Transform3D(1, 0, -4.76837e-07, 0, 4, 0, 1.19209e-07, 0, 4, -19.9997, 8.00032, -21.9995)
  245. mesh = SubResource( 4 )
  246. surface_material_override/0 = SubResource( 7 )
  247. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall4"]
  248. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall4/StaticBody3D"]
  249. shape = SubResource( 6 )
  250. [node name="Wall5" type="MeshInstance3D" parent="Level/Walls"]
  251. transform = Transform3D(-1.62921e-07, 0, -4, 0, 4, 0, 1, 0, -6.51683e-07, -9.9997, 8.00032, -27.9995)
  252. mesh = SubResource( 4 )
  253. surface_material_override/0 = SubResource( 7 )
  254. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall5"]
  255. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall5/StaticBody3D"]
  256. shape = SubResource( 6 )
  257. [node name="Wall6" type="MeshInstance3D" parent="Level/Walls"]
  258. transform = Transform3D(-1, 0, 8.26528e-07, 0, 4, 0, -2.06632e-07, 0, -4, 0.000319004, 8.00032, -21.9995)
  259. mesh = SubResource( 4 )
  260. surface_material_override/0 = SubResource( 7 )
  261. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall6"]
  262. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall6/StaticBody3D"]
  263. shape = SubResource( 6 )
  264. [node name="Wall7" type="MeshInstance3D" parent="Level/Walls"]
  265. transform = Transform3D(-1.62921e-07, 0, -4, 0, 4, 0, 1, 0, -6.51683e-07, 10.0003, 8.00032, -15.9995)
  266. mesh = SubResource( 4 )
  267. surface_material_override/0 = SubResource( 7 )
  268. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall7"]
  269. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall7/StaticBody3D"]
  270. shape = SubResource( 6 )
  271. [node name="Wall9" type="MeshInstance3D" parent="Level/Walls"]
  272. transform = Transform3D(1, 0, -4.76837e-07, 0, 4, 0, 1.19209e-07, 0, 4, 25.0003, 8.00032, -25.9995)
  273. mesh = SubResource( 4 )
  274. surface_material_override/0 = SubResource( 7 )
  275. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall9"]
  276. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall9/StaticBody3D"]
  277. shape = SubResource( 6 )
  278. [node name="Wall10" type="MeshInstance3D" parent="Level/Walls"]
  279. transform = Transform3D(0.573577, 0, 3.27661, 0, 4, 0, -0.819152, 0, 2.29431, 23.0003, 8.00032, 3.00049)
  280. mesh = SubResource( 4 )
  281. surface_material_override/0 = SubResource( 7 )
  282. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall10"]
  283. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall10/StaticBody3D"]
  284. shape = SubResource( 6 )
  285. [node name="Wall11" type="MeshInstance3D" parent="Level/Walls"]
  286. transform = Transform3D(-0.819152, 0, 2.29431, 0, 4, 0, -0.573577, 0, -3.27661, 22.2126, 8.00032, 14.7123)
  287. mesh = SubResource( 4 )
  288. surface_material_override/0 = SubResource( 7 )
  289. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall11"]
  290. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall11/StaticBody3D"]
  291. shape = SubResource( 6 )
  292. [node name="Wall12" type="MeshInstance3D" parent="Level/Walls"]
  293. transform = Transform3D(-0.627507, 2.10616, 2.29431, 0.642788, 3.06418, 0, -0.439385, 1.47475, -3.27661, 14.8402, 8.00032, 9.55015)
  294. mesh = SubResource( 4 )
  295. surface_material_override/0 = SubResource( 7 )
  296. [node name="StaticBody3D" type="StaticBody3D" parent="Level/Walls/Wall12"]
  297. [node name="CollisionShape3D" type="CollisionShape3D" parent="Level/Walls/Wall12/StaticBody3D"]
  298. shape = SubResource( 6 )
  299. [node name="DirectionalLight3D" type="DirectionalLight3D" parent="."]
  300. transform = Transform3D(0.388878, -0.754027, 0.529355, 0, 0.574581, 0.818448, -0.921289, -0.318277, 0.223442, -9.77531, 11.5204, 11.766)
  301. light_color = Color(1, 0.925598, 0.820313, 1)
  302. shadow_enabled = true
  303. directional_shadow_mode = 0
  304. [node name="Control" type="Control" parent="."]
  305. anchor_right = 1.0
  306. anchor_bottom = 1.0
  307. [node name="Panel" type="Panel" parent="Control"]
  308. modulate = Color(1, 1, 1, 0.784314)
  309. anchor_top = 1.0
  310. anchor_right = 1.0
  311. anchor_bottom = 1.0
  312. offset_left = -2.0
  313. offset_top = -70.0
  314. offset_right = 4.0
  315. [node name="Label" type="Label" parent="Control/Panel"]
  316. anchor_right = 1.0
  317. anchor_bottom = 1.0
  318. offset_left = 12.0
  319. offset_top = 10.0
  320. offset_right = -18.0
  321. offset_bottom = -29.0
  322. text = "F.A.B.R.I.K IK Example use case: Dynamic FPS Animations
  323. Controls: WASD/Arrows to move, left click to fire, right click to look down sights, Q/E to lean left/right
  324. Escape to free/lock mouse cursor"
  325. align = 1
  326. valign = 1
  327. [node name="ButtonPrev" type="Button" parent="Control"]
  328. anchor_top = 1.0
  329. anchor_bottom = 1.0
  330. offset_left = 10.0
  331. offset_top = -60.0
  332. offset_right = 129.0
  333. offset_bottom = -10.0
  334. text = "Previous scene"
  335. script = ExtResource( 2 )
  336. __meta__ = {
  337. "_edit_use_anchors_": false
  338. }
  339. scene_to_change_to = "res://skeleton_ik.tscn"
  340. [node name="Crosshair" type="Control" parent="Control"]
  341. modulate = Color(1, 1, 1, 0.784314)
  342. anchor_left = 0.5
  343. anchor_top = 0.5
  344. anchor_right = 0.5
  345. anchor_bottom = 0.5
  346. offset_left = -20.0
  347. offset_top = -20.0
  348. offset_right = 20.0
  349. offset_bottom = 20.0
  350. __meta__ = {
  351. "_edit_use_anchors_": false
  352. }
  353. [node name="ColorRect" type="ColorRect" parent="Control/Crosshair"]
  354. offset_left = 19.0
  355. offset_right = 21.0
  356. offset_bottom = 40.0
  357. __meta__ = {
  358. "_edit_use_anchors_": false
  359. }
  360. [node name="ColorRect2" type="ColorRect" parent="Control/Crosshair"]
  361. offset_left = 40.0
  362. offset_top = 18.0
  363. offset_right = 42.0
  364. offset_bottom = 58.0
  365. rotation = 90.0
  366. [node name="CharacterBody3D" type="CharacterBody3D" parent="."]
  367. script = ExtResource( 3 )
  368. [node name="CollisionShape3D" type="CollisionShape3D" parent="CharacterBody3D"]
  369. transform = Transform3D(1, 0, 0, 0, -4.37114e-08, -1, 0, 1, -4.37114e-08, 0, 7, 0)
  370. shape = SubResource( 8 )
  371. [node name="CameraHolder" type="Node3D" parent="CharacterBody3D"]
  372. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 13, 0)
  373. [node name="LeanPath" type="Path3D" parent="CharacterBody3D/CameraHolder"]
  374. curve = SubResource( 9 )
  375. [node name="PathFollow3D" type="PathFollow3D" parent="CharacterBody3D/CameraHolder/LeanPath"]
  376. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0412404, 0.205172, 0)
  377. offset = 2.71865
  378. rotation_mode = 0
  379. loop = false
  380. [node name="IK_LookAt_Chest" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D"]
  381. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.451559, 0)
  382. script = ExtResource( 4 )
  383. __meta__ = {
  384. "_editor_icon": ExtResource( 5 )
  385. }
  386. skeleton_path = NodePath("../../../../GodotBattleBot/Armature/Skeleton3D")
  387. bone_name = "Chest"
  388. look_at_axis = 2
  389. additional_rotation = Vector3(-10, 0, 0)
  390. [node name="Camera3D" type="Camera3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest"]
  391. transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0, 0)
  392. fov = 74.0
  393. [node name="AimPos" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest"]
  394. transform = Transform3D(0.999391, 0, -0.0348995, 0, 1, 0, 0.0348995, 0, 0.999391, 0.570504, -2.2654, 2.93826)
  395. [node name="IK_FABRIK" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos"]
  396. script = ExtResource( 6 )
  397. __meta__ = {
  398. "_editor_icon": ExtResource( 7 )
  399. }
  400. skeleton_path = NodePath("../../../../../../GodotBattleBot/Armature/Skeleton3D")
  401. bones_in_chain = PackedStringArray("Left_UpperArm", "Left_LowerArm", "Left_Hand")
  402. bones_in_chain_lengths = PackedFloat32Array(1.97, 3, 0.1)
  403. limit_chain_iterations = false
  404. use_middle_joint_target = true
  405. [node name="Target" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK"]
  406. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.54883, -0.0335302, -0.934144)
  407. [node name="IK_LookAt" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK/Target"]
  408. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.300601, 0, 0.714191)
  409. script = ExtResource( 4 )
  410. __meta__ = {
  411. "_editor_icon": ExtResource( 5 )
  412. }
  413. skeleton_path = NodePath("../../../../../../../../GodotBattleBot/Armature/Skeleton3D")
  414. bone_name = "Left_Hand"
  415. use_negative_our_rot = true
  416. additional_rotation = Vector3(0, 0, 90)
  417. [node name="MiddleJoint" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK"]
  418. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 5.85263, -2.91316, -2.77555)
  419. [node name="Left_UpperArm" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK"]
  420. transform = Transform3D(-0.985848, -0.0154234, 0.16693, -0.0140715, 0.999858, 0.00927825, -0.167049, 0.00679813, -0.985925, 1.5529, -1.84646, -6.07288)
  421. [node name="Left_LowerArm" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK"]
  422. transform = Transform3D(-0.980952, 0.0992109, 0.167001, 0.116307, 0.988573, 0.0958931, -0.155579, 0.11349, -0.981282, 1.2349, -1.86413, -4.19466)
  423. [node name="Left_Hand" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK"]
  424. transform = Transform3D(-0.962426, 0.0909643, 0.255854, 0.128209, 0.982809, 0.132853, -0.23937, 0.160664, -0.957543, 0.737802, -2.14957, -1.27378)
  425. [node name="IK_FABRIK_RightArm" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos"]
  426. script = ExtResource( 6 )
  427. __meta__ = {
  428. "_editor_icon": ExtResource( 7 )
  429. }
  430. skeleton_path = NodePath("../../../../../../GodotBattleBot/Armature/Skeleton3D")
  431. bones_in_chain = PackedStringArray("Right_UpperArm", "Right_LowerArm", "Right_Hand")
  432. bones_in_chain_lengths = PackedFloat32Array(1.97, 3, 0.1)
  433. chain_iterations = 8
  434. limit_chain_iterations = false
  435. use_middle_joint_target = true
  436. [node name="Target" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm"]
  437. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.285662, -0.0335302, -1.05271)
  438. [node name="IK_LookAt" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm/Target"]
  439. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00396007, 0, 0.834561)
  440. script = ExtResource( 4 )
  441. __meta__ = {
  442. "_editor_icon": ExtResource( 5 )
  443. }
  444. skeleton_path = NodePath("../../../../../../../../GodotBattleBot/Armature/Skeleton3D")
  445. bone_name = "Right_Hand"
  446. use_negative_our_rot = true
  447. additional_rotation = Vector3(0, 0, 90)
  448. [node name="MiddleJoint" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm"]
  449. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -5.73318, -2.91316, -2.77555)
  450. [node name="Right_UpperArm" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm"]
  451. [node name="Right_LowerArm" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm"]
  452. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 5.85263, -2.91316, -2.77555)
  453. [node name="Right_Hand" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos/IK_FABRIK_RightArm"]
  454. [node name="RemoteTransform3D" type="RemoteTransform3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D/IK_LookAt_Chest/AimPos"]
  455. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.505047, 0.268441)
  456. remote_path = NodePath("../../../../../Weapon/Pistol")
  457. [node name="IK_LookAt_Head" type="Node3D" parent="CharacterBody3D/CameraHolder/LeanPath/PathFollow3D"]
  458. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -3.14041, -2.57003)
  459. script = ExtResource( 4 )
  460. __meta__ = {
  461. "_editor_icon": ExtResource( 5 )
  462. }
  463. skeleton_path = NodePath("../../../../GodotBattleBot/Armature/Skeleton3D")
  464. bone_name = "Head"
  465. [node name="AnimationPlayer" type="AnimationPlayer" parent="CharacterBody3D/CameraHolder"]
  466. autoplay = "Start"
  467. playback_speed = 4.0
  468. anims/Aiming = SubResource( 10 )
  469. anims/Idle = SubResource( 11 )
  470. anims/Start = SubResource( 12 )
  471. [node name="Weapon" type="Node3D" parent="CharacterBody3D/CameraHolder"]
  472. [node name="Pistol" parent="CharacterBody3D/CameraHolder/Weapon" instance=ExtResource( 8 )]
  473. transform = Transform3D(0.999391, 0, -0.0348995, 0, 1, 0, 0.0348995, 0, 0.999391, 0.519895, -1.10362, 3.20654)
  474. [node name="Pistol_textured" parent="CharacterBody3D/CameraHolder/Weapon/Pistol" index="0"]
  475. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0)
  476. surface_material_override/0 = ExtResource( 9 )
  477. material/1 = ExtResource( 10 )
  478. [node name="PistolEnd" type="Node3D" parent="CharacterBody3D/CameraHolder/Weapon/Pistol"]
  479. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.0161836, 0.315914, 1.41329)
  480. [node name="GodotBattleBot" parent="CharacterBody3D" instance=ExtResource( 11 )]
  481. [node name="godot_battle_bot" parent="CharacterBody3D/GodotBattleBot/Armature/Skeleton3D" index="0"]
  482. surface_material_override/0 = ExtResource( 12 )
  483. material/1 = ExtResource( 13 )
  484. [editable path="CharacterBody3D/CameraHolder/Weapon/Pistol"]
  485. [editable path="CharacterBody3D/GodotBattleBot"]