This commit is contained in:
AleaJactaEst 2021-03-23 23:24:40 +01:00
parent 70f3ae38c6
commit 4f72931cac
88 changed files with 36020 additions and 270 deletions

View file

@ -0,0 +1,25 @@
extends Spatial
signal animation_finished( anim_name )
signal limb_body_entered( limb, body )
func _on_AnimationPlayer_animation_finished(anim_name):
emit_signal( "animation_finished", anim_name )
func _on_limb_blue_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )
func _on_limb_pink_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )
func _on_limb_red_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )
func _on_limb_yellow_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )
func _on_limb_green_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )
func _on_limb_cyan_area_body_entered(body):
emit_signal( "limb_body_entered", Datas.Cloth.LIMB.torso, body )

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -0,0 +1,22 @@
extends Spatial
# Declare member variables here. Examples:
# var a = 2
# var b = "text"
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
#func _process(delta):
# pass
func play( anim_name, speed = 1.0 ):
for child in $body_parts.get_children():
child.get_node( "Arche/AnimationPlayer" ).playback_speed = speed
if child.get_node( "Arche/AnimationPlayer" ).has_animation( anim_name ):
child.get_node( "Arche/AnimationPlayer" ).play( anim_name )

Binary file not shown.

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,71 @@
[gd_scene load_steps=8 format=2]
[ext_resource path="res://assets/creatures/arche/arche.gltf" type="PackedScene" id=1]
[sub_resource type="SphereShape" id=1]
radius = 0.2
[sub_resource type="SphereShape" id=2]
radius = 0.2
[sub_resource type="SphereShape" id=3]
radius = 0.2
[sub_resource type="SphereShape" id=4]
radius = 0.2
[sub_resource type="SphereShape" id=5]
radius = 0.2
[sub_resource type="SphereShape" id=6]
radius = 0.2
[node name="arche" instance=ExtResource( 1 )]
[node name="BoneArcheBleue" parent="Arche/Bone" index="0"]
transform = Transform( 0.707107, 0.707107, -8.9407e-08, 8.9407e-08, 1.19209e-07, 1, 0.707107, -0.707107, 5.96046e-08, 0.7, 0.4, -1.74846e-08 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheBleue/ArcheBleue" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheBleue/ArcheBleue/area" index="0"]
shape = SubResource( 1 )
[node name="BoneArcheRose" parent="Arche/Bone" index="1"]
transform = Transform( -0.843489, -0.537147, 1.19209e-07, 0, 1.19209e-07, 1, -0.537147, 0.843489, -1.19209e-07, -0.0976257, 0.899057, 0.0216616 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheRose/ArcheRose" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheRose/ArcheRose/area" index="0"]
shape = SubResource( 2 )
[node name="BoneArcheRouge" parent="Arche/Bone" index="2"]
transform = Transform( 0.906155, -0.422946, 0, -4.47035e-08, 0, 1, -0.422946, -0.906155, 0, 0.034168, 1.26493, -0.0939817 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheRouge/ArcheRouge" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheRouge/ArcheRouge/area" index="0"]
shape = SubResource( 3 )
[node name="BoneArcheJaune" parent="Arche/Bone" index="3"]
transform = Transform( -0.129988, 0.991516, 0, 0, 0, 1, 0.991516, 0.129988, 0, 0.0609192, 1.39999, 0.0793022 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheJaune/ArcheJaune" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheJaune/ArcheJaune/area" index="0"]
shape = SubResource( 4 )
[node name="BoneArcheVert" parent="Arche/Bone" index="4"]
transform = Transform( -0.981572, 0.191092, -3.27826e-07, -2.98023e-07, 1.78814e-07, 1, 0.191092, 0.981572, -1.19209e-07, -0.391267, 1.26819, 0.58044 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheVert/ArcheVert" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheVert/ArcheVert/area" index="0"]
shape = SubResource( 5 )
[node name="BoneArcheCyan" parent="Arche/Bone" index="5"]
transform = Transform( 0.34168, -0.939817, 2.98023e-08, -2.98023e-08, 1.19209e-07, 1, -0.939817, -0.34168, 0, -0.296062, 0.904706, -0.634308 )
[node name="area" type="Area" parent="Arche/Bone/BoneArcheCyan/ArcheCyan" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Arche/Bone/BoneArcheCyan/ArcheCyan/area" index="0"]
shape = SubResource( 6 )

View file

@ -0,0 +1,302 @@
extends KinematicBody
signal equip( p_slot, p_item )
signal unequip( p_slot )
var character = null
var rotation_speed_factor = 0.01
var move_speed = 2.5
var run_speed = 5.0
var max_speed = 12.0
export var gravity = -9.0
var velocity: = Vector3.ZERO
var is_running = false
var can_turn = false
var ground_contacts = 0
var is_jump_started = false
var is_jumping = false
var jump_strength = 250.0
var is_falling = false
var is_on_ground = true
var is_readying_weapon = false
var is_weapon_ready = false
var can_attack = true
var is_dying = false
var is_dead = false
var direction = Vector3.ZERO
var orientation = 0.0
enum PLAYER_RELATION {
neutre,
friend,
ennemy
}
export( PLAYER_RELATION ) var player_relation = PLAYER_RELATION.neutre
export( String ) var creature_filename = null setget set_creature_filename
func set_creature_filename( p_filename ):
creature_filename = p_filename
self.load_from_name( p_filename )
func _process( delta ):
# Calculate a move direction vector relative to the camera
# The basis stores the (right, up, -forwards) vectors of our camera.
var forwards: Vector3 = $look_at.global_transform.basis.z * direction.z
var right: Vector3 = $look_at.global_transform.basis.x * direction.x
if forwards:
right = Vector3.ZERO
var move_direction: = forwards + right
if move_direction.length() > 1.0:
move_direction = move_direction.normalized()
move_direction.y = 0
# Rotation.
if (self.has_node( "creature" ) and $creature.can_turn()) or self.is_readying_weapon or self.is_weapon_ready:
self.rotate_y( rotation_speed_factor * orientation )
# Movement.
velocity = self.calculate_velocity(velocity, move_direction, delta)
if not self.is_readying_weapon and not self.is_weapon_ready:
if not self.is_jumping and not self.is_jump_started and not self.is_falling:
velocity = self.move_and_slide_with_snap(velocity, Vector3.DOWN, Vector3.UP, true)
else:
velocity = self.move_and_slide(velocity, Vector3.UP, true)
# Animation.
if self.has_node( "creature" ):
if self.is_dead:
$creature.play( "dead_loop" )
elif self.is_dying:
$creature.play( "dying", 2.0 )
elif self.is_readying_weapon:
$creature.play( "1h_pistol_ready_start" )
elif self.is_weapon_ready:
$creature.play( "1h_pistol_ready_loop" )
elif direction and not self.is_jump_started and not self.is_jumping and not self.is_falling:
if direction.z < 0.0:
if self.is_running:
$creature.play( "run" , 2.0 )
else:
$creature.play( "walk" )
elif direction.z > 0.0:
if self.is_running:
$creature.play_backwards( "run", 2.0 )
else:
$creature.play_backwards( "walk" )
elif direction.x > 0.0:
$creature.play( "strafe_right" )
elif direction.x < 0.0:
$creature.play( "strafe_left" )
elif self.is_jump_started and not self.is_jumping:
$creature.play( "jump_start" )
elif self.is_jumping or self.is_falling:
if not self.is_on_ground:
$creature.play( "jump_loop" )
else:
$creature.play( "jump_end", 2 )
elif not self.orientation == 0.0:
if self.orientation < 0.0:
$creature.play( "turn_right", 2.0 )
elif self.orientation > 0.0:
$creature.play( "turn_left", 2.0 )
else:
$creature.play( "idle" )
func calculate_velocity(
velocity_current: Vector3,
move_direction: Vector3,
delta: float
) -> Vector3:
# var velocity_new := move_direction
var velocity_new = Vector3.ZERO
if not self.is_jump_started:
velocity_new = move_direction
if self.is_running:
velocity_new *= run_speed
else:
velocity_new *= move_speed
if velocity_new.length() > max_speed:
velocity_new = velocity_new.normalized() * max_speed
velocity_new.y = velocity_current.y + gravity * delta
if self.is_jumping:
velocity_new.y += self.jump_strength * delta
self.is_jumping = false
self.is_falling = true
if self.is_falling:
velocity_new.x *= 2.0
velocity_new.z *= 2.0
return velocity_new
func load_from_name( p_name, p_emplacement = null ):
var creature = Datas.Creature.new()
creature.set_data( "name", p_name )
creature.load( null, p_emplacement )
if creature.get_data( "race" ) == Globals.RACE.human:
if creature.get_data( "sex" ) == Globals.SEX.female:
self.change_creature( "res://scenes/creatures/human/human_female.tscn" )
elif creature.get_data( "sex" ) == Globals.SEX.male:
self.change_creature( "res://scenes/creatures/human/human_male.tscn" )
if $creature:
$creature.load_from_name( p_name, p_emplacement )
func change_creature( new_model_path ):
if $creature:
var old_model = $creature
self.remove_child( old_model )
old_model.queue_free()
var new_model = load( new_model_path )
if new_model:
new_model = new_model.instance()
new_model.name = "creature"
self.add_child( new_model )
new_model.connect( "animation_finished", self, "_on_creature_animation_finished" )
new_model.duplicate_meshes()
func set_blend_shape( p_blend_shape_name, p_value ):
$creature.set_blend_shape( p_blend_shape_name, p_value )
func _on_ground_area_body_entered(body):
if not body == self:
self.ground_contacts += 1
if self.ground_contacts > 0:
# self.is_falling = false
self.is_on_ground = true
func _on_ground_area_body_exited(body):
if not body == self:
self.ground_contacts -= 1
if self.ground_contacts <= 0:
self.is_falling = true
self.is_on_ground = false
func _on_creature_animation_finished(anim_name):
if anim_name == "jump_start":
self.is_jump_started = false
self.is_jumping = true
elif anim_name == "jump_end":
self.is_falling = false
elif anim_name == "turn_right":
self.can_turn = false
elif anim_name == "turn_left":
self.can_turn = false
elif anim_name == "1h_pistol_ready_start":
self.is_readying_weapon = false
self.is_weapon_ready = true
elif anim_name == "dying":
self.is_dying = false
self.is_dead = true
func set_focus( p_focus = true ):
if p_focus:
$focus.show()
if self.player_relation == PLAYER_RELATION.neutre:
$focus.get_surface_material( 0 ).albedo_color = Color.white
elif self.player_relation == PLAYER_RELATION.friend:
$focus.get_surface_material( 0 ).albedo_color = Color.green
elif self.player_relation == PLAYER_RELATION.ennemy:
$focus.get_surface_material( 0 ).albedo_color = Color.red
else:
$focus.hide()
func get_weapons():
var weapons = []
if Datas.Equipment.SLOT.weapon_hands in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item )
if not weapons.size() > 0:
if Datas.Equipment.SLOT.weapon_hand_right in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item )
if Datas.Equipment.SLOT.weapon_hand_left in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item )
return weapons
func get_main_weapon_node():
var weapon = null
if Datas.Equipment.SLOT.weapon_hands in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item:
if $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
if not weapon and Datas.Equipment.SLOT.weapon_hand_right in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item:
if $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
if not weapon and Datas.Equipment.SLOT.weapon_hand_left in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item:
if $creature/body_parts/body/skeleton/attachment_hand_L/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
return weapon
func attack():
if self.can_attack:
var weapon = null
var attachment = null
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].attachment
if not weapon:
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].attachment
if not weapon:
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].attachment
if weapon:
print( "pan " + str(weapon.get_data( "damage" )) )
var weapon_node = $creature/body_parts/body/skeleton.get_node( attachment )
if weapon_node:
weapon_node = weapon_node.get_node( "handle" ).get_children()[0]
# if weapon_node is preload( "res://scenes/items/equipments/weapons/firearm.gd" ):
# weapon_node.fire( self, [self] )
#
self.can_attack = false
$attack_delay.start()
func hit( p_damage, p_from = null ):
$creature.creature.set_data( "current_life", $creature.creature.get_data( "current_life" )-p_damage )
$head_infos_viewport/head_infos/bars/life.max_value = $creature.creature.get_max_life()
$head_infos_viewport/head_infos/bars/life.value = $creature.creature.get_data( "current_life", 0 )
func die():
self.is_dying = true
func _on_creature_equip(p_slot, p_item):
var weapons = self.get_weapons()
if weapons.size() > 0:
var max_delay = null
for weapon in weapons:
if not max_delay:
max_delay = weapon.get_data( "attack_delay" )
else:
max_delay = max( max_delay, weapon.get_data( "attack_delay" ) )
$attack_delay.wait_time = max_delay
emit_signal( "equip", p_slot, p_item )
func _on_creature_unequip(p_slot):
emit_signal( "unequip", p_slot )
func _on_attack_delay_timeout():
self.can_attack = true
func _on_creature_is_dead():
self.die()

