pandemonium_demo_projects/3d/ik/skeleton_ik.tscn

156 lines
4.7 KiB
Plaintext

[gd_scene load_steps=14 format=2]
[ext_resource path="res://skeleton_ik_runner.gd" type="Script" id=1]
[ext_resource path="res://addons/sade/ik_look_at.png" type="Texture" id=2]
[ext_resource path="res://addons/sade/editor_gizmo_texture.png" type="Texture" id=3]
[ext_resource path="res://model/godot_battle_bot.dae" type="PackedScene" id=4]
[ext_resource path="res://target_from_mousepos.gd" type="Script" id=5]
[ext_resource path="res://model/battle_bot_color.tres" type="Material" id=6]
[ext_resource path="res://model/battle_bot_emission.tres" type="Material" id=7]
[ext_resource path="res://button_change_scene.gd" type="Script" id=8]
[ext_resource path="res://addons/sade/ik_look_at.gd" type="Script" id=9]
[sub_resource type="PlaneMesh" id=1]
size = Vector2( 40, 40 )
[sub_resource type="SpatialMaterial" id=2]
albedo_texture = ExtResource( 3 )
roughness = 0.2
uv1_scale = Vector3( 0.25, 0.25, 0.25 )
uv1_triplanar = true
[sub_resource type="CubeMesh" id=3]
size = Vector3( 1, 1, 1 )
[sub_resource type="SpatialMaterial" id=4]
albedo_color = Color( 0, 0.191406, 0.765625, 1 )
roughness = 0.0
[node name="SkeletonIK" type="Spatial"]
[node name="Floor" type="MeshInstance" parent="."]
mesh = SubResource( 1 )
material/0 = SubResource( 2 )
[node name="DirectionalLight" type="DirectionalLight" parent="."]
transform = Transform( 0.56827, 0.673454, -0.472789, 0, 0.574581, 0.818448, 0.822842, -0.465099, 0.326517, -9.77531, 11.5204, 11.766 )
[node name="Camera" type="Camera" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 11.5, 11 )
fov = 74.0
script = ExtResource( 5 )
MOVEMENT_SPEED = -8.0
flip_axis = true
[node name="Targets" type="Spatial" parent="Camera"]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -8 )
[node name="IK_LookAt_Head" type="Spatial" parent="Camera/Targets"]
script = ExtResource( 9 )
__meta__ = {
"_editor_icon": ExtResource( 2 )
}
skeleton_path = NodePath("../../../GodotBattleBot/Armature/Skeleton")
bone_name = "Head"
additional_rotation = Vector3( 90, 0, 0 )
[node name="1MeterCube" type="MeshInstance" parent="Camera/Targets"]
mesh = SubResource( 3 )
material/0 = SubResource( 4 )
[node name="TargetLeft" type="Position3D" parent="Camera/Targets"]
transform = Transform( -0.179447, 0.98366, -0.0145678, 0.981822, 0.178142, -0.0654973, -0.0618319, -0.0260563, -0.997746, 0.653517, -0.112305, -0.760886 )
[node name="TargetRight" type="Position3D" parent="Camera/Targets"]
transform = Transform( -0.0217688, 0.998559, -0.0490576, 0.992503, 0.0274873, 0.119085, 0.120262, -0.0460975, -0.991671, -0.683053, 0.0251284, -0.811513 )
[node name="GodotBattleBot" parent="." instance=ExtResource( 4 )]
[node name="godot_battle_bot" parent="GodotBattleBot/Armature/Skeleton" index="0"]
material/0 = ExtResource( 6 )
material/1 = ExtResource( 7 )
[node name="SkeletonIK_Left" type="SkeletonIK" parent="GodotBattleBot/Armature/Skeleton" index="1"]
process_priority = 1
root_bone = "Left_UpperArm"
tip_bone = "Left_Hand"
use_magnet = true
magnet = Vector3( 8, 6, 0 )
target_node = NodePath("../../../../Camera/Targets/TargetLeft")
script = ExtResource( 1 )
[node name="SkeletonIK_Right" type="SkeletonIK" parent="GodotBattleBot/Armature/Skeleton" index="2"]
process_priority = 1
root_bone = "Right_UpperArm"
tip_bone = "Right_Hand"
use_magnet = true
magnet = Vector3( -8, 6, 0 )
target_node = NodePath("../../../../Camera/Targets/TargetRight")
script = ExtResource( 1 )
[node name="Control" type="Control" parent="."]
anchor_right = 1.0
anchor_bottom = 1.0
__meta__ = {
"_edit_use_anchors_": false
}
[node name="Panel" type="Panel" parent="Control"]
modulate = Color( 1, 1, 1, 0.784314 )
anchor_top = 1.0
anchor_right = 1.0
anchor_bottom = 1.0
margin_left = -2.0
margin_top = -70.0
margin_right = 4.0
__meta__ = {
"_edit_use_anchors_": false
}
[node name="Label" type="Label" parent="Control/Panel"]
anchor_right = 1.0
anchor_bottom = 1.0
margin_left = 12.0
margin_top = 10.0
margin_right = -18.0
margin_bottom = -29.0
text = "SkeletonIK node
Move mouse to move IK targets"
align = 1
valign = 1
__meta__ = {
"_edit_use_anchors_": false
}
[node name="ButtonNext" type="Button" parent="Control"]
anchor_left = 1.0
anchor_top = 1.0
anchor_right = 1.0
anchor_bottom = 1.0
margin_left = -124.0
margin_top = -60.0
margin_right = -5.0
margin_bottom = -10.0
text = "Next scene"
script = ExtResource( 8 )
__meta__ = {
"_edit_use_anchors_": false
}
scene_to_change_to = "res://fps/fps_example.tscn"
[node name="ButtonPrev" type="Button" parent="Control"]
anchor_top = 1.0
anchor_bottom = 1.0
margin_left = 10.0
margin_top = -60.0
margin_right = 129.0
margin_bottom = -10.0
text = "Previous scene"
script = ExtResource( 8 )
__meta__ = {
"_edit_use_anchors_": false
}
scene_to_change_to = "res://fabrik_ik.tscn"
[editable path="GodotBattleBot"]