View file

@ -0,0 +1,74 @@
[gd_scene load_steps=12 format=2]
[ext_resource path="res://scenes/interfaces/focus_reticle.tscn" type="PackedScene" id=1]
[ext_resource path="res://scenes/characters/head_infos.tscn" type="PackedScene" id=2]
[ext_resource path="res://assets/creatures/arche/arche.tscn" type="PackedScene" id=3]
[ext_resource path="res://assets/interfaces/focus_reticle.png" type="Texture" id=4]
[ext_resource path="res://assets/creatures/arche/area_arche.gd" type="Script" id=5]
[sub_resource type="QuadMesh" id=1]
size = Vector2( 0.5, 0.5 )
[sub_resource type="ViewportTexture" id=2]
viewport_path = NodePath("head_infos_viewport")
[sub_resource type="SpatialMaterial" id=3]
resource_local_to_scene = true
flags_transparent = true
flags_unshaded = true
params_cull_mode = 2
params_billboard_mode = 1
albedo_texture = SubResource( 2 )
[sub_resource type="CylinderShape" id=4]
height = 0.03
[sub_resource type="QuadMesh" id=5]
resource_local_to_scene = true
size = Vector2( 2, 2 )
[sub_resource type="SpatialMaterial" id=6]
resource_local_to_scene = true
render_priority = 10
flags_unshaded = true
flags_no_depth_test = true
params_billboard_mode = 1
params_use_alpha_scissor = true
params_alpha_scissor_threshold = 0.1
albedo_texture = ExtResource( 4 )
[node name="character" type="Spatial"]
script = ExtResource( 5 )
[node name="head_infos_viewport" type="Viewport" parent="."]
size = Vector2( 512, 2565 )
transparent_bg = true
[node name="head_infos" parent="head_infos_viewport" instance=ExtResource( 2 )]
[node name="head_infos_frame" type="MeshInstance" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.7504, 0 )
mesh = SubResource( 1 )
material/0 = SubResource( 3 )
[node name="creature" parent="." instance=ExtResource( 3 )]
[node name="look_at" type="Spatial" parent="."]
transform = Transform( -1, 0, 0, 0, 1, 0, 0, 0, -1, 0, 1.71448, 0 )
[node name="ground_area" type="Area" parent="."]
[node name="collision_shape" type="CollisionShape" parent="ground_area"]
shape = SubResource( 4 )
[node name="focus" parent="." instance=ExtResource( 1 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0 )
mesh = SubResource( 5 )
material/0 = SubResource( 6 )
size = Vector2( 2, 2 )
[node name="attack_delay" type="Timer" parent="."]
one_shot = true
[connection signal="body_entered" from="ground_area" to="." method="_on_ground_area_body_entered"]
[connection signal="body_exited" from="ground_area" to="." method="_on_ground_area_body_exited"]
[connection signal="timeout" from="attack_delay" to="." method="_on_attack_delay_timeout"]

View file

@ -0,0 +1,298 @@
extends KinematicBody
signal equip( p_slot, p_item )
signal unequip( p_slot )
var character = null
var rotation_speed_factor = 0.1
var move_speed = 2.5
var run_speed = 5.0
var max_speed = 12.0
export var gravity = -9.0
var velocity: = Vector3.ZERO
var is_running = false
var can_turn = false
var ground_contacts = 0
var is_jump_started = false
var is_jumping = false
var jump_strength = 250.0
var is_falling = false
var is_on_ground = true
var is_readying_weapon = false
var is_weapon_ready = false
var can_attack = true
var is_dying = false
var is_dead = false
var direction = Vector3.ZERO
var orientation = 0.0
enum PLAYER_RELATION {
neutre,
friend,
ennemy
}
export( PLAYER_RELATION ) var player_relation = PLAYER_RELATION.neutre
export( String ) var creature_filename = null setget set_creature_filename
func set_creature_filename( p_filename ):
creature_filename = p_filename
self.load_from_name( p_filename )
func _process( delta ):
# Calculate a move direction vector relative to the camera
# The basis stores the (right, up, -forwards) vectors of our camera.
var forwards: Vector3 = $look_at.global_transform.basis.z * direction.z
var right: Vector3 = $look_at.global_transform.basis.x * direction.x
if forwards:
right = Vector3.ZERO
var move_direction: = forwards + right
if move_direction.length() > 1.0:
move_direction = move_direction.normalized()
move_direction.y = 0
# Rotation.
#if (self.has_node( "creature" ) and $creature.can_turn()) or self.is_readying_weapon or self.is_weapon_ready:
self.rotate_y( rotation_speed_factor * orientation )
# Movement.
velocity = self.calculate_velocity(velocity, move_direction, delta)
if not self.is_readying_weapon and not self.is_weapon_ready:
if not self.is_jumping and not self.is_jump_started and not self.is_falling:
velocity = self.move_and_slide_with_snap(velocity, Vector3.DOWN, Vector3.UP, true)
else:
velocity = self.move_and_slide(velocity, Vector3.UP, true)
# Animation.
if self.has_node( "creature" ):
# if self.is_dead:
# $creature.play( "dead_loop" )
# elif self.is_dying:
# $creature.play( "dying", 2.0 )
# elif self.is_readying_weapon:
# $creature.play( "1h_pistol_ready_start" )
# elif self.is_weapon_ready:
# $creature.play( "1h_pistol_ready_loop" )
# elif direction and not self.is_jump_started and not self.is_jumping and not self.is_falling:
# if direction.z < 0.0:
# if self.is_running:
# $creature.play( "run" , 2.0 )
# else:
# $creature.play( "walk" )
# elif direction.z > 0.0:
# if self.is_running:
# $creature.play_backwards( "run", 2.0 )
# else:
# $creature.play_backwards( "walk" )
# elif direction.x > 0.0:
# $creature.play( "strafe_right" )
# elif direction.x < 0.0:
# $creature.play( "strafe_left" )
# elif self.is_jump_started and not self.is_jumping:
# $creature.play( "jump_start" )
# elif self.is_jumping or self.is_falling:
# if not self.is_on_ground:
# $creature.play( "jump_loop" )
# else:
# $creature.play( "jump_end", 2 )
# elif not self.orientation == 0.0:
# if self.orientation < 0.0:
# $creature.play( "turn_right", 2.0 )
# elif self.orientation > 0.0:
# $creature.play( "turn_left", 2.0 )
# else:
# $creature.play( "idle" )
$creature.play( "idle" )
func calculate_velocity(
velocity_current: Vector3,
move_direction: Vector3,
delta: float
) -> Vector3:
# var velocity_new := move_direction
var velocity_new = Vector3.ZERO
if not self.is_jump_started:
velocity_new = move_direction
if self.is_running:
velocity_new *= run_speed
else:
velocity_new *= move_speed
if velocity_new.length() > max_speed:
velocity_new = velocity_new.normalized() * max_speed
velocity_new.y = velocity_current.y + gravity * delta
if self.is_jumping:
velocity_new.y += self.jump_strength * delta
self.is_jumping = false
self.is_falling = true
if self.is_falling:
velocity_new.x *= 2.0
velocity_new.z *= 2.0
return velocity_new
func load_from_name( p_name, p_emplacement = null ):
var creature = Datas.Creature.new()
creature.set_data( "name", p_name )
creature.load( null, p_emplacement )
# if creature.get_data( "race" ) == Globals.RACE.human:
# if creature.get_data( "sex" ) == Globals.SEX.female:
# self.change_creature( "res://scenes/creatures/human/human_female.tscn" )
# elif creature.get_data( "sex" ) == Globals.SEX.male:
# self.change_creature( "res://scenes/creatures/human/human_male.tscn" )
if $creature:
$creature.load_from_name( p_name, p_emplacement )
func change_creature( new_model_path ):
if $creature:
var old_model = $creature
self.remove_child( old_model )
old_model.queue_free()
var new_model = load( new_model_path )
if new_model:
new_model = new_model.instance()
new_model.name = "creature"
self.add_child( new_model )
new_model.connect( "animation_finished", self, "_on_creature_animation_finished" )
new_model.duplicate_meshes()
func set_blend_shape( p_blend_shape_name, p_value ):
$creature.set_blend_shape( p_blend_shape_name, p_value )
func _on_ground_area_body_entered(body):
if not body == self:
self.ground_contacts += 1
if self.ground_contacts > 0:
# self.is_falling = false
self.is_on_ground = true
func _on_ground_area_body_exited(body):
if not body == self:
self.ground_contacts -= 1
if self.ground_contacts <= 0:
self.is_falling = true
self.is_on_ground = false
func _on_creature_animation_finished(anim_name):
if anim_name == "jump_start":
self.is_jump_started = false
self.is_jumping = true
elif anim_name == "jump_end":
self.is_falling = false
elif anim_name == "turn_right":
self.can_turn = false
elif anim_name == "turn_left":
self.can_turn = false
elif anim_name == "1h_pistol_ready_start":
self.is_readying_weapon = false
self.is_weapon_ready = true
elif anim_name == "dying":
self.is_dying = false
self.is_dead = true
func set_focus( p_focus = true ):
if p_focus:
$focus.show()
if self.player_relation == PLAYER_RELATION.neutre:
$focus.get_surface_material( 0 ).albedo_color = Color.white
elif self.player_relation == PLAYER_RELATION.friend:
$focus.get_surface_material( 0 ).albedo_color = Color.green
elif self.player_relation == PLAYER_RELATION.ennemy:
$focus.get_surface_material( 0 ).albedo_color = Color.red
else:
$focus.hide()
func get_weapons():
var weapons = []
if Datas.Equipment.SLOT.weapon_hands in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item )
if not weapons.size() > 0:
if Datas.Equipment.SLOT.weapon_hand_right in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item )
if Datas.Equipment.SLOT.weapon_hand_left in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item:
weapons.push_back( $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item )
return weapons
func get_main_weapon_node():
var weapon = null
if Datas.Equipment.SLOT.weapon_hands in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item:
if $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
if not weapon and Datas.Equipment.SLOT.weapon_hand_right in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item:
if $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
if not weapon and Datas.Equipment.SLOT.weapon_hand_left in $creature.slots:
if $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item:
if $creature/body_parts/body/skeleton/attachment_hand_L/handle.get_children().size() > 0:
weapon = $creature/body_parts/body/skeleton/attachment_hand_R/handle.get_children()[0]
return weapon
func attack():
if self.can_attack:
var weapon = null
var attachment = null
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_right ].attachment
if not weapon:
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hand_left ].attachment
if not weapon:
weapon = $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].item
attachment = $creature.slots[ Datas.Equipment.SLOT.weapon_hands ].attachment
if weapon:
print( "pan " + str(weapon.get_data( "damage" )) )
var weapon_node = $creature/body_parts/body/skeleton.get_node( attachment )
if weapon_node:
weapon_node = weapon_node.get_node( "handle" ).get_children()[0]
# if weapon_node is preload( "res://scenes/items/equipments/weapons/firearm.gd" ):
# weapon_node.fire( self, [self] )
#
self.can_attack = false
$attack_delay.start()
func hit( p_damage, p_from = null ):
$creature.creature.set_data( "current_life", $creature.creature.get_data( "current_life" )-p_damage )
$head_infos_viewport/head_infos/bars/life.max_value = $creature.creature.get_max_life()
$head_infos_viewport/head_infos/bars/life.value = $creature.creature.get_data( "current_life", 0 )
func die():
self.is_dying = true
func _on_creature_equip(p_slot, p_item):
var weapons = self.get_weapons()
if weapons.size() > 0:
var max_delay = null
for weapon in weapons:
if not max_delay:
max_delay = weapon.get_data( "attack_delay" )
else:
max_delay = max( max_delay, weapon.get_data( "attack_delay" ) )
$attack_delay.wait_time = max_delay
emit_signal( "equip", p_slot, p_item )
func _on_creature_unequip(p_slot):
emit_signal( "unequip", p_slot )
func _on_attack_delay_timeout():
self.can_attack = true
func _on_creature_is_dead():
self.die()

View file

@ -0,0 +1,76 @@
[gd_scene load_steps=12 format=2]
[ext_resource path="res://scenes/characters/head_infos.tscn" type="PackedScene" id=1]
[ext_resource path="res://assets/creatures/arche/skin_arche.tscn" type="PackedScene" id=2]
[ext_resource path="res://scenes/interfaces/focus_reticle.tscn" type="PackedScene" id=3]
[ext_resource path="res://assets/interfaces/focus_reticle.png" type="Texture" id=4]
[sub_resource type="QuadMesh" id=1]
size = Vector2( 0.5, 0.5 )
[sub_resource type="ViewportTexture" id=2]
viewport_path = NodePath("head_infos_viewport")
[sub_resource type="SpatialMaterial" id=3]
resource_local_to_scene = true
flags_transparent = true
flags_unshaded = true
albedo_texture = SubResource( 2 )
[sub_resource type="CylinderShape" id=4]
resource_local_to_scene = true
[sub_resource type="CylinderShape" id=5]
resource_local_to_scene = true
height = 0.03
[sub_resource type="QuadMesh" id=6]
resource_local_to_scene = true
size = Vector2( 2.1, 1.8 )
[sub_resource type="SpatialMaterial" id=7]
resource_local_to_scene = true
render_priority = 10
flags_unshaded = true
flags_no_depth_test = true
params_billboard_mode = 1
params_use_alpha_scissor = true
params_alpha_scissor_threshold = 0.1
albedo_texture = ExtResource( 4 )
[node name="kinematic_body" type="KinematicBody"]
[node name="head_infos_viewport" type="Viewport" parent="."]
size = Vector2( 512, 2565 )
transparent_bg = true
[node name="head_infos" parent="head_infos_viewport" instance=ExtResource( 1 )]
[node name="head_infos_frame" type="MeshInstance" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.96237, 0 )
visible = false
mesh = SubResource( 1 )
material/0 = SubResource( 3 )
[node name="creature" parent="." instance=ExtResource( 2 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0 )
shape = SubResource( 4 )
[node name="look_at" type="Spatial" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.86429, 0 )
[node name="ground_area" type="Area" parent="."]
[node name="collision_shape" type="CollisionShape" parent="ground_area"]
shape = SubResource( 5 )
[node name="focus" parent="." instance=ExtResource( 3 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.9, 0 )
visible = false
mesh = SubResource( 6 )
material/0 = SubResource( 7 )
size = Vector2( 2.1, 1.8 )
[node name="attack_delay" type="Timer" parent="."]
one_shot = true
[connection signal="timeout" from="attack_delay" to="focus" method="_on_attack_delay_timeout"]

View file

@ -0,0 +1,65 @@
extends Spatial
onready var camera_tps = $character/spring_arm/camera_tps
onready var camera_fps = $character/spring_arm/camera_fps
var mouse_delta = Vector2.ZERO
var zoom_level = 0
var camera_position = Vector3( 0.0, 2.0, -2.0 )
var proximity_objects = []
var focused_object = null
var focus_index = 0
static func get_input_direction() -> Vector3:
return Vector3(
Input.get_action_strength("move_strafe_right") - Input.get_action_strength("move_strafe_left"),
0,
Input.get_action_strength("move_backward") - Input.get_action_strength("move_forward")
)
func _input( event ):
# Run.
if event.is_action_pressed( "move_toggle_run" ):
$character.is_running = not $character.is_running
# Camera.
if event.is_action( "camera_zoom_in" ):
self.zoom_level += 1
elif event.is_action( "camera_zoom_out" ):
self.zoom_level -= 1
if event.is_action_pressed( "camera_reset_view" ):
$character/spring_arm.rotation = Vector3.ZERO
self.zoom_level = 0
if event.is_action_pressed( "camera_switch" ):
if self.camera_tps.current:
self.camera_fps.make_current()
$character/spring_arm.rotation = Vector3.ZERO
# self.hide()
else:
self.camera_tps.make_current()
# self.show()
if event is InputEventMouseMotion:
self.mouse_delta = event.relative
# Jump.
if event.is_action_pressed( "move_jump" ) and not $character.is_falling:
$character.is_jump_started = true
if event.is_action_pressed( "interact" ):
# self.interact()
pass
if event.is_action_pressed( "focus_next" ):
# self.focus_next()
pass
func _process( delta ):
$character.direction = self.get_input_direction()
# Rotation.
if not Input.is_key_pressed( KEY_SHIFT ) and not $character.is_jump_started:
$character.orientation = (Input.get_action_strength("move_turn_left") - Input.get_action_strength("move_turn_right"))
else:
$character.orientation = 0.0
# Camera.
if not self.mouse_delta == Vector2.ZERO and self.camera_tps.current:
if Input.get_mouse_mode() == Input.MOUSE_MODE_CAPTURED:
$character/spring_arm.rotate_y( -self.mouse_delta.x * 0.01 )
self.camera_tps.rotate_x( self.mouse_delta.y * 0.01 )

View file

@ -0,0 +1,24 @@
[gd_scene load_steps=4 format=2]
[ext_resource path="res://assets/creatures/arche/character_arche.tscn" type="PackedScene" id=1]
[ext_resource path="res://assets/creatures/arche/player_arche.gd" type="Script" id=2]
[ext_resource path="res://assets/creatures/arche/character_arche.gd" type="Script" id=3]
[node name="spatial" type="Spatial"]
script = ExtResource( 2 )
[node name="character" parent="." instance=ExtResource( 1 )]
script = ExtResource( 3 )
[node name="spring_arm" type="Spatial" parent="character"]
[node name="camera_tps" type="Camera" parent="character/spring_arm"]
transform = Transform( 1, 0, 0, 0, 0.944077, 0.329724, 0, -0.329724, 0.944077, 0, 2.4017, 2.25811 )
current = true
near = 0.01
far = 100000.0
[node name="camera_fps" type="Camera" parent="character/spring_arm"]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.90314, 0 )
near = 0.01
far = 100000.0

View file

@ -0,0 +1,411 @@
extends CollisionShape
signal animation_finished( anim_name )
signal equip( p_slot, p_item )
signal unequip( p_slot )
signal is_dead
var creature = Datas.Human.new()
var eye_color_list = [ "blue_eye", "bluegreen_eye","brown_eye","deepblue_eye","green_eye","grey_eye","ice_eye","lightblue_eye" ]
class Slot:
var item = null
var attachment = null
func _init( p_attachment = null ):
self.attachment = p_attachment
var slots = { Datas.Equipment.SLOT.cloth_hand: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_face: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_head: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_torso: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_legs: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_feet: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.cloth_back: Slot.new( "cloths" )\
, Datas.Equipment.SLOT.weapon_hand_right: Slot.new( "attachment_hand_R" )\
, Datas.Equipment.SLOT.weapon_hand_left: Slot.new( "attachment_hand_L" )\
, Datas.Equipment.SLOT.weapon_hands: Slot.new( "attachment_hand_R" )\
, Datas.Equipment.SLOT.weapon_hip_right: Slot.new( "attachment_hips_R" )\
, Datas.Equipment.SLOT.weapon_hip_left: Slot.new( "attachment_hips_L" )\
, Datas.Equipment.SLOT.weapon_back_right: Slot.new()\
, Datas.Equipment.SLOT.weapon_back_left: Slot.new()\
, Datas.Equipment.SLOT.weapon_holster_right: Slot.new()\
, Datas.Equipment.SLOT.weapon_holster_left: Slot.new() }
func _ready():
self.duplicate_meshes()
func duplicate_meshes():
# for body in $body_parts.get_children():
# for mesh in body.get_node( "skeleton" ).get_children():
# if mesh is MeshInstance:
# var new_mat = mesh.get( "material/0" ).duplicate()
# var new_mesh = mesh.mesh.duplicate()
# mesh.mesh = new_mesh
# mesh.set( "material/0", new_mat )
# for body in $hair_parts.get_children():
# for mesh in body.get_node( "skeleton" ).get_children():
# if mesh is MeshInstance:
# var new_mat = mesh.get( "material/0" ).duplicate()
# var new_mesh = mesh.mesh.duplicate()
# mesh.mesh = new_mesh
# mesh.set( "material/0", new_mat )
# for body in $cloths.get_children():
# for mesh in body.get_node( "skeleton" ).get_children():
# if mesh is MeshInstance:
# var new_mat = mesh.get( "material/0" ).duplicate()
# var new_mesh = mesh.mesh.duplicate()
# mesh.mesh = new_mesh
# mesh.set( "material/0", new_mat )
self.update()
func set_blend_shape( p_blend_shape_name, p_value ):
# for child in $body_parts.get_children():
# var skeleton = child.get_node( "skeleton" )
# for node in skeleton.get_children():
# if node is MeshInstance:
# node.set( "blend_shapes/"+p_blend_shape_name, p_value )
# for child in $hair_parts.get_children():
# var skeleton = child.get_node( "skeleton" )
# for node in skeleton.get_children():
# if node is MeshInstance:
# node.set( "blend_shapes/"+p_blend_shape_name, p_value )
# for child in $cloths.get_children():
# var skeleton = child.get_node( "skeleton" )
# for node in skeleton.get_children():
# if node is MeshInstance:
# node.set( "blend_shapes/"+p_blend_shape_name, p_value )
pass
func load_from_name( p_name, p_emplacement = "usr" ):
var new_creature = Datas.Human.new()
var name_split = p_name.split( "_" )
new_creature.set_data( "first_name", name_split[0] )
new_creature.set_data( "last_name", name_split[1] )
new_creature.load( null, p_emplacement )
self.creature = new_creature
self.update()
func update():
# if self.creature:
# self.scale = Vector3( self.creature.get_data( "size" ), self.creature.get_data( "size" ), self.creature.get_data( "size" ) )
#
# self.set_blend_shape( "caucasian", self.creature.get_data( "caucasian" ) )
# self.set_blend_shape( "african", self.creature.get_data( "african" ) )
# self.set_blend_shape( "asian", self.creature.get_data( "asian" ) )
#
# if self.creature.get_data( "sex" ) == Globals.SEX.female:
# if self.creature.get_data( "skin" ) == 0:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_lightskinned_female_diffuse.png" ) )
# elif self.creature.get_data( "skin" ) == 1:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_lightskinned_female_diffuse3.png" ) )
# elif self.creature.get_data( "skin" ) == 2:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_darkskinned_female_diffuse.png" ) )
# elif self.creature.get_data( "sex" ) == Globals.SEX.male:
# if self.creature.get_data( "skin" ) == 0:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_lightskinned_male_diffuse2.png" ) )
# elif self.creature.get_data( "skin" ) == 1:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_lightskinned_male_diffuse3.png" ) )
# elif self.creature.get_data( "skin" ) == 2:
# self.get_node( "body_parts/body/skeleton/body" ).get_surface_material( 0 ).set_shader_param( "texture_albedo", preload( "res://assets/creatures/human/textures/young_darkskinned_male_diffuse.png" ) )
#
# if self.creature.get_data( "sex" ) == Globals.SEX.female:
# if self.creature.get_data( "hair" ) == 0:
# self.get_node( "hair_parts/mh_human_female_hair" ).hide()
# elif self.creature.get_data( "hair" ) == 1:
# self.get_node( "hair_parts/mh_human_female_hair" ).show()
# self.get_node( "hair_parts/mh_human_female_hair/skeleton/hair" ).get_surface_material( 0 ).albedo_texture = preload( "res://assets/creatures/human/textures/human_female_hair_001.png" )
# elif self.creature.get_data( "hair" ) == 2:
# self.get_node( "hair_parts/mh_human_female_hair" ).show()
# self.get_node( "hair_parts/mh_human_female_hair/skeleton/hair" ).get_surface_material( 0 ).albedo_texture = preload( "res://assets/creatures/human/textures/human_female_hair_002.png" )
# elif self.creature.get_data( "sex" ) == Globals.SEX.male:
# if self.creature.get_data( "hair" ) == 0:
# self.get_node( "hair_parts/mh_human_male_hair" ).hide()
# elif self.creature.get_data( "hair" ) == 1:
# self.get_node( "hair_parts/mh_human_male_hair" ).show()
# self.get_node( "hair_parts/mh_human_male_hair/skeleton/hair" ).get_surface_material( 0 ).albedo_texture = preload( "res://assets/creatures/human/textures/human_male_hair.png" )
#
#
# for hair in $hair_parts.get_children():
# if hair.has_node( "skeleton/hair" ) and hair.get_node( "skeleton/hair" ).get_surface_material( 0 ):
# hair.get_node( "skeleton/hair" ).get_surface_material( 0 ).albedo_color = self.creature.get_data( "hair_color" )
#
#
# if self.creature.get_data( "muscles" ) > 0.0:
# self.set_blend_shape( "muscles_min", 0.0 )
# self.set_blend_shape( "muscles_max", self.creature.get_data( "muscles" ) )
# elif self.creature.get_data( "muscles" ) < 0.0:
# self.set_blend_shape( "muscles_min", -self.creature.get_data( "muscles" ) )
# self.set_blend_shape( "muscles_max", 0.0 )
# else:
# self.set_blend_shape( "muscles_min", 0.0 )
# self.set_blend_shape( "muscles_max", 0.0 )
#
# if self.creature.get_data( "fat" ) > 0.0:
# self.set_blend_shape( "fat_min", 0.0 )
# self.set_blend_shape( "fat_max", self.creature.get_data( "fat" ) )
# elif self.creature.get_data( "fat" ) < 0.0:
# self.set_blend_shape( "fat_min", -self.creature.get_data( "fat" ) )
# self.set_blend_shape( "fat_max", 0.0 )
# else:
# self.set_blend_shape( "fat_min", 0.0 )
# self.set_blend_shape( "fat_max", 0.0 )
#
# if self.creature.get_data( "proportion" ) > 0.0:
# self.set_blend_shape( "proportion_min", 0.0 )
# self.set_blend_shape( "proportion_max", self.creature.get_data( "proportion" ) )
# elif self.creature.get_data( "proportion" ) < 0.0:
# self.set_blend_shape( "proportion_min", -self.creature.get_data( "proportion" ) )
# self.set_blend_shape( "proportion_max", 0.0 )
# else:
# self.set_blend_shape( "proportion_min", 0.0 )
# self.set_blend_shape( "proportion_max", 0.0 )
#
# if self.creature.get_data( "breast" ) > 0.0:
# self.set_blend_shape( "breast_min", 0.0 )
# self.set_blend_shape( "breast_max", self.creature.get_data( "breast" ) )
# elif self.creature.get_data( "breast" ) < 0.0:
# self.set_blend_shape( "breast_min", -self.creature.get_data( "breast" ) )
# self.set_blend_shape( "breast_max", 0.0 )
# else:
# self.set_blend_shape( "breast_min", 0.0 )
# self.set_blend_shape( "breast_max", 0.0 )
#
# if self.creature.get_data( "sex" ) == Globals.SEX.female:
# self.set_blend_shape( "pregnancy", self.creature.get_data( "pregnancy" ) )
#
# # Skin tone.
# if self.get_node( "body_parts/body/skeleton/body" ).get( "material/0" ) and self.get_node( "body_parts/body/skeleton/body" ).get( "material/0" ) is ShaderMaterial:
# var color = self.get_node( "body_parts/body/skeleton/body" ).get( "material/0" ).get_shader_param( "albedo" )
# color.v = 1.0 - self.creature.get_data( "skin_tone" )
# self.get_node( "body_parts/body/skeleton/body" ).get( "material/0" ).set_shader_param( "albedo", color )
#
# self.set_blend_shape( "cleft_chin", self.creature.get_data( "cleft_chin" ) )
# self.set_blend_shape( "chin_angle", self.creature.get_data( "chin_angle" ) )
#
# if self.creature.get_data( "mouth_horiz" ) > 0.0:
# self.set_blend_shape( "mouth_horiz_min", 0.0 )
# self.set_blend_shape( "mouth_horiz_max", self.creature.get_data( "mouth_horiz" ) )
# elif self.creature.get_data( "mouth_horiz" ) < 0.0:
# self.set_blend_shape( "mouth_horiz_min", -self.creature.get_data( "mouth_horiz" ) )
# self.set_blend_shape( "mouth_horiz_max", 0.0 )
# else:
# self.set_blend_shape( "mouth_horiz_min", 0.0 )
# self.set_blend_shape( "mouth_horiz_max", 0.0 )
#
# if self.creature.get_data( "mouth_vert" ) > 0.0:
# self.set_blend_shape( "mouth_vert_min", 0.0 )
# self.set_blend_shape( "mouth_vert_max", self.creature.get_data( "mouth_vert" ) )
# elif self.creature.get_data( "mouth_vert" ) < 0.0:
# self.set_blend_shape( "mouth_vert_min", -self.creature.get_data( "mouth_vert" ) )
# self.set_blend_shape( "mouth_vert_max", 0.0 )
# else:
# self.set_blend_shape( "mouth_vert_min", 0.0 )
# self.set_blend_shape( "mouth_vert_max", 0.0 )
#
# if self.creature.get_data( "nose_galbe" ) > 0.0:
# self.set_blend_shape( "nose_galbe_min", 0.0 )
# self.set_blend_shape( "nose_galbe_max", self.creature.get_data( "nose_galbe" ) )
# elif self.creature.get_data( "nose_galbe" ) < 0.0:
# self.set_blend_shape( "nose_galbe_min", -self.creature.get_data( "nose_galbe" ) )
# self.set_blend_shape( "nose_galbe_max", 0.0 )
# else:
# self.set_blend_shape( "nose_galbe_min", 0.0 )
# self.set_blend_shape( "nose_galbe_max", 0.0 )
#
# if self.creature.get_data( "nose_grec" ) > 0.0:
# self.set_blend_shape( "nose_grec_min", 0.0 )
# self.set_blend_shape( "nose_grec_max", self.creature.get_data( "nose_grec" ) )
# elif self.creature.get_data( "nose_grec" ) < 0.0:
# self.set_blend_shape( "nose_grec_min", -self.creature.get_data( "nose_grec" ) )
# self.set_blend_shape( "nose_grec_max", 0.0 )
# else:
# self.set_blend_shape( "nose_grec_min", 0.0 )
# self.set_blend_shape( "nose_grec_max", 0.0 )
#
# if self.creature.get_data( "nose_horiz" ) > 0.0:
# self.set_blend_shape( "nose_horiz_min", 0.0 )
# self.set_blend_shape( "nose_horiz_max", self.creature.get_data( "nose_horiz" ) )
# elif self.creature.get_data( "nose_horiz" ) < 0.0:
# self.set_blend_shape( "nose_horiz_min", -self.creature.get_data( "nose_horiz" ) )
# self.set_blend_shape( "nose_horiz_max", 0.0 )
# else:
# self.set_blend_shape( "nose_horiz_min", 0.0 )
# self.set_blend_shape( "nose_horiz_max", 0.0 )
#
# if self.creature.get_data( "nose_depth" ) > 0.0:
# self.set_blend_shape( "nose_depth_min", 0.0 )
# self.set_blend_shape( "nose_depth_max", self.creature.get_data( "nose_depth" ) )
# elif self.creature.get_data( "nose_depth" ) < 0.0:
# self.set_blend_shape( "nose_depth_min", -self.creature.get_data( "nose_depth" ) )
# self.set_blend_shape( "nose_depth_max", 0.0 )
# else:
# self.set_blend_shape( "nose_depth_min", 0.0 )
# self.set_blend_shape( "nose_depth_max", 0.0 )
#
#
# self.get_node( "body_parts/body/skeleton/eyes" ).get_surface_material( 0 ).albedo_texture = load( "res://assets/creatures/human/textures/"+self.eye_color_list[ self.creature.get_data( "eyes_color", 0 ) ]+".png" )
#
# if self.creature.get_data( "eyes_vert" ) > 0.0:
# self.set_blend_shape( "eyes_vert_min", 0.0 )
# self.set_blend_shape( "eyes_vert_max", self.creature.get_data( "eyes_vert" ) )
# elif self.creature.get_data( "eyes_vert" ) < 0.0:
# self.set_blend_shape( "eyes_vert_min", -self.creature.get_data( "eyes_vert" ) )
# self.set_blend_shape( "eyes_vert_max", 0.0 )
# else:
# self.set_blend_shape( "eyes_vert_min", 0.0 )
# self.set_blend_shape( "eyes_vert_max", 0.0 )
#
# if self.creature.get_data( "eyes_gap" ) > 0.0:
# self.set_blend_shape( "eyes_gap_min", 0.0 )
# self.set_blend_shape( "eyes_gap_max", self.creature.get_data( "eyes_gap" ) )
# elif self.creature.get_data( "eyes_gap" ) < 0.0:
# self.set_blend_shape( "eyes_gap_min", -self.creature.get_data( "eyes_gap" ) )
# self.set_blend_shape( "eyes_gap_max", 0.0 )
# else:
# self.set_blend_shape( "eyes_gap_min", 0.0 )
# self.set_blend_shape( "eyes_gap_max", 0.0 )
#
# self.set_blend_shape( "earlobes", self.creature.get_data( "earlobes" ) )
# self.set_blend_shape( "ears_wing", self.creature.get_data( "ears_wing" ) )
#
# if self.creature.get_data( "lips_up_shape" ) > 0.0:
# self.set_blend_shape( "lips_up_shape_min", 0.0 )
# self.set_blend_shape( "lips_up_shape_max", self.creature.get_data( "lips_up_shape" ) )
# elif self.creature.get_data( "lips_up_shape" ) < 0.0:
# self.set_blend_shape( "lips_up_shape_min", -self.creature.get_data( "lips_up_shape" ) )
# self.set_blend_shape( "lips_up_shape_max", 0.0 )
# else:
# self.set_blend_shape( "lips_up_shape_min", 0.0 )
# self.set_blend_shape( "lips_up_shape_max", 0.0 )
#
# if self.creature.get_data( "lips_up_shape_2" ) > 0.0:
# self.set_blend_shape( "lips_up_shape_2_min", 0.0 )
# self.set_blend_shape( "lips_up_shape_2_max", self.creature.get_data( "lips_up_shape_2" ) )
# elif self.creature.get_data( "lips_up_shape_2" ) < 0.0:
# self.set_blend_shape( "lips_up_shape_2_min", -self.creature.get_data( "lips_up_shape_2" ) )
# self.set_blend_shape( "lips_up_shape_2_max", 0.0 )
# else:
# self.set_blend_shape( "lips_up_shape_2_min", 0.0 )
# self.set_blend_shape( "lips_up_shape_2_max", 0.0 )
#
# self.set_blend_shape( "nipple_flat", 1.0 )
pass
func play( anim_name, speed = 1.0 ):
for child in $body_parts.get_children():
child.get_node( "AnimationPlayer" ).playback_speed = speed
if child.get_node( "AnimationPlayer" ).has_animation( anim_name ):
child.get_node( "AnimationPlayer" ).play( anim_name )
func play_backwards( anim_name, speed = 1.0 ):
for child in $body_parts.get_children():
child.get_node( "AnimationPlayer" ).playback_speed = speed
if child.get_node( "AnimationPlayer" ).has_animation( anim_name ):
child.get_node( "AnimationPlayer" ).play_backwards( anim_name )
# for child in $hair_parts.get_children():
# child.get_node( "skeleton/AnimationPlayer" ).playback_speed = speed
# if child.get_node( "skeleton/AnimationPlayer" ).has_animation( anim_name ):
# child.get_node( "skeleton/AnimationPlayer" ).play_backwards( anim_name )
# for child in $cloths.get_children():
# child.get_node( "skeleton/AnimationPlayer" ).playback_speed = speed
# if child.get_node( "skeleton/AnimationPlayer" ).has_animation( anim_name ):
# child.get_node( "skeleton/AnimationPlayer" ).play_backwards( anim_name )
func can_turn():
# var animation_player = $body_parts/body/skeleton/AnimationPlayer
# return (animation_player.current_animation.begins_with( "turn_") and animation_player.current_animation_position >= 1.2) or (not animation_player.current_animation.begins_with( "turn_") and not animation_player.current_animation.begins_with( "idle"))
return true
func equip( p_item, p_slot = null ):
# var model = load( p_item.get_data( "model_equiped", "") )
# if not model:
# model = load( p_item.get_data( "model", "") )
# if model:
# model = model.instance()
# var attachment = null
# if not p_slot:
# p_slot = p_item.get_data( "default_slot" )
# if p_slot and int(p_slot) in self.slots:
# self.unequip( p_slot )
# attachment = self.slots[ int(p_slot) ].attachment
# self.slots[ int(p_slot) ].item = p_item
# if attachment:
# if attachment == "cloths":
# model.name = str(int(p_slot))
# $cloths.add_child( model )
# var animation = $body_parts/body/skeleton/AnimationPlayer.current_animation
# var animation_position = $body_parts/body/skeleton/AnimationPlayer.current_animation_position
# var animation_speed = $body_parts/body/skeleton/AnimationPlayer.playback_speed
# model.get_node( "skeleton/AnimationPlayer" ).stop()
# model.get_node( "skeleton/AnimationPlayer" ).set( "playback_speed", animation_speed )
# model.get_node( "skeleton/AnimationPlayer" ).play( animation )
# model.get_node( "skeleton/AnimationPlayer" ).advance( animation_position )
# else:
# if $body_parts/body/skeleton.has_node( attachment ):
# $body_parts/body/skeleton.get_node( attachment ).get_node( "handle" ).add_child( model )
#
# emit_signal( "equip", int(p_slot), p_item )
pass
func unequip( p_slot ):
# if p_slot and int(p_slot) in self.slots:
# if self.slots[ int(p_slot) ].item:
# var attachment = self.slots[ int(p_slot) ].attachment
# self.slots[ int(p_slot) ].item = null
# if attachment:
# if attachment == "cloths":
# var node = $cloths.get_node( str(p_slot) )
# if node:
# $cloths.remove_child( node )
# node.queue_free()
# else:
# for child in $body_parts/body/skeleton.get_node( attachment ).get_node( "handle" ).get_children():
# $body_parts/body/skeleton.get_node( attachment ).get_node( "handle" ).remove_child( child )
# child.queue_free()
# emit_signal( "unequip", int(p_slot) )
pass
func drop_item( p_item ):
# var new_inventory = self.creature.get_data( "inventory" )
# var item_index = new_inventory.find( p_item )
# if item_index != -1:
# if new_inventory[ item_index ].get_data( "dropable", true ):
# new_inventory[ item_index ].set_data( "number", new_inventory[ item_index ].get_data( "number" )-1 )
#
# if new_inventory[ item_index ].get_data( "number" ) <= 0:
# new_inventory.remove( item_index )
#
# var pickup_item_node = preload( "res://scenes/items/pickup_item.tscn" ).instance()
# pickup_item_node.item_filename = p_item.get_filename()
# pickup_item_node.global_transform = $drop_point.global_transform
#
# var pickup_item = Datas.PickupItem.new( p_item.get_filename(), $drop_point.global_transform, p_item )
# pickup_item_node.item = pickup_item
#
# if self.get_tree().get_root().has_node( "main/scene/game" ):
# self.get_tree().get_root().get_node( "main/scene/game" ).get_node( "pickups" ).add_child( pickup_item_node )
pass
func _on_body_animation_finished( anim_name ):
emit_signal( "animation_finished", anim_name )
func _on_body_limb_body_entered(limb, body):
if body.is_in_group( "bullet" ):
if limb == Datas.Cloth.LIMB.head:
#var blood_particle = preload( "res://scenes/fx/blood_particles.tscn" ).instance()
#$body_parts/body/skeleton/limb_head.add_child( blood_particle )
#blood_particle.emit()
#emit_signal( "is_dead" )
#self.creature.set_data( "current_life", 0.0 )
pass
else:
#var blood_particle = preload( "res://scenes/fx/blood_particles.tscn" ).instance()
#$body_parts/body/skeleton/limb_torso_1.add_child( blood_particle )
#blood_particle.emit()
pass

View file

@ -0,0 +1,12 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/creatures/arche/arche.tscn" type="PackedScene" id=1]
[ext_resource path="res://assets/creatures/arche/skin_arche.gd" type="Script" id=2]
[node name="collision_shape" type="CollisionShape"]
script = ExtResource( 2 )
[node name="body_parts" type="Spatial" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -1, 0 )
[node name="arche" parent="body_parts" instance=ExtResource( 1 )]

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,231 @@
[gd_scene load_steps=24 format=2]
[ext_resource path="res://assets/decors/buildings/dispensaire/dispensaire_chambre_d.gltf" type="PackedScene" id=1]
[ext_resource path="res://assets/decors/buildings/dispensaire/Material_001.material" type="Material" id=2]
[ext_resource path="res://assets/decors/buildings/dispensaire/Material_009.material" type="Material" id=3]
[ext_resource path="res://assets/decors/buildings/dispensaire/Material_004.material" type="Material" id=4]
[ext_resource path="res://assets/decors/buildings/dispensaire/Material_005.material" type="Material" id=5]
[ext_resource path="res://assets/decors/buildings/dispensaire/Material_002.material" type="Material" id=6]
[sub_resource type="ArrayMesh" id=2]
resource_name = "Mur001001"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 2 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=11]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ArrayMesh" id=3]
resource_name = "Mur001002"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 2 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=12]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ArrayMesh" id=4]
resource_name = "Mur001003"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 2 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=13]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ConcavePolygonShape" id=5]
data = PoolVector3Array( 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1 )
[sub_resource type="ArrayMesh" id=10]
resource_name = "Mur002004"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 3 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=14]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ArrayMesh" id=7]
resource_name = "Mur002003"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 5 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=15]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ArrayMesh" id=6]
resource_name = "Mur002002"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2, 2, 2.00001 ),
"array_data": PoolByteArray( 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56 ),
"array_index_data": PoolByteArray( 0, 0, 9, 0, 3, 0, 0, 0, 6, 0, 9, 0, 8, 0, 21, 0, 10, 0, 8, 0, 19, 0, 21, 0, 20, 0, 17, 0, 23, 0, 20, 0, 14, 0, 17, 0, 13, 0, 4, 0, 15, 0, 13, 0, 2, 0, 4, 0, 7, 0, 12, 0, 18, 0, 7, 0, 1, 0, 12, 0, 22, 0, 5, 0, 11, 0, 22, 0, 16, 0, 5, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 4 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=16]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[sub_resource type="ConcavePolygonShape" id=1]
data = PoolVector3Array( 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1 )
[sub_resource type="ArrayMesh" id=8]
resource_name = "Sol003"
surfaces/0 = {
"aabb": AABB( -1, -1, -1, 2.00001, 2.00001, 2 ),
"array_data": PoolByteArray( 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 191, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 56, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 128, 63, 127, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 52, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 57, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 191, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 56, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 129, 0, 0, 127, 0, 127, 0, 54, 0, 58, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 57, 0, 60, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 57, 0, 0, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 128, 63, 0, 127, 0, 0, 129, 0, 0, 127, 0, 59, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 129, 0, 0, 0, 0, 127, 0, 127, 0, 54, 0, 60, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 129, 0, 0, 127, 0, 0, 127, 0, 48, 0, 52, 0, 0, 128, 191, 0, 0, 128, 191, 0, 0, 128, 63, 0, 0, 127, 0, 0, 127, 0, 127, 0, 54, 0, 0 ),
"array_index_data": PoolByteArray( 1, 0, 20, 0, 14, 0, 1, 0, 7, 0, 20, 0, 10, 0, 19, 0, 6, 0, 10, 0, 23, 0, 19, 0, 21, 0, 12, 0, 18, 0, 21, 0, 15, 0, 12, 0, 16, 0, 9, 0, 3, 0, 16, 0, 22, 0, 9, 0, 5, 0, 8, 0, 2, 0, 5, 0, 11, 0, 8, 0, 17, 0, 0, 0, 13, 0, 17, 0, 4, 0, 0, 0 ),
"blend_shape_data": [ ],
"format": 97559,
"index_count": 36,
"material": ExtResource( 6 ),
"primitive": 4,
"skeleton_aabb": [ ],
"vertex_count": 24
}
[sub_resource type="ConcavePolygonShape" id=17]
data = PoolVector3Array( 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1 )
[sub_resource type="ConcavePolygonShape" id=18]
data = PoolVector3Array( -1, -1, -0.75, -1, 1, -1, -1, 1, -0.75, -1, -1, -0.75, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, 0.75, 19, 1, 0.75, 1, 1, 0.75, 1, -1, 0.75, 19, -1, 0.75, 19, 1, 0.75, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, 0.75, 1, -1, 1, 1, -1, 0.75, -1, -1, 0.75, -1, -1, 1, 1, -1, 1, 1, 1, 0.75, -1, 1, 1, -1, 1, 0.75, 1, 1, 0.75, 1, 1, 1, -1, 1, 1, 1, 1, -0.25, -1, 1, 0, -1, 1, -0.25, 1, 1, -0.25, 1, 1, 0, -1, 1, 0, -1, -1, -0.25, 1, -1, 0, 1, -1, -0.25, -1, -1, -0.25, -1, -1, 0, 1, -1, 0, 1, -1, -0.25, 1, 1, 0, 1, 1, -0.25, 1, -1, -0.25, 1, -1, 0, 1, 1, 0, -1, -1, 0.25, -1, 1, 0, -1, 1, 0.25, -1, -1, 0.25, -1, -1, 0, -1, 1, 0, -1, -1, 0.75, -1, 1, 0.5, -1, 1, 0.75, -1, -1, 0.75, -1, -1, 0.5, -1, 1, 0.5, 1, 1, 0.25, -1, 1, 0.5, -1, 1, 0.25, 1, 1, 0.25, 1, 1, 0.5, -1, 1, 0.5, -1, -1, 0.25, 1, -1, 0.5, 1, -1, 0.25, -1, -1, 0.25, -1, -1, 0.5, 1, -1, 0.5, 1, -1, 0.25, 1, 1, 0.5, 1, 1, 0.25, 1, -1, 0.25, 1, -1, 0.5, 1, 1, 0.5, 1, -1, -0.75, 1, 1, -0.5, 1, 1, -0.75, 1, -1, -0.75, 1, -1, -0.5, 1, 1, -0.5, -1, -1, -0.75, 1, -1, -0.5, 1, -1, -0.75, -1, -1, -0.75, -1, -1, -0.5, 1, -1, -0.5, 1, 1, -0.75, -1, 1, -0.5, -1, 1, -0.75, 1, 1, -0.75, 1, 1, -0.5, -1, 1, -0.5, -1, -1, -0.25, -1, 1, -0.5, -1, 1, -0.25, -1, -1, -0.25, -1, -1, -0.5, -1, 1, -0.5, -1, -1, 1, -1, 1, 0.75, -1, 1, 1, -1, -1, 1, -1, -1, 0.75, -1, 1, 0.75, 1, 1, 0.5, -1, 1, 0.75, -1, 1, 0.5, 1, 1, 0.5, 1, 1, 0.75, -1, 1, 0.75, -1, -1, 0.5, 1, -1, 0.75, 1, -1, 0.5, -1, -1, 0.5, -1, -1, 0.75, 1, -1, 0.75, 1, -1, 0.5, 1, 1, 0.75, 1, 1, 0.5, 1, -1, 0.5, 1, -1, 0.75, 1, 1, 0.75, 1, 1, -1, -1, 1, -0.75, -1, 1, -1, 1, 1, -1, 1, 1, -0.75, -1, 1, -0.75, -1, -1, -1, 1, -1, -0.75, 1, -1, -1, -1, -1, -1, -1, -1, -0.75, 1, -1, -0.75, 1, -1, -1, 19, 1, -1, 1, 1, -1, 1, -1, -1, 19, -1, -1, 19, 1, -1, -1, -1, -0.5, -1, 1, -0.75, -1, 1, -0.5, -1, -1, -0.5, -1, -1, -0.75, -1, 1, -0.75, 1, -1, 0, 1, 1, 0.25, 1, 1, 0, 1, -1, 0, 1, -1, 0.25, 1, 1, 0.25, -1, -1, 0, 1, -1, 0.25, 1, -1, 0, -1, -1, 0, -1, -1, 0.25, 1, -1, 0.25, 1, 1, 0, -1, 1, 0.25, -1, 1, 0, 1, 1, 0, 1, 1, 0.25, -1, 1, 0.25, -1, -1, 0.5, -1, 1, 0.25, -1, 1, 0.5, -1, -1, 0.5, -1, -1, 0.25, -1, 1, 0.25, -1, -1, 0, -1, 1, -0.25, -1, 1, 0, -1, -1, 0, -1, -1, -0.25, -1, 1, -0.25, 1, -1, -0.5, 1, 1, -0.25, 1, 1, -0.5, 1, -1, -0.5, 1, -1, -0.25, 1, 1, -0.25, -1, -1, -0.5, 1, -1, -0.25, 1, -1, -0.5, -1, -1, -0.5, -1, -1, -0.25, 1, -1, -0.25, 1, 1, -0.5, -1, 1, -0.25, -1, 1, -0.5, 1, 1, -0.5, 1, 1, -0.25, -1, 1, -0.25, 19, -1, 0.75, 19, 1, 1, 19, 1, 0.75, 19, -1, 0.75, 19, -1, 1, 19, 1, 1, -1, -1, 1, 19, -1, 1, 1, -1, 1, -1, -1, 1, 17, -1, 1, 19, -1, 1, 1, 1, 0.75, 19, 1, 1, 1, 1, 1, 1, 1, 0.75, 19, 1, 0.75, 19, 1, 1, 1, -1, 1, 19, -1, 0.75, 1, -1, 0.75, 1, -1, 1, 19, -1, 1, 19, -1, 0.75, 1, 1, 1, 19, -1, 1, 1, -1, 1, 1, 1, 1, 19, 1, 1, 19, -1, 1, 19, -1, -1, 19, 1, -0.75, 19, 1, -1, 19, -1, -1, 19, -1, -0.75, 19, 1, -0.75, 1, 1, -0.75, 19, -1, -0.75, 1, -1, -0.75, 1, 1, -0.75, 19, 1, -0.75, 19, -1, -0.75, 1, -1, -0.75, 19, -1, -1, 1, -1, -1, 1, -1, -0.75, 19, -1, -0.75, 19, -1, -1, 1, 1, -1, 19, 1, -0.75, 1, 1, -0.75, 1, 1, -1, 19, 1, -1, 19, 1, -0.75 )
[node name="dispensaire_chambre_d" instance=ExtResource( 1 )]
[node name="Mur001001" type="MeshInstance" parent="Soll001" index="0"]
transform = Transform( 1, 0, 0, 0, 3, 0, 0, 0, 0.1, 0, 4, -0.9 )
mesh = SubResource( 2 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Soll001/Mur001001" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Soll001/Mur001001/static_body" index="0"]
shape = SubResource( 11 )
[node name="Mur001002" type="MeshInstance" parent="Soll001" index="1"]
transform = Transform( 1, 0, 0, 0, 3, 0, 0, 0, 0.1, 0, 4, 0.9 )
mesh = SubResource( 3 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Soll001/Mur001002" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Soll001/Mur001002/static_body" index="0"]
shape = SubResource( 12 )
[node name="Mur001003" type="MeshInstance" parent="Soll001" index="2"]
transform = Transform( 0.1, 0, 0, 0, 3, 0, 0, 0, 0.8, -0.9, 4, 0 )
mesh = SubResource( 4 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Soll001/Mur001003" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Soll001/Mur001003/static_body" index="0"]
shape = SubResource( 13 )
[node name="static_body" type="StaticBody" parent="Soll001" index="3"]
[node name="collision_shape" type="CollisionShape" parent="Soll001/static_body" index="0"]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )
shape = SubResource( 5 )
[node name="Mur002004" type="MeshInstance" parent="Sol002" index="0"]
transform = Transform( 1, 0, 0, 0, 3, 0, 0, 0, 0.1, 0, 4, -0.9 )
mesh = SubResource( 10 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Sol002/Mur002004" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Sol002/Mur002004/static_body" index="0"]
shape = SubResource( 14 )
[node name="Mur002003" type="MeshInstance" parent="Sol002" index="1"]
transform = Transform( 0.1, 0, 0, 0, 4, 0, 0, 0, 0.8, -0.9, 5, 0 )
mesh = SubResource( 7 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Sol002/Mur002003" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Sol002/Mur002003/static_body" index="0"]
shape = SubResource( 15 )
[node name="Mur002002" type="MeshInstance" parent="Sol002" index="2"]
transform = Transform( 1, 0, 0, 0, 3, 0, 0, 0, 0.1, 0, 4, 0.9 )
mesh = SubResource( 6 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Sol002/Mur002002" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Sol002/Mur002002/static_body" index="0"]
shape = SubResource( 16 )
[node name="static_body" type="StaticBody" parent="Sol002" index="3"]
[node name="collision_shape" type="CollisionShape" parent="Sol002/static_body" index="0"]
shape = SubResource( 1 )
[node name="Sol003" type="MeshInstance" parent="Mur003001" index="0"]
transform = Transform( 10, 0, 0, 0, 0.2, 0, 0, 0, 1, 9, -1.2, 0 )
mesh = SubResource( 8 )
material/0 = null
[node name="static_body" type="StaticBody" parent="Mur003001/Sol003" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Mur003001/Sol003/static_body" index="0"]
shape = SubResource( 17 )
[node name="static_body" type="StaticBody" parent="Mur003001" index="1"]
[node name="collision_shape" type="CollisionShape" parent="Mur003001/static_body" index="0"]
shape = SubResource( 18 )

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,5 @@
[gd_scene load_steps=2 format=2]
[ext_resource path="res://assets/decors/buildings/dispensaire/dispensaire_zone_plafond.glb" type="PackedScene" id=1]
[node name="dispensaire_zone_plafond" instance=ExtResource( 1 )]

View file

@ -0,0 +1,13 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/decors/buildings/dispensaire/dispensaire_zone_sol.glb" type="PackedScene" id=1]
[sub_resource type="ConcavePolygonShape" id=1]
data = PoolVector3Array( -1, -1, 1, -1, 1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, -1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, 1, 1, 1, -1, 1, -1, 1, 1, 1, 1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, -1, 1, 1, -1, -1, -1, -1, -1, -1, -1, 1, 1, -1, 1, 1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, 1, 1, -1, 1, 1 )
[node name="dispensaire_zone_sol" instance=ExtResource( 1 )]
[node name="static_body" type="StaticBody" parent="Cube" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Cube/static_body" index="0"]
shape = SubResource( 1 )

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,13 @@
[gd_scene load_steps=3 format=2]
[ext_resource path="res://assets/decors/buildings/hall_01/hall_04.gltf" type="PackedScene" id=1]
[sub_resource type="ConcavePolygonShape" id=1]
data = PoolVector3Array( -10, 0, 10, 10, 0, -10, 10, 0, 10, -10, 0, 10, -10, 0, -10, 10, 0, -10 )
[node name="hall_04" instance=ExtResource( 1 )]
[node name="static_body" type="StaticBody" parent="Sol" index="0"]
[node name="collision_shape" type="CollisionShape" parent="Sol/static_body" index="0"]
shape = SubResource( 1 )

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -398,8 +398,7 @@ func drop_item( p_item ):
if self.get_tree().get_root().has_node( "main/scene/game" ):
self.get_tree().get_root().get_node( "main/scene/game" ).get_node( "pickups" ).add_child( pickup_item_node )
func _on_body_animation_finished( anim_name ):
emit_signal( "animation_finished", anim_name )

View file

@ -17,219 +17,219 @@ onready var sex_popup = $margin_box/window_box/content_box/tabs_box/definition/s
var max_caracteristiques_points = 5*5 + 5
func _ready():
# Race.
race_popup.add_item( Globals.race_label[ Globals.RACE.human ] )
race_popup.connect("id_pressed", self, "_on_race_id_pressed")
# Race.
race_popup.add_item( Globals.race_label[ Globals.RACE.human ] )
race_popup.connect("id_pressed", self, "_on_race_id_pressed")
# Sex.
sex_popup.add_item( Globals.sex_label[ Globals.SEX.female ] )
sex_popup.add_item( Globals.sex_label[ Globals.SEX.male ] )
sex_popup.connect("id_pressed", self, "_on_sex_id_pressed")
# Sex.
sex_popup.add_item( Globals.sex_label[ Globals.SEX.female ] )
sex_popup.add_item( Globals.sex_label[ Globals.SEX.male ] )
sex_popup.connect("id_pressed", self, "_on_sex_id_pressed")
func _on_race_id_pressed( ID ):
$margin_box/window_box/content_box/tabs_box/definition/race/value.text = race_popup.get_item_text( ID )
emit_signal( "updated", "race", ID )
$margin_box/window_box/content_box/tabs_box/definition/race/value.text = race_popup.get_item_text( ID )
emit_signal( "updated", "race", ID )
func _on_sex_id_pressed( ID ):
$margin_box/window_box/content_box/tabs_box/definition/sex/value.text = sex_popup.get_item_text( ID )
emit_signal( "updated", "sex", ID )
if ID == Globals.SEX.male:
$margin_box/window_box/content_box/tabs_box/Corps/aspect/female_label.hide()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/breast.hide()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/pregnancy.hide()
else:
$margin_box/window_box/content_box/tabs_box/Corps/aspect/female_label.show()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/breast.show()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/pregnancy.show()
$margin_box/window_box/content_box/tabs_box/definition/sex/value.text = sex_popup.get_item_text( ID )
emit_signal( "updated", "sex", ID )
if ID == Globals.SEX.male:
$margin_box/window_box/content_box/tabs_box/Corps/aspect/female_label.hide()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/breast.hide()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/pregnancy.hide()
else:
$margin_box/window_box/content_box/tabs_box/Corps/aspect/female_label.show()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/breast.show()
$margin_box/window_box/content_box/tabs_box/Corps/aspect/pregnancy.show()
func update_sliders( p_creature ):
var race = p_creature.get_data( "race", Globals.RACE.human )
self._on_race_id_pressed( race )
var sex = p_creature.get_data( "sex", Globals.SEX.female )
self._on_sex_id_pressed( sex )
var race = p_creature.get_data( "race", Globals.RACE.human )
self._on_race_id_pressed( race )
var sex = p_creature.get_data( "sex", Globals.SEX.female )
self._on_sex_id_pressed( sex )
for child in $margin_box/window_box/content_box/tabs_box/Corps/aspect.get_children():
if not child is Label:
if child.get_node( "value" ) is ColorPickerButton:
child.get_node( "value" ).color = p_creature.get_data( child.name, Color.white )
else:
child.get_node( "value" ).value = p_creature.get_data( child.name, 0.0 )
for child in self.get_node( "margin_box/window_box/content_box/tabs_box/Tête/aspect" ).get_children():
if not child is Label:
if child.get_node( "value" ) is ColorPickerButton:
child.get_node( "value" ).color = p_creature.get_data( child.name, Color.white )
else:
child.get_node( "value" ).value = p_creature.get_data( child.name, 0.0 )
for child in $margin_box/window_box/content_box/tabs_box/Corps/aspect.get_children():
if not child is Label:
if child.get_node( "value" ) is ColorPickerButton:
child.get_node( "value" ).color = p_creature.get_data( child.name, Color.white )
else:
child.get_node( "value" ).value = p_creature.get_data( child.name, 0.0 )
for child in self.get_node( "margin_box/window_box/content_box/tabs_box/Tête/aspect" ).get_children():
if not child is Label:
if child.get_node( "value" ) is ColorPickerButton:
child.get_node( "value" ).color = p_creature.get_data( child.name, Color.white )
else:
child.get_node( "value" ).value = p_creature.get_data( child.name, 0.0 )
func update_caracteristique( p_name, p_value ):
var total_points = 0
for caracteristique in $margin_box/window_box/content_box/tabs_box/caracteristiques.get_children():
if not caracteristique.name == "lasting_points":
total_points += caracteristique.get_node( "value" ).value
$margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text = str(self.max_caracteristiques_points - total_points)
var total_points = 0
for caracteristique in $margin_box/window_box/content_box/tabs_box/caracteristiques.get_children():
if not caracteristique.name == "lasting_points":
total_points += caracteristique.get_node( "value" ).value
$margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text = str(self.max_caracteristiques_points - total_points)
if int($margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text) < 0:
var other_points = total_points - p_value
var other_lasting_points = self.max_caracteristiques_points - other_points
self.get_node( "margin_box/window_box/content_box/tabs_box/caracteristiques/"+p_name+"/value" ).value = other_lasting_points
$margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text = "0"
if int($margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text) < 0:
var other_points = total_points - p_value
var other_lasting_points = self.max_caracteristiques_points - other_points
self.get_node( "margin_box/window_box/content_box/tabs_box/caracteristiques/"+p_name+"/value" ).value = other_lasting_points
$margin_box/window_box/content_box/tabs_box/caracteristiques/lasting_points/value.text = "0"
func _on_first_name_text_entered(new_text):
emit_signal( "updated", "first_name", new_text )
emit_signal( "updated", "first_name", new_text )
func _on_last_name_text_entered(new_text):
emit_signal( "updated", "last_name", new_text )
emit_signal( "updated", "last_name", new_text )
func _on_size_value_changed(value):
emit_signal( "updated", "size", value )
emit_signal( "updated", "size", value )
func _on_fat_value_changed(value):
emit_signal( "updated", "fat", value )
emit_signal( "updated", "fat", value )
func _on_muscle_value_changed(value):
emit_signal( "updated", "muscles", value )
emit_signal( "updated", "muscles", value )
func _on_breast_value_changed(value):
emit_signal( "updated", "breast", value )
emit_signal( "updated", "breast", value )
func _on_pregnancy_value_changed(value):
emit_signal( "updated", "pregnancy", value )
emit_signal( "updated", "pregnancy", value )
func _on_skin_tone_value_changed(value):
emit_signal( "updated", "skin_tone", value )
emit_signal( "updated", "skin_tone", value )
func _on_hair_value_changed(value):
emit_signal( "updated", "hair", value )
emit_signal( "updated", "hair", value )
func _on_hair_color_color_changed( color ):
emit_signal( "updated", "hair_color", color )
emit_signal( "updated", "hair_color", color )
func _on_caucasian_value_changed(value):
emit_signal( "updated", "caucasian", value )
emit_signal( "updated", "caucasian", value )
func _on_african_value_changed(value):
emit_signal( "updated", "african", value )
emit_signal( "updated", "african", value )
func _on_asian_value_changed(value):
emit_signal( "updated", "asian", value )
emit_signal( "updated", "asian", value )
func _on_first_name_text_changed(new_text):
emit_signal( "updated", "first_name", new_text )
emit_signal( "updated", "first_name", new_text )
func _on_last_name_text_changed(new_text):
emit_signal( "updated", "last_name", new_text )
emit_signal( "updated", "last_name", new_text )
func _on_proportion_value_changed(value):
emit_signal( "updated", "proportion", value )
emit_signal( "updated", "proportion", value )
func _on_strength_value_changed(value):
self.update_caracteristique( "strength", value )
self.update_caracteristique( "strength", value )
func _on_perception_value_changed(value):
self.update_caracteristique( "perception", value )
self.update_caracteristique( "perception", value )
func _on_endurance_value_changed(value):
self.update_caracteristique( "endurance", value )
self.update_caracteristique( "endurance", value )
func _on_constitution_value_changed(value):
self.update_caracteristique( "constitution", value )
self.update_caracteristique( "constitution", value )
func _on_agility_value_changed(value):
self.update_caracteristique( "agility", value )
self.update_caracteristique( "agility", value )
func _on_cleft_chin_value_changed(value):
emit_signal( "updated", "cleft_chin", value )
emit_signal( "updated", "cleft_chin", value )
func _on_chin_angle_value_changed(value):
emit_signal( "updated", "chin_angle", value )
emit_signal( "updated", "chin_angle", value )
func _on_mouth_horiz_value_changed(value):
emit_signal( "updated", "mouth_horiz", value )
emit_signal( "updated", "mouth_horiz", value )
func _on_mouth_vert_value_changed(value):
emit_signal( "updated", "mouth_vert", value )
emit_signal( "updated", "mouth_vert", value )
func _on_nose_galbe_value_changed(value):
emit_signal( "updated", "nose_galbe", value )
emit_signal( "updated", "nose_galbe", value )
func _on_nose_grec_value_changed(value):
emit_signal( "updated", "nose_grec", value )
emit_signal( "updated", "nose_grec", value )
func _on_nose_horiz_value_changed(value):
emit_signal( "updated", "nose_horiz", value )
emit_signal( "updated", "nose_horiz", value )
func _on_nose_depth_value_changed(value):
emit_signal( "updated", "nose_depth", value )
emit_signal( "updated", "nose_depth", value )
func _on_eyes_color_value_changed(value):
emit_signal( "updated", "eyes_color", value )
emit_signal( "updated", "eyes_color", value )
func _on_eyes_vert_value_changed(value):
emit_signal( "updated", "eyes_vert", value )
emit_signal( "updated", "eyes_vert", value )
func _on_eyes_gap_value_changed(value):
emit_signal( "updated", "eyes_gap", value )
emit_signal( "updated", "eyes_gap", value )
func _on_earlobes_value_changed(value):
emit_signal( "updated", "earlobes", value )
emit_signal( "updated", "earlobes", value )
func _on_ears_wing_value_changed(value):
emit_signal( "updated", "ears_wing", value )
emit_signal( "updated", "ears_wing", value )
func _on_lips_up_shape_value_changed(value):
emit_signal( "updated", "lips_up_shape", value )
emit_signal( "updated", "lips_up_shape", value )
func _on_lips_up_shape_2_value_changed(value):
emit_signal( "updated", "lips_up_shape_2", value )
emit_signal( "updated", "lips_up_shape_2", value )
func _on_skin_value_changed(value):
emit_signal( "updated", "skin", value )
emit_signal( "updated", "skin", value )
func _on_load_pressed():
emit_signal( "load_pressed" )
emit_signal( "load_pressed" )
func _on_save_pressed():
emit_signal( "save_pressed" )
emit_signal( "save_pressed" )
func _on_choose_pressed():
emit_signal( "choose_pressed" )
emit_signal( "choose_pressed" )
func _on_quit_pressed():
emit_signal( "quit_pressed" )
emit_signal( "quit_pressed" )
func _on_creature_creation_menu_mouse_entered():
emit_signal( "mouse_exited_ui")
emit_signal( "mouse_exited_ui")
func _on_creature_creation_menu_mouse_exited():
emit_signal( "mouse_entered_ui")
emit_signal( "mouse_entered_ui")
func _on_cloths_button_toggled(button_pressed):
emit_signal( "cloths_button_toggled", button_pressed )
if button_pressed:
$margin_box/window_box/content_box/preview_box/v_box_container/cloths_button.modulate.a = 1.0
else:
$margin_box/window_box/content_box/preview_box/v_box_container/cloths_button.modulate.a = 0.5
emit_signal( "cloths_button_toggled", button_pressed )
if button_pressed:
$margin_box/window_box/content_box/preview_box/v_box_container/cloths_button.modulate.a = 1.0
else:
$margin_box/window_box/content_box/preview_box/v_box_container/cloths_button.modulate.a = 0.5
func _on_underwear_button_toggled(button_pressed):
emit_signal( "underwear_button_toggled", button_pressed )
if button_pressed:
$margin_box/window_box/content_box/preview_box/v_box_container/underwear_button.modulate.a = 1.0
else:
$margin_box/window_box/content_box/preview_box/v_box_container/underwear_button.modulate.a = 0.5
emit_signal( "underwear_button_toggled", button_pressed )
if button_pressed:
$margin_box/window_box/content_box/preview_box/v_box_container/underwear_button.modulate.a = 1.0
else:
$margin_box/window_box/content_box/preview_box/v_box_container/underwear_button.modulate.a = 0.5
func _on_zoom_head_button_toggled(button_pressed):
emit_signal( "zoom_head_button_toggled", button_pressed )
emit_signal( "zoom_head_button_toggled", button_pressed )

View file

@ -5,161 +5,161 @@ var is_over_ui = false
func _ready():
$creature_creation_menu._on_race_id_pressed( 0 )
$creature_creation_menu._on_sex_id_pressed( 0 )
$creature_creation_menu._on_race_id_pressed( 0 )
$creature_creation_menu._on_sex_id_pressed( 0 )
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.player:
$creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/race.hide()
elif Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
$creature_creation_menu.max_caracteristiques_points = 999
$creature_creation_menu/margin_box/window_box/tools_box/buttons_box/choose.hide()
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.player:
$creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/race.hide()
elif Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
$creature_creation_menu.max_caracteristiques_points = 999
$creature_creation_menu/margin_box/window_box/tools_box/buttons_box/choose.hide()
func _input( event ):
if event is InputEventMouseMotion and Input.is_mouse_button_pressed( 1 ):
if self.character and not self.is_over_ui:
self.character.rotate_y( event.relative.x *0.01 )
if event is InputEventMouseMotion and Input.is_mouse_button_pressed( 3 ):
if not self.is_over_ui:
if $camera.current:
$camera.translation.x -= event.relative.x *0.001
$camera.translation.y += event.relative.y *0.001
elif $camera_head.current:
$camera_head.translation.x -= event.relative.x *0.001
$camera_head.translation.y += event.relative.y *0.001
if event.is_action_pressed( "camera_zoom_in" ) and not self.is_over_ui:
if $camera.current:
$camera.size -= 0.1
elif $camera_head.current:
$camera_head.size -= 0.1
elif event.is_action_pressed( "camera_zoom_out" ) and not self.is_over_ui:
if $camera.current:
$camera.size += 0.1
elif $camera_head.current:
$camera_head.size += 0.1
if event is InputEventMouseMotion and Input.is_mouse_button_pressed( 1 ):
if self.character and not self.is_over_ui:
self.character.rotate_y( event.relative.x *0.01 )
if event is InputEventMouseMotion and Input.is_mouse_button_pressed( 3 ):
if not self.is_over_ui:
if $camera.current:
$camera.translation.x -= event.relative.x *0.001
$camera.translation.y += event.relative.y *0.001
elif $camera_head.current:
$camera_head.translation.x -= event.relative.x *0.001
$camera_head.translation.y += event.relative.y *0.001
if event.is_action_pressed( "camera_zoom_in" ) and not self.is_over_ui:
if $camera.current:
$camera.size -= 0.1
elif $camera_head.current:
$camera_head.size -= 0.1
elif event.is_action_pressed( "camera_zoom_out" ) and not self.is_over_ui:
if $camera.current:
$camera.size += 0.1
elif $camera_head.current:
$camera_head.size += 0.1
func _on_creature_creation_menu_updated(value_name, value):
var need_model_change = false
if value_name == "race":
need_model_change = true
elif value_name == "sex":
need_model_change = true
var need_creature_update =false
if self.character:
self.character.get_node( "creature" ).creature.set_data( value_name, value )
need_creature_update = true
if need_model_change:
var old_creature_datas = null
if self.character:
old_creature_datas = self.character.get_node( "creature" ).creature
var race = old_creature_datas.get_data( "race" )
var sex = old_creature_datas.get_data( "sex" )
if race == Globals.RACE.human and sex == Globals.SEX.female:
self.character.show()
self.character.change_creature( "res://scenes/creatures/human/human_female.tscn" )
need_creature_update = true
elif race == Globals.RACE.human and sex == Globals.SEX.male:
self.character.show()
self.character.change_creature( "res://scenes/creatures/human/human_male.tscn" )
need_creature_update = true
if self.character and old_creature_datas:
self.character.get_node( "creature" ).creature = old_creature_datas
if need_creature_update:
if self.character:
self.character.get_node( "creature" ).update()
var need_model_change = false
if value_name == "race":
need_model_change = true
elif value_name == "sex":
need_model_change = true
var need_creature_update =false
if self.character:
self.character.get_node( "creature" ).creature.set_data( value_name, value )
need_creature_update = true
if need_model_change:
var old_creature_datas = null
if self.character:
old_creature_datas = self.character.get_node( "creature" ).creature
var race = old_creature_datas.get_data( "race" )
var sex = old_creature_datas.get_data( "sex" )
if race == Globals.RACE.human and sex == Globals.SEX.female:
self.character.show()
self.character.change_creature( "res://scenes/creatures/human/human_female.tscn" )
need_creature_update = true
elif race == Globals.RACE.human and sex == Globals.SEX.male:
self.character.show()
self.character.change_creature( "res://scenes/creatures/human/human_male.tscn" )
need_creature_update = true
if self.character and old_creature_datas:
self.character.get_node( "creature" ).creature = old_creature_datas
if need_creature_update:
if self.character:
self.character.get_node( "creature" ).update()
func save_creature():
if self.character:
var emplacement = "pc"
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
emplacement = "res"
self.character.get_node( "creature" ).creature.save( emplacement )
$creature_creation_menu/margin_box/window_box/tooltips.text = "Créature enregistrée."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.green )
if self.character:
var emplacement = "pc"
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
emplacement = "res"
self.character.get_node( "creature" ).creature.save( emplacement )
$creature_creation_menu/margin_box/window_box/tooltips.text = "Créature enregistrée."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.green )
func load_creature( p_name = null ):
var creature = null
var race = Globals.get_race_id( $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/race/value.text )
if race == Globals.RACE.human:
creature = Datas.Human.new()
else:
creature = Datas.Creature.new()
var filename = $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/first_name.text + "_" + $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/last_name.text+".creature"
if p_name:
filename = p_name + ".creature"
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
creature.load( "res://ressources/files/creatures/"+filename )
else:
creature.load( "user://saves/save_temp/ressources/files/creatures/pc/"+filename )
if creature.get_filename() == "unknow.creature":
$creature_creation_menu/margin_box/window_box/tooltips.text = "Echec du chargement de la créature."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.red )
else:
$creature_creation_menu/margin_box/window_box/tooltips.text = "Créature chargée avec succès."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.green )
var creature = null
var race = Globals.get_race_id( $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/race/value.text )
if race == Globals.RACE.human:
creature = Datas.Human.new()
else:
creature = Datas.Creature.new()
var filename = $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/first_name.text + "_" + $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/last_name.text+".creature"
if p_name:
filename = p_name + ".creature"
if Globals.creatures_editor_mode == Globals.CREATURES_EDITOR_MODE.npc:
creature.load( "res://ressources/files/creatures/"+filename )
else:
creature.load( "user://saves/save_temp/ressources/files/creatures/pc/"+filename )
if creature.get_filename() == "unknow.creature":
$creature_creation_menu/margin_box/window_box/tooltips.text = "Echec du chargement de la créature."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.red )
else:
$creature_creation_menu/margin_box/window_box/tooltips.text = "Créature chargée avec succès."
$creature_creation_menu/margin_box/window_box/tooltips.set( "custom_colors/font_color", Color.green )
$creature_creation_menu.update_sliders( creature )
$creature_creation_menu.update_sliders( creature )
func _on_creature_creation_menu_mouse_entered_ui():
self.is_over_ui = true
self.is_over_ui = true
func _on_creature_creation_menu_mouse_exited_ui():
self.is_over_ui = false
self.is_over_ui = false
func _on_creature_creation_menu_load_pressed():
self.load_creature()
self.load_creature()
func _on_creature_creation_menu_save_pressed():
self.save_creature()
self.save_creature()
func _on_creature_creation_menu_choose_pressed():
self.save_creature()
Globals.player_name = $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/first_name.text + "_" + $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/last_name.text
Globals.goto_scene( "res://scenes/game/game.tscn" )
self.save_creature()
Globals.player_name = $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/first_name.text + "_" + $creature_creation_menu/margin_box/window_box/content_box/tabs_box/definition/name/value/last_name.text
Globals.goto_scene( "res://scenes/game/game.tscn" )
func _on_creature_creation_menu_quit_pressed():
Globals.goto_scene( "res://scenes/main/main.tscn" )
Globals.goto_scene( "res://scenes/main/main.tscn" )
func _on_creature_creation_menu_cloths_button_toggled(button_pressed):
if $character/creature.creature.get_data( "sex" ) == Globals.SEX.female:
if button_pressed:
$character/creature/cloths/mh_human_female_tshirt.show()
$character/creature/cloths/mh_human_female_pant.show()
$character/creature/cloths/mh_human_female_shoes.show()
else:
$character/creature/cloths/mh_human_female_tshirt.hide()
$character/creature/cloths/mh_human_female_pant.hide()
$character/creature/cloths/mh_human_female_shoes.hide()
elif $character/creature.creature.get_data( "sex" ) == Globals.SEX.male:
if button_pressed:
$character/creature/cloths/mh_human_male_tshirt.show()
$character/creature/cloths/mh_human_male_pant.show()
$character/creature/cloths/mh_human_male_shoes.show()
else:
$character/creature/cloths/mh_human_male_tshirt.hide()
$character/creature/cloths/mh_human_male_pant.hide()
$character/creature/cloths/mh_human_male_shoes.hide()
if $character/creature.creature.get_data( "sex" ) == Globals.SEX.female:
if button_pressed:
$character/creature/cloths/mh_human_female_tshirt.show()
$character/creature/cloths/mh_human_female_pant.show()
$character/creature/cloths/mh_human_female_shoes.show()
else:
$character/creature/cloths/mh_human_female_tshirt.hide()
$character/creature/cloths/mh_human_female_pant.hide()
$character/creature/cloths/mh_human_female_shoes.hide()
elif $character/creature.creature.get_data( "sex" ) == Globals.SEX.male:
if button_pressed:
$character/creature/cloths/mh_human_male_tshirt.show()
$character/creature/cloths/mh_human_male_pant.show()
$character/creature/cloths/mh_human_male_shoes.show()
else:
$character/creature/cloths/mh_human_male_tshirt.hide()
$character/creature/cloths/mh_human_male_pant.hide()
$character/creature/cloths/mh_human_male_shoes.hide()
func _on_creature_creation_menu_underwear_button_toggled(button_pressed):
pass
pass
# if button_pressed:
# $character/creature/cloths/mh_human_female_underwear_top.show()
# $character/creature/cloths/mh_human_female_underwear_bottom.show()
@ -169,7 +169,7 @@ func _on_creature_creation_menu_underwear_button_toggled(button_pressed):
func _on_creature_creation_menu_zoom_head_button_toggled(button_pressed):
if button_pressed:
$camera_head.make_current()
else:
$camera.make_current()
if button_pressed:
$camera_head.make_current()
else:
$camera.make_current()

View file

@ -15,31 +15,31 @@ signal animation_finished( anim_name )
signal limb_body_entered( limb, body )
func _on_AnimationPlayer_animation_finished(anim_name):
emit_signal( \"animation_finished\", anim_name )
emit_signal( \"animation_finished\", anim_name )
func _on_limb_head_area_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.head, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.head, body )
func _on_limb_tosro_1_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
func _on_limb_torso_2_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
func _on_limb_torso_3_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
func _on_limb_torso_4_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
func _on_limb_torso_5_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.torso, body )
func _on_limb_upper_arm_left_body_entered(body):
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.left_upper_arm, body )
emit_signal( \"limb_body_entered\", Datas.Cloth.LIMB.left_upper_arm, body )
"
@ -67,6 +67,9 @@ height = 0.16166
[node name="mh_human_female" instance=ExtResource( 1 )]
script = SubResource( 1 )
[node name="AnimationPlayer" parent="skeleton" index="0"]
playback_speed = 10.0
[node name="body" parent="skeleton" index="1"]
material/0 = ExtResource( 7 )
@ -86,7 +89,7 @@ material/0 = ExtResource( 6 )
material/0 = ExtResource( 2 )
[node name="limb_head" type="BoneAttachment" parent="skeleton" index="7"]
transform = Transform( 1, 0, 0, 0, 0.0523112, -0.998451, 0, 0.99863, 0.0523236, 0, 0.631645, 0.0409583 )
transform = Transform( 1, 0, 0, 0, 0.0523111, -0.998451, 0, 0.99863, 0.0523234, 0, 0.631645, 0.0409584 )
bone_name = "head"
[node name="area" type="Area" parent="skeleton/limb_head" index="0"]
@ -96,7 +99,7 @@ transform = Transform( 1, 0, 0, 0, 0.999999, -7.45058e-09, 0, 7.45058e-09, 1, 0,
shape = SubResource( 2 )
[node name="limb_torso_1" type="BoneAttachment" parent="skeleton" index="8"]
transform = Transform( 1, 0, 0, 0, 0.0981498, -0.994991, 0, 0.99517, 0.0981703, 0, 0.383938, 0.01275 )
transform = Transform( 1, 0, 0, 0, 0.0981497, -0.994991, 0, 0.99517, 0.0981702, 0, 0.383938, 0.0127501 )
bone_name = "spine01"
[node name="area" type="Area" parent="skeleton/limb_torso_1" index="0"]
@ -107,7 +110,7 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 3 )
[node name="limb_torso_2" type="BoneAttachment" parent="skeleton" index="9"]
transform = Transform( 1, 0, 0, 0, -0.00632599, -0.999801, 0, 0.99998, -0.00632417, 0, 0.231632, 0.0117867 )
transform = Transform( 1, 0, 0, 0, -0.00632605, -0.999801, 0, 0.99998, -0.00632426, 0, 0.231632, 0.0117867 )
bone_name = "spine02"
[node name="area" type="Area" parent="skeleton/limb_torso_2" index="0"]
@ -117,7 +120,7 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 4 )
[node name="limb_torso_3" type="BoneAttachment" parent="skeleton" index="10"]
transform = Transform( 1, 0, 0, 0, -0.13324, -0.990902, 0, 0.991081, -0.133261, 0, 0.141423, -0.000345033 )
transform = Transform( 1, 0, 0, 0, -0.13324, -0.990903, 0, 0.991081, -0.133261, 0, 0.141423, -0.000345025 )
bone_name = "spine03"
[node name="area" type="Area" parent="skeleton/limb_torso_3" index="0"]
@ -127,7 +130,7 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 4 )
[node name="limb_torso_4" type="BoneAttachment" parent="skeleton" index="11"]
transform = Transform( 1, 0, 0, 0, -0.32935, -0.944017, 0, 0.944188, -0.329407, 0, 0.0787433, -0.0222167 )
transform = Transform( 1, 0, 0, 0, -0.329351, -0.944018, 0, 0.944188, -0.329407, 0, 0.0787433, -0.0222167 )
bone_name = "spine04"
[node name="area" type="Area" parent="skeleton/limb_torso_4" index="0"]
@ -138,7 +141,7 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 5 )
[node name="limb_torso_5" type="BoneAttachment" parent="skeleton" index="12"]
transform = Transform( 1, 0, 0, 0, 0.534014, -0.845263, 0, 0.845413, 0.534112, 0, 0.0066183, 0.0233583 )
transform = Transform( 1, 0, 0, 0, 0.534014, -0.845263, 0, 0.845413, 0.534112, 0, 0.00661829, 0.0233583 )
bone_name = "spine05"
[node name="area" type="Area" parent="skeleton/limb_torso_5" index="0"]
@ -149,7 +152,7 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 5 )
[node name="limb_upper_arm_left" type="BoneAttachment" parent="skeleton" index="13"]
transform = Transform( -0.745066, -0.0134922, -0.666855, -0.666773, 0.03218, 0.744323, 0.0114208, 0.999391, -0.0329804, 0.208593, 0.385909, 0.019574 )
transform = Transform( -0.916258, -0.0495514, 0.39748, -0.146441, 0.964933, -0.217242, -0.372833, -0.257312, -0.891465, 0.124098, 0.457149, 0.0935225 )
bone_name = "upperarm02.L"
[node name="area" type="Area" parent="skeleton/limb_upper_arm_left" index="0"]
@ -160,21 +163,21 @@ transform = Transform( -1.62921e-07, 0, 0.999999, 0, 0.999999, 0, -0.999999, 0,
shape = SubResource( 6 )
[node name="attachment_hand_R" type="BoneAttachment" parent="skeleton" index="14"]
transform = Transform( 0.587628, 0.647439, 0.485299, 0.412693, -0.755596, 0.508329, 0.695927, -0.0984435, -0.711334, -0.440104, 0.124054, 0.17144 )
transform = Transform( 0.139119, 0.942787, 0.301158, 0.989192, -0.11686, -0.0900727, -0.0499327, 0.310136, -0.949558, -0.0396669, 0.548563, 0.446445 )
bone_name = "metacarpal3.R"
[node name="handle" type="Spatial" parent="skeleton/attachment_hand_R" index="0"]
transform = Transform( -0.0511686, 0.991695, -0.116549, 0.320607, -0.0942135, -0.942455, -0.946104, -0.0855632, -0.313081, 0.0258782, 0.0285175, -0.0395434 )
[node name="attachment_hand_L" type="BoneAttachment" parent="skeleton" index="15"]
transform = Transform( 0.587628, -0.647439, -0.485299, -0.412693, -0.755596, 0.508329, -0.695927, -0.0984435, -0.711334, 0.440104, 0.124054, 0.17144 )
transform = Transform( -0.850823, -0.524239, -0.0322684, -0.515658, 0.822074, 0.240839, -0.0998667, 0.221566, -0.970097, -0.0341468, 0.523948, 0.450898 )
bone_name = "metacarpal3.L"
[node name="handle" type="Spatial" parent="skeleton/attachment_hand_L" index="0"]
transform = Transform( 0.248711, -0.966789, 0.0577959, -0.32067, -0.138623, -0.937039, 0.914105, 0.214413, -0.344196, -0.0963456, 0.0583696, -0.12191 )
[node name="attachment_hips_R" type="BoneAttachment" parent="skeleton" index="16"]
transform = Transform( -0.0959694, 0.091845, 0.991138, 0.312981, -0.942256, 0.11762, 0.944878, 0.321558, 0.0616928, 0, 0.0066183, 0.0233583 )
transform = Transform( -0.0959694, 0.091845, 0.991138, 0.312981, -0.942256, 0.11762, 0.944878, 0.321558, 0.0616928, -1.00505e-09, 0.0066183, 0.0233583 )
bone_name = "pelvis.R"
[node name="handle" type="Spatial" parent="skeleton/attachment_hips_R" index="0"]

View file

@ -0,0 +1,18 @@
[gd_scene load_steps=4 format=2]
[ext_resource path="res://assets/decors/buildings/dispensaire/gerenaber.tscn" type="PackedScene" id=1]
[ext_resource path="res://assets/creatures/arche/player_arche.tscn" type="PackedScene" id=2]
[ext_resource path="res://assets/decors/buildings/hall_01/hall_01.tscn" type="PackedScene" id=3]
[node name="spatial" type="Spatial"]
[node name="spatial" type="Spatial" parent="."]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -5.76592, -5.87158 )
[node name="player" parent="spatial" instance=ExtResource( 2 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 3.61281, 5.76592, 5.87158 )
[node name="gerenaber" parent="." instance=ExtResource( 1 )]
[node name="hall_01b" parent="." instance=ExtResource( 3 )]
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -14.839, 0.001, 0 )

View file

@ -24,8 +24,8 @@ noise = SubResource( 1 )
[sub_resource type="ShaderMaterial" id=3]
resource_local_to_scene = true
shader = ExtResource( 5 )
shader_param/iTime = 4.27346
shader_param/iFrame = 402
shader_param/iTime = 85.3788
shader_param/iFrame = 4332
shader_param/COVERAGE = 0.5
shader_param/THICKNESS = 25.0
shader_param/ABSORPTION = 1.031

View file

@ -7,3 +7,7 @@ export( Vector2 ) var size = Vector2( 1.0, 1.0 ) setget set_size
func set_size( p_value ):
size = p_value
self.mesh.size = p_value
func _on_attack_delay_timeout():
self.can_attack = true

View file

@ -33,7 +33,6 @@ func update_model():
self.add_child( item_node )
func set_focus( p_focus = true ):
var _item
if p_focus:
for _item in self.get_children():
if _item.has_node( "focus" ):

View file

@ -167,7 +167,8 @@ func _on_creatures_menu_ui_cancel_pressed():
func _on_creatures_menu_ui_select_pressed( filename ):
self.creature_selected_filename = filename
Globals.goto_scene( "res://scenes/game/game.tscn" )
#Globals.goto_scene( "res://scenes/game/game.tscn" )
Globals.goto_scene( "res://scenes/game/dispensaire/dispensaire.tscn" )
func _on_creature_editor_ui_valid_pressed():
Globals.goto_scene( "res://scenes/interfaces/creatures_menu/creatures_menu_ui.tscn" )

View file

@ -24,7 +24,6 @@ static func get_input_direction() -> Vector3:
)
func _input( event ):
# Run.
if event.is_action_pressed( "move_toggle_run" ):
$character.is_running = not $character.is_running
@ -63,7 +62,6 @@ func _input( event ):
if event.is_action_pressed( "focus_next" ):
self.focus_next()
# if not self.get_tree().get_root().get_node( "main/scene/game" ).is_on_ui:
# if event.is_action_pressed( "action_ready_weapon" ):
# $character.is_readying_weapon = true
@ -76,7 +74,6 @@ func _input( event ):
func _process( delta ):
$character.direction = self.get_input_direction()
# Rotation.
@ -117,7 +114,6 @@ func _process( delta ):
#var old_collider = null
func _physics_process(delta):
var space_state = get_world().direct_space_state
# Camera.
self.camera_position = Vector3( 0.0, 2 - 0.1*self.zoom_level, -2 + 0.1*self.zoom_level )
@ -202,13 +198,10 @@ func _on_character_equip(p_slot, p_item):
else:
min_range = min( min_range, weapon.get_data( "range" ) )
$character.get_main_weapon_node().get_node( "bullet_exit/target_spring_arm" ).spring_length = min_range
func _on_character_unequip(p_slot):
emit_signal( "unequip", p_slot )
func _on_crosshair_area_body_entered(body):
if not body == $character:
if body is preload( "res://scenes/characters/character.gd" ):