Réparation de bug, paufinnage du rayon tracteur et insert de l'outil dans l'histoire
This commit is contained in:
BIN
common/audio_manager/assets/sfx/tractor_beam/drop.wav
Normal file
BIN
common/audio_manager/assets/sfx/tractor_beam/drop.wav
Normal file
Binary file not shown.
24
common/audio_manager/assets/sfx/tractor_beam/drop.wav.import
Normal file
24
common/audio_manager/assets/sfx/tractor_beam/drop.wav.import
Normal file
@@ -0,0 +1,24 @@
|
||||
[remap]
|
||||
|
||||
importer="wav"
|
||||
type="AudioStreamWAV"
|
||||
uid="uid://cam4vv1am40dy"
|
||||
path="res://.godot/imported/drop.wav-b76e8a2f6f5f0c41737e74496f01ceaa.sample"
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://common/audio_manager/assets/sfx/tractor_beam/drop.wav"
|
||||
dest_files=["res://.godot/imported/drop.wav-b76e8a2f6f5f0c41737e74496f01ceaa.sample"]
|
||||
|
||||
[params]
|
||||
|
||||
force/8_bit=false
|
||||
force/mono=false
|
||||
force/max_rate=false
|
||||
force/max_rate_hz=44100
|
||||
edit/trim=false
|
||||
edit/normalize=false
|
||||
edit/loop_mode=0
|
||||
edit/loop_begin=0
|
||||
edit/loop_end=-1
|
||||
compress/mode=2
|
||||
BIN
common/audio_manager/assets/sfx/tractor_beam/take.wav
Normal file
BIN
common/audio_manager/assets/sfx/tractor_beam/take.wav
Normal file
Binary file not shown.
24
common/audio_manager/assets/sfx/tractor_beam/take.wav.import
Normal file
24
common/audio_manager/assets/sfx/tractor_beam/take.wav.import
Normal file
@@ -0,0 +1,24 @@
|
||||
[remap]
|
||||
|
||||
importer="wav"
|
||||
type="AudioStreamWAV"
|
||||
uid="uid://bdrdnli5k27a2"
|
||||
path="res://.godot/imported/take.wav-d597c4daf1adbf3b061372ab36ef9940.sample"
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://common/audio_manager/assets/sfx/tractor_beam/take.wav"
|
||||
dest_files=["res://.godot/imported/take.wav-d597c4daf1adbf3b061372ab36ef9940.sample"]
|
||||
|
||||
[params]
|
||||
|
||||
force/8_bit=false
|
||||
force/mono=false
|
||||
force/max_rate=false
|
||||
force/max_rate_hz=44100
|
||||
edit/trim=false
|
||||
edit/normalize=false
|
||||
edit/loop_mode=0
|
||||
edit/loop_begin=0
|
||||
edit/loop_end=-1
|
||||
compress/mode=2
|
||||
@@ -68,6 +68,8 @@
|
||||
[ext_resource type="AudioStream" uid="uid://53ixfbcd5qwu" path="res://common/audio_manager/assets/sfx/holo/holo_appear.wav" id="63_aedoe"]
|
||||
[ext_resource type="AudioStream" uid="uid://dsijqgnnadgem" path="res://common/audio_manager/assets/sfx/holo/holo_disappear.wav" id="64_ge2sc"]
|
||||
[ext_resource type="AudioStream" uid="uid://dscyqjujj1com" path="res://common/audio_manager/assets/sfx/unlock_tool/unlock_tool.wav" id="64_yr73o"]
|
||||
[ext_resource type="AudioStream" uid="uid://bdrdnli5k27a2" path="res://common/audio_manager/assets/sfx/tractor_beam/take.wav" id="69_5rlid"]
|
||||
[ext_resource type="AudioStream" uid="uid://cam4vv1am40dy" path="res://common/audio_manager/assets/sfx/tractor_beam/drop.wav" id="70_gfbcu"]
|
||||
|
||||
[sub_resource type="AudioStreamRandomizer" id="AudioStreamRandomizer_6o1yh"]
|
||||
streams_count = 3
|
||||
@@ -384,3 +386,11 @@ volume_db = -11.0
|
||||
[node name="Unlock_tool" type="AudioStreamPlayer" parent="Sfx" unique_id=667077616]
|
||||
stream = ExtResource("64_yr73o")
|
||||
volume_db = -5.0
|
||||
|
||||
[node name="TractorBeamTake" type="AudioStreamPlayer" parent="Sfx" unique_id=1321980229]
|
||||
stream = ExtResource("69_5rlid")
|
||||
volume_db = -5.0
|
||||
|
||||
[node name="TractorBeamDrop" type="AudioStreamPlayer" parent="Sfx" unique_id=2023233451]
|
||||
stream = ExtResource("70_gfbcu")
|
||||
volume_db = -5.0
|
||||
|
||||
@@ -3,6 +3,7 @@ class_name MercuryStoryStep
|
||||
|
||||
|
||||
const MERCURY_DEPARTURE_DIALOG_PATH = "res://dialogs/timelines/1_waking_up/6_mercury_departure.dtl"
|
||||
const VENDING_MACHINE_DIALOG_PATH = "res://dialogs/timelines/1_waking_up/6_vending_machine_presentation.dtl"
|
||||
const VENUS_ARRIVAL_DIALOG_PATH = "res://dialogs/timelines/1_waking_up/7_venus_arrival.dtl"
|
||||
|
||||
func get_respawn_scene() -> Scene:
|
||||
@@ -21,12 +22,11 @@ func get_destination_scene() -> Scene:
|
||||
"002"
|
||||
)
|
||||
|
||||
func get_first_vending_machine_occurence(_level : int) -> int:
|
||||
return 1
|
||||
|
||||
func get_ship_dialog_path(level : int, ship_in_space := true) -> String:
|
||||
if level == 0:
|
||||
return MERCURY_DEPARTURE_DIALOG_PATH
|
||||
elif level == 1:
|
||||
return MERCURY_DEPARTURE_DIALOG_PATH
|
||||
if ship_in_space and is_run_finished(level + 1):
|
||||
return VENUS_ARRIVAL_DIALOG_PATH
|
||||
return ""
|
||||
67
common/icons/tractor-beam.svg
Normal file
67
common/icons/tractor-beam.svg
Normal file
@@ -0,0 +1,67 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
width="24"
|
||||
height="24"
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
stroke="#ffffff"
|
||||
stroke-width="2"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
class="icon icon-tabler icons-tabler-outline icon-tabler-hand-stop"
|
||||
version="1.1"
|
||||
id="svg5"
|
||||
sodipodi:docname="tractor-beam.svg"
|
||||
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
|
||||
xml:space="preserve"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"><defs
|
||||
id="defs5" /><sodipodi:namedview
|
||||
id="namedview5"
|
||||
pagecolor="#505050"
|
||||
bordercolor="#ffffff"
|
||||
borderopacity="1"
|
||||
inkscape:showpageshadow="0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pagecheckerboard="1"
|
||||
inkscape:deskcolor="#505050"
|
||||
inkscape:zoom="18.5"
|
||||
inkscape:cx="12.621622"
|
||||
inkscape:cy="19.72973"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1009"
|
||||
inkscape:window-x="-8"
|
||||
inkscape:window-y="-8"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg5" /><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 23.749739 V 23.9144 H 0 Z"
|
||||
fill="none"
|
||||
id="path1"
|
||||
style="stroke-width:1.99999" /><path
|
||||
d="M 6.8271984,12.845525 V 5.3722753 a 1.4843591,1.4946504 0 0 1 2.968718,0 v 6.4768177"
|
||||
id="path2"
|
||||
style="stroke-width:1.99999" /><path
|
||||
d="M 9.7959164,5.3722753 V 3.3794087 a 1.4843589,1.4946502 0 1 1 2.9687166,0 v 8.4696843"
|
||||
id="path3"
|
||||
style="stroke-width:1.99999" /><path
|
||||
d="m 12.764633,5.3722753 a 1.4843591,1.4946504 0 0 1 2.968718,0 v 6.4768177"
|
||||
id="path4"
|
||||
style="stroke-width:1.99999" /><path
|
||||
d="m 15.733351,7.365142 c 0,-1.9928659 2.968717,-1.9928659 2.968717,0 v 2.975834 m -7.710749,11.47245 C 8.9938986,21.813765 7.1301633,20.802796 6.0315822,19.123055 5.9666761,19.023581 5.9020237,18.923936 5.837626,18.824125 5.5288793,18.346835 4.4452975,16.444642 2.5858908,13.116556 2.1917476,12.411131 2.4268816,11.517964 3.1163016,11.101767 c 0.726623,-0.439011 1.6566878,-0.324001 2.2562253,0.279001 l 1.4546715,1.464757"
|
||||
id="path5"
|
||||
sodipodi:nodetypes="cscccccccc"
|
||||
style="stroke-width:1.99999" /><g
|
||||
style="fill:none;stroke:#ffffff;stroke-width:3.85163;stroke-linecap:round;stroke-linejoin:round"
|
||||
id="g5"
|
||||
transform="matrix(0.51747196,0,0,0.52105962,10.491291,11.386461)"><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 24 V 24 H 0 Z"
|
||||
fill="none"
|
||||
id="path1-9"
|
||||
style="stroke-width:3.85163" /><path
|
||||
d="M 21,12 H 19 C 18.106,12 17.338,11.143 17.239,10 16.943,6.55 16.49,4 14.49,4 c -2,0 -2.5,3.582 -2.5,8 0,4.418 -0.5,8 -2.5,8 -2,0 -2.452,-2.547 -2.749,-6 -0.1,-1.147 -0.867,-2 -1.763,-2 h -2"
|
||||
id="path2-1"
|
||||
style="stroke-width:3.85163" /></g></svg>
|
||||
|
After Width: | Height: | Size: 2.8 KiB |
43
common/icons/tractor-beam.svg.import
Normal file
43
common/icons/tractor-beam.svg.import
Normal file
@@ -0,0 +1,43 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://d2nnlb6u5tvrk"
|
||||
path="res://.godot/imported/tractor-beam.svg-4c2610322ae48f5564558f00d6fd6d1a.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://common/icons/tractor-beam.svg"
|
||||
dest_files=["res://.godot/imported/tractor-beam.svg-4c2610322ae48f5564558f00d6fd6d1a.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
svg/scale=2.0
|
||||
editor/scale_with_editor_scale=false
|
||||
editor/convert_colors_with_editor_theme=false
|
||||
@@ -3,7 +3,7 @@ audio "res://common/audio_manager/assets/sfx/dialogs/sfx/incoming_transmission.w
|
||||
join mysterious_demeter center [animation="Fade In" length="1.0"]
|
||||
mysterious_demeter: Hi again ![pause=0.5] You did well up there ! #id:74
|
||||
mysterious_demeter: Perhaps I should introduce myself now. #id:75
|
||||
leave [animation="Fade Out"] mysterious_demeter
|
||||
leave mysterious_demeter [animation="Fade Out"]
|
||||
join demeter center [animation="Fade In" length="1.0"]
|
||||
demeter: I am.[pause=0.3].[pause=0.3].[pause=0.5] was,[pause=0.2] the Deputy Manager of Engineering and Talion Energy Research on this planet,[pause=0.5] but my creators and colleagues quickly called me [color=#FFA617]Demeter[/color]. #id:76
|
||||
demeter: I am installed at the [color=#FFA617]Borea[/color] base,[pause=0.2] in the third server room of the east wing,[pause=0.2] from which I oversee.[pause=0.3].[pause=0.3].[pause=0.5] oversaw,[pause=0.3] all the important operations on this planet. #id:77
|
||||
|
||||
@@ -19,16 +19,8 @@ demeter: [b]I also did some cleaning in your seeds[/b], they have gone bad durin
|
||||
- No problem, I'll found better ones. #id:112
|
||||
- Oh no ! But I've been away just a moment ! #id:113
|
||||
demeter: Uhm, I actually repaired the ship over two full months; I didn't wake you up just after the save, I thought that you wouldn't want to wait that long! #id:114
|
||||
demeter: Luckily, I've found something that might help you. I've cataloged ancient human ruins all over the planet, and some of them contain "vending machines," machines for exchanging items for money. #id:ce
|
||||
- Thanks ! #id:101
|
||||
- Vending machines? #id:cf
|
||||
demeter: Yes, that's where they used to get the energy they needed, for a completely unreasonable price. #id:d0
|
||||
demeter: Before, real people were in charge of transactions, but for some reason, humans spent all of recent history figuring out how to encounter as few humans as possible. Maybe they couldn't stand each other anymore... #id:d1
|
||||
- Money? #id:d2
|
||||
demeter: Yes, each human had a sum of an imaginary unit they called money. They based their entire social hierarchy on this unit. #id:d3
|
||||
demeter: In any case, I've updated their system. They'll probably need some energy to function, but they might bring you some interesting items. #id:d4
|
||||
demeter: As usual, you can use your detector to find the entrance to these ruins. #id:d5
|
||||
demeter: [b]These artifacts will be placed on a shelf in your ship[/b], but remember that if you ran out of energy and I have to teleport the ship, you'll lose them. #id:d6
|
||||
demeter: I've updated you in the meantime, and you'll discover a new tool I just added, a tractable beam! #id:115
|
||||
demeter: If you were in trouble for sorting your seeds, it might help you. #id:116
|
||||
demeter: Good luck with the [color=#FFA617]Venus Relay Base[/color]; it's a little further than the last one. #id:d7
|
||||
audio "res://common/audio_manager/assets/sfx/dialogs/sfx/closing_transmission.wav"
|
||||
[wait time="2.0"]
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
audio "res://common/audio_manager/assets/sfx/dialogs/sfx/incoming_transmission.wav"
|
||||
join demeter center [animation="Bounce In" length="1.0"]
|
||||
demeter: I've found something that might help you. I've cataloged ancient human ruins all over the planet, and some of them contain "vending machines," machines for exchanging items for money. #id:117
|
||||
- Thanks ! #id:101
|
||||
- Vending machines? #id:cf
|
||||
demeter: Yes, that's where they used to get the energy they needed, for a completely unreasonable price. #id:d0
|
||||
demeter: Before, real people were in charge of transactions, but for some reason, humans spent all of recent history figuring out how to encounter as few humans as possible. Maybe they couldn't stand each other anymore... #id:d1
|
||||
- Money? #id:d2
|
||||
demeter: Yes, each human had a sum of an imaginary unit they called money. They based their entire social hierarchy on this unit. #id:d3
|
||||
demeter: In any case, I've updated their system. They'll probably need some energy to function, but they might bring you some interesting items. #id:d4
|
||||
demeter: As usual, you can use your detector to find the entrance to these ruins. #id:d5
|
||||
demeter: [b]These artifacts will be placed on a shelf in your ship[/b], but remember that if you ran out of energy and I have to teleport the ship, you'll lose them. #id:d6
|
||||
demeter: It could really help you, so go fetch them. #id:118
|
||||
audio "res://common/audio_manager/assets/sfx/dialogs/sfx/closing_transmission.wav"
|
||||
[wait time="2.0"]
|
||||
[end_timeline]
|
||||
@@ -0,0 +1 @@
|
||||
uid://be7qtv1piktek
|
||||
@@ -33,6 +33,12 @@ func get_icon() -> Texture2D:
|
||||
func get_pointer() -> Texture2D:
|
||||
return null
|
||||
|
||||
func get_clicked_pointer() -> Texture2D:
|
||||
return null
|
||||
|
||||
func is_pointer_center() -> bool:
|
||||
return false
|
||||
|
||||
func get_energy_used() -> int:
|
||||
return energy_usage
|
||||
|
||||
@@ -48,11 +54,11 @@ func is_action_need_press_time() -> bool:
|
||||
func get_action_press_time() -> float:
|
||||
return DEFAULT_PRESS_TIME
|
||||
|
||||
func get_action_is_hold() -> bool:
|
||||
func deactivate_interactable() -> bool:
|
||||
return false
|
||||
|
||||
func get_usage_object_affected(_i : Area2D) -> bool:
|
||||
return false
|
||||
func get_usage_objects_affected(_areas : Array[Area2D], _zone : Player.ActionZone) -> Array[Area2D]:
|
||||
return []
|
||||
|
||||
func is_one_time_use():
|
||||
return false
|
||||
|
||||
@@ -27,26 +27,32 @@ func get_energy_used() -> int:
|
||||
func get_usage_zone_radius() -> int:
|
||||
return 10
|
||||
|
||||
func get_usage_object_affected(i : Area2D) -> bool:
|
||||
return i is Plant and Pointer.inspected == i
|
||||
func get_usage_objects_affected(areas : Array[Area2D], zone : Player.ActionZone) -> Array[Area2D]:
|
||||
areas = areas.filter(
|
||||
func (a): return a is Plant and a.position.distance_to(zone.area.position) < 5
|
||||
)
|
||||
if len(areas) == 0:
|
||||
return []
|
||||
else:
|
||||
return [areas[0]]
|
||||
|
||||
func use_text() -> String:
|
||||
return tr("HARVEST")
|
||||
|
||||
func can_use(_player : Player, zone : Player.ActionZone) -> bool:
|
||||
var areas = zone.get_affected_areas()
|
||||
for area in areas :
|
||||
if area is Plant and Pointer.inspected == area:
|
||||
return true
|
||||
print(zone)
|
||||
var areas = get_usage_objects_affected(zone.get_affected_areas(), zone)
|
||||
if len(areas) > 0:
|
||||
return true
|
||||
print("nope")
|
||||
return false
|
||||
|
||||
func use(player : Player, zone : Player.ActionZone) -> bool:
|
||||
var has_plant = false
|
||||
for area in zone.get_affected_areas():
|
||||
if area and area is Plant and Pointer.inspected == area:
|
||||
harvest(area, player)
|
||||
await player.get_tree().create_timer(USE_INTERVAL).timeout
|
||||
has_plant = true
|
||||
var areas = get_usage_objects_affected(zone.get_affected_areas(), zone)
|
||||
if len(areas) > 0:
|
||||
harvest(areas[0], player)
|
||||
has_plant = true
|
||||
return has_plant
|
||||
|
||||
func harvest(p : Plant, _player: Player):
|
||||
|
||||
@@ -74,8 +74,10 @@ func get_energy_used() -> int:
|
||||
func get_usage_zone_radius() -> int:
|
||||
return 10
|
||||
|
||||
func get_usage_object_affected(i : Area2D) -> bool:
|
||||
return i is PlantSprite
|
||||
func get_usage_objects_affected(areas : Array[Area2D], _zone : Player.ActionZone) -> Array[Area2D]:
|
||||
return areas.filter(
|
||||
func(a): return a is PlantSprite
|
||||
)
|
||||
|
||||
func snap_usage_to_grid():
|
||||
return true
|
||||
|
||||
@@ -17,8 +17,14 @@ func get_icon() -> Texture2D:
|
||||
func get_usage_zone_radius() -> int:
|
||||
return SHOVEL_ZONE_RADIUS
|
||||
|
||||
func get_usage_object_affected(i : Area2D) -> bool:
|
||||
return i is Plant
|
||||
func get_usage_objects_affected(areas : Array[Area2D], zone : Player.ActionZone) -> Array[Area2D]:
|
||||
areas.sort_custom(
|
||||
func (a1,a2): return a1.position.distance_to(zone.area.position) - a2.position.distance_to(zone.area.position)
|
||||
)
|
||||
if len(areas) == 0:
|
||||
return []
|
||||
else:
|
||||
return [areas[0]]
|
||||
|
||||
func use_text() -> String:
|
||||
return tr("DIG")
|
||||
|
||||
@@ -10,8 +10,16 @@ func get_description() -> String:
|
||||
return tr("TRACTOR_BEAM_DESC_TEXT")
|
||||
|
||||
func get_icon() -> Texture2D:
|
||||
# return preload("res://common/icons/tractor_beam.svg")
|
||||
return preload("res://common/icons/alert-triangle.svg")
|
||||
return preload("res://common/icons/tractor-beam.svg")
|
||||
|
||||
func get_pointer() -> Texture2D:
|
||||
return preload("res://gui/pointer/assets/cursors/pointer-hand.svg")
|
||||
|
||||
func get_clicked_pointer() -> Texture2D:
|
||||
return preload("res://gui/pointer/assets/cursors/pointer-grab.svg")
|
||||
|
||||
func is_pointer_center() -> bool:
|
||||
return true
|
||||
|
||||
func get_item_type() -> ItemType:
|
||||
return Item.ItemType.TOOL_ITEM
|
||||
@@ -20,16 +28,16 @@ func get_energy_used() -> int:
|
||||
return 0
|
||||
|
||||
func get_usage_zone_radius() -> int:
|
||||
return 1
|
||||
return 0
|
||||
|
||||
func is_usage_need_proximity() -> bool:
|
||||
return false
|
||||
|
||||
func get_action_is_hold() -> bool:
|
||||
func deactivate_interactable() -> bool:
|
||||
return true
|
||||
|
||||
func use_text() -> String:
|
||||
return tr("MOVE")
|
||||
return tr("")
|
||||
|
||||
func can_use(_player: Player, _zone: Player.ActionZone) -> bool:
|
||||
return Pointer.inspected != null
|
||||
@@ -38,12 +46,14 @@ func use(_player: Player, _zone: Player.ActionZone) -> bool:
|
||||
if Pointer.dragging_inspected:
|
||||
Pointer.stop_dragging()
|
||||
if !Pointer.dragging_inspected:
|
||||
AudioManager.play_sfx("TractorBeamDrop")
|
||||
return true
|
||||
else:
|
||||
return false
|
||||
else:
|
||||
Pointer.start_dragging()
|
||||
if Pointer.dragging_inspected:
|
||||
AudioManager.play_sfx("TractorBeamTake")
|
||||
return true
|
||||
else:
|
||||
return false
|
||||
|
||||
@@ -32,6 +32,7 @@ var instruction : Instruction = null :
|
||||
|
||||
var just_dropped_item_objects : Array = []
|
||||
var last_just_dropped_item_objects_updated := 0.
|
||||
var last_instruction_done := 0.
|
||||
|
||||
var elapsed_time := 0.
|
||||
|
||||
@@ -89,6 +90,7 @@ func _process(delta):
|
||||
and instruction and instruction.can_be_done(self)
|
||||
):
|
||||
instruction.do(self)
|
||||
last_instruction_done = elapsed_time
|
||||
instruction = null
|
||||
|
||||
|
||||
@@ -97,7 +99,7 @@ func _process(delta):
|
||||
instruction = null
|
||||
input_direction = calculate_direction_instruction_direction()
|
||||
|
||||
if instruction == null and action_zone:
|
||||
if instruction == null and action_zone and elapsed_time > last_instruction_done + 0.1:
|
||||
action_zone.destroy()
|
||||
action_zone = null
|
||||
|
||||
@@ -371,7 +373,7 @@ class Instruction:
|
||||
|
||||
player.get_tree().create_tween().tween_property(indicator, "modulate:a", 0.8, 0.2)
|
||||
|
||||
func abort(player : Player):
|
||||
func abort(_player : Player):
|
||||
indicator.queue_free()
|
||||
|
||||
class MoveInstruction extends Instruction:
|
||||
@@ -467,10 +469,11 @@ class ActionZone:
|
||||
var detected_areas = get_affected_areas()
|
||||
clear_preview_on_affected_area()
|
||||
var new_affected_areas : Array[Area2D] = []
|
||||
for a in detected_areas:
|
||||
if a is Area2D and item.get_usage_object_affected(a) and a.has_method("affect_preview"):
|
||||
a.affect_preview(true)
|
||||
new_affected_areas.append(a)
|
||||
if item:
|
||||
for a in item.get_usage_objects_affected(detected_areas, self):
|
||||
if a.has_method("affect_preview"):
|
||||
a.affect_preview(true)
|
||||
new_affected_areas.append(a)
|
||||
affected_areas = new_affected_areas
|
||||
|
||||
func get_affected_areas() -> Array[Area2D]:
|
||||
|
||||
68
gui/pointer/assets/cursors/pointer-grab.svg
Normal file
68
gui/pointer/assets/cursors/pointer-grab.svg
Normal file
@@ -0,0 +1,68 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
width="31.51301"
|
||||
height="31.618402"
|
||||
viewBox="0 0 31.51301 31.618402"
|
||||
fill="#ffffff"
|
||||
class="icon icon-tabler icons-tabler-filled icon-tabler-pointer"
|
||||
version="1.1"
|
||||
id="svg2"
|
||||
sodipodi:docname="pointer-grab.svg"
|
||||
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
|
||||
xml:space="preserve"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"><defs
|
||||
id="defs2" /><sodipodi:namedview
|
||||
id="namedview2"
|
||||
pagecolor="#505050"
|
||||
bordercolor="#ffffff"
|
||||
borderopacity="1"
|
||||
inkscape:showpageshadow="0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pagecheckerboard="1"
|
||||
inkscape:deskcolor="#505050"
|
||||
inkscape:zoom="11.313709"
|
||||
inkscape:cx="16.83798"
|
||||
inkscape:cy="12.993087"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1009"
|
||||
inkscape:window-x="-8"
|
||||
inkscape:window-y="-8"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg2" /><g
|
||||
id="g15"
|
||||
transform="matrix(0.9885228,0,0,0.99150555,6.1801905,2.5439475)"
|
||||
style="stroke-width:1.01009"><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 24 V 24 H 0 Z"
|
||||
fill="none"
|
||||
id="path1"
|
||||
style="stroke-width:1.01009" /><g
|
||||
style="fill:none;stroke:#000000;stroke-width:1.52089;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:0.286275"
|
||||
id="g14"
|
||||
transform="matrix(1.3282871,0,0,1.3282871,-6.2519453,1.4283269)"><path
|
||||
id="path11"
|
||||
style="color:#000000;fill:#000000;fill-opacity:0.286275;stroke:none;stroke-width:1.52089;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;-inkscape-stroke:none"
|
||||
d="m 12.5,4.0008929 c -0.597221,0 -1.207882,0.1936814 -1.695312,0.6269531 C 10.639844,4.774373 10.495228,4.9497692 10.375,5.1473773 10.090773,5.0480128 9.7940211,5.0008929 9.5000001,5.0008929 8.9027792,5.0008929 8.2921185,5.1945743 7.8046876,5.627846 7.3172567,6.0611178 7.0000001,6.7508945 7.0000001,7.5008929 V 8.6141742 C 6.0755349,7.8752923 4.7685924,7.7740909 3.7363282,8.393471 2.5845019,9.0840318 2.1832949,10.592162 2.841797,11.762612 c 1.8805606,3.342773 2.9291437,5.182658 3.3203125,5.783203 a 1.0001,1.0001 0 0 0 0,0.002 l 0.1972656,0.300781 a 1.0001,1.0001 0 0 0 0.00195,0.002 c 1.2404681,1.883628 3.3285347,2.986304 5.5703129,3.080078 A 1.0001,1.0001 0 0 0 12,21.000893 h 0.207031 0.002 H 14 c 3.854141,0 7,-3.145859 7,-7 V 9.5008929 C 21,8.7508945 20.682744,8.0611178 20.195313,7.627846 19.707882,7.1945743 19.097222,7.0008929 18.5,7.0008929 c -0.179726,0 -0.360627,0.020309 -0.539062,0.056641 C 17.863969,6.4834828 17.585038,5.9742681 17.195313,5.627846 16.707882,5.1945743 16.097222,5.0008929 15.5,5.0008929 c -0.294021,0 -0.590773,0.04712 -0.875,0.1464844 C 14.504772,4.9497692 14.360155,4.774373 14.195313,4.627846 13.707881,4.1945743 13.097222,4.0008929 12.5,4.0008929 Z m 0,2 c 0.152778,0 0.292119,0.05632 0.367188,0.1230469 C 12.942256,6.1906668 13,6.2508937 13,6.5008929 v 1 2.5000001 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 V 7.5008929 C 15,7.2508937 15.05774,7.1906668 15.132813,7.1239398 15.207883,7.0572128 15.347222,7.0008929 15.5,7.0008929 c 0.152778,0 0.292119,0.05632 0.367188,0.1230469 C 15.942256,7.1906668 16,7.2508937 16,7.5008929 v 2.5000001 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 V 9.5008929 C 18,9.2508937 18.05775,9.1906668 18.132813,9.1239398 18.207883,9.0572128 18.347222,9.0008929 18.5,9.0008929 c 0.152778,0 0.29212,0.05632 0.367188,0.1230469 C 18.942257,9.1906668 19,9.2508937 19,9.5008929 v 4.5000001 c 0,2.773263 -2.226737,5 -5,5 h -1.792969 c -1.683258,2.84e-4 -3.2499888,-0.844203 -4.1757809,-2.25 L 7.8378907,16.455971 v -0.002 C 7.60465,16.095864 6.4628829,14.118491 4.5859376,10.782143 4.4478483,10.536697 4.5221315,10.253127 4.763672,10.108315 5.1090604,9.9010744 5.5392385,9.9545203 5.8242188,10.239174 l 1.46875,1.46875 a 1,1 0 0 0 0.2851563,0.191406 1,1 0 0 0 0.083984,0.0332 1,1 0 0 0 0.3378906,0.06836 1,1 0 0 0 0.3378906,-0.06836 1,1 0 0 0 0.083984,-0.0332 1,1 0 0 0 0.2851562,-0.191406 1,1 0 0 0 0.1464844,-0.191406 1,1 0 0 0 0.015625,-0.02539 1,1 0 0 0 0.085937,-0.205078 1,1 0 0 0 0.015625,-0.05078 1,1 0 0 0 0.027344,-0.21875 1,1 0 0 0 0.00195,-0.01563 V 7.5008929 c 0,-0.2499992 0.057745,-0.3102261 0.1328125,-0.3769531 0.075068,-0.066727 0.21441,-0.1230469 0.3671875,-0.1230469 0.1527775,0 0.2921196,0.05632 0.3671875,0.1230469 C 9.9422555,7.1906668 10,7.2508937 10,7.5008929 v 2 0.5000001 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 v -0.5000001 -2 -1 C 12,6.2508937 12.057744,6.1906668 12.132813,6.1239398 12.207881,6.0572127 12.347222,6.0008929 12.5,6.0008929 Z" /></g><g
|
||||
style="fill:none;stroke:#ffffff;stroke-width:1.52089;stroke-linecap:round;stroke-linejoin:round"
|
||||
id="g10"
|
||||
transform="matrix(1.3282871,0,0,1.3282871,-6.2519453,-2.5657421)"><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 24 V 24 H 0 Z"
|
||||
fill="none"
|
||||
id="path1-4"
|
||||
style="stroke-width:1.52089" /><path
|
||||
d="M 8,11 V 7.5 a 1.5,1.5 0 0 1 3,0 V 10"
|
||||
id="path2"
|
||||
style="stroke-width:1.52089" /><path
|
||||
d="m 11,9.5 v -3 a 1.5,1.5 0 0 1 3,0 V 10"
|
||||
id="path3-2"
|
||||
style="stroke-width:1.52089" /><path
|
||||
d="m 14,7.5 a 1.5,1.5 0 0 1 3,0 V 10"
|
||||
id="path4"
|
||||
style="stroke-width:1.52089" /><path
|
||||
d="m 17,9.5 a 1.5,1.5 0 0 1 3,0 V 14 a 6,6 0 0 1 -6,6 h -2 0.208 A 6,6 0 0 1 7.196,17.3 L 7,17 C 6.688,16.521 5.593,14.612 3.714,11.272 A 1.5,1.5 0 0 1 4.25,9.25 1.867,1.867 0 0 1 6.53,9.53 L 8,11"
|
||||
id="path5-5"
|
||||
style="stroke-width:1.52089" /></g></g></svg>
|
||||
|
After Width: | Height: | Size: 5.6 KiB |
43
gui/pointer/assets/cursors/pointer-grab.svg.import
Normal file
43
gui/pointer/assets/cursors/pointer-grab.svg.import
Normal file
@@ -0,0 +1,43 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://cxgeop0b0avku"
|
||||
path="res://.godot/imported/pointer-grab.svg-34d4526b795f58b917fc46fb088c5706.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://gui/pointer/assets/cursors/pointer-grab.svg"
|
||||
dest_files=["res://.godot/imported/pointer-grab.svg-34d4526b795f58b917fc46fb088c5706.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
svg/scale=1.0
|
||||
editor/scale_with_editor_scale=false
|
||||
editor/convert_colors_with_editor_theme=false
|
||||
68
gui/pointer/assets/cursors/pointer-hand.svg
Normal file
68
gui/pointer/assets/cursors/pointer-hand.svg
Normal file
@@ -0,0 +1,68 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg
|
||||
width="31.51301"
|
||||
height="31.618402"
|
||||
viewBox="0 0 31.51301 31.618402"
|
||||
fill="#ffffff"
|
||||
class="icon icon-tabler icons-tabler-filled icon-tabler-pointer"
|
||||
version="1.1"
|
||||
id="svg2"
|
||||
sodipodi:docname="pointer-hand.svg"
|
||||
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
|
||||
xml:space="preserve"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"><defs
|
||||
id="defs2" /><sodipodi:namedview
|
||||
id="namedview2"
|
||||
pagecolor="#505050"
|
||||
bordercolor="#ffffff"
|
||||
borderopacity="1"
|
||||
inkscape:showpageshadow="0"
|
||||
inkscape:pageopacity="0"
|
||||
inkscape:pagecheckerboard="1"
|
||||
inkscape:deskcolor="#505050"
|
||||
inkscape:zoom="16"
|
||||
inkscape:cx="15.09375"
|
||||
inkscape:cy="14.3125"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1009"
|
||||
inkscape:window-x="-8"
|
||||
inkscape:window-y="-8"
|
||||
inkscape:window-maximized="1"
|
||||
inkscape:current-layer="svg2" /><g
|
||||
id="g2"
|
||||
transform="matrix(1.1976441,0,0,1.1976441,2.7695521,1.2281839)"
|
||||
style="stroke-width:0.834973"><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 24 V 24 H 0 Z"
|
||||
fill="none"
|
||||
id="path1"
|
||||
style="stroke-width:0.834973" /><g
|
||||
style="fill:none;stroke:#000000;stroke-width:1.66995;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:0.286275"
|
||||
id="g9"
|
||||
transform="translate(-2.3125001,2.3749876)"><path
|
||||
id="path6"
|
||||
style="color:#000000;fill:#000000;fill-opacity:0.286275;stroke:none;stroke-width:1.66995;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;-inkscape-stroke:none"
|
||||
d="m 12.5,1.0000124 c -0.597221,0 -1.207882,0.1936814 -1.695312,0.6269531 C 10.415301,1.9730861 10.136266,2.4832127 10.039063,3.056653 9.8606276,3.020321 9.6797259,3.000012 9.5000001,3.000012 8.9027792,3.000012 8.2921185,3.1936934 7.8046876,3.6269651 7.3172567,4.0602373 7.0000001,4.750014 7.0000001,5.5000124 V 10.615247 C 6.0755194,9.8761636 4.7686953,9.7731488 3.7363282,10.392591 c -1.1518263,0.690561 -1.5530333,2.19869 -0.8945312,3.36914 1.8805606,3.342774 2.9291437,5.182659 3.3203125,5.783203 0.066009,0.101604 0.1307351,0.203425 0.1972656,0.304688 a 1.0001,1.0001 0 0 0 0.00195,0 C 7.6017963,21.73325 9.6898629,22.835926 11.931641,22.9297 A 1.0001,1.0001 0 0 0 12,23.000012 h 0.207031 0.002 H 14 c 3.854141,0 7,-3.145858 7,-7 V 7.5000124 C 21,6.750014 20.682744,6.0602373 20.195313,5.6269655 19.707882,5.1936938 19.097222,5.0000124 18.5,5.0000124 c -0.179726,0 -0.360627,0.020309 -0.539062,0.056641 C 17.863734,4.4832127 17.584699,3.9730861 17.195313,3.6269655 16.707882,3.1936938 16.097222,3.0000124 15.5,3.0000124 c -0.179726,0 -0.360627,0.020309 -0.539062,0.056641 C 14.863734,2.4832127 14.584698,1.9730861 14.195313,1.6269655 13.707881,1.1936938 13.097222,1.0000124 12.5,1.0000124 Z m 0,2 c 0.152778,0 0.292119,0.05632 0.367188,0.1230469 C 12.942256,3.1897863 13,3.2500132 13,3.5000124 v 8.4999996 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 V 5.5000124 C 15,5.2500132 15.05774,5.1897863 15.132813,5.1230593 15.207883,5.0563323 15.347222,5.0000124 15.5,5.0000124 c 0.152778,0 0.292119,0.05632 0.367188,0.1230469 C 15.942256,5.1897863 16,5.2500132 16,5.5000124 v 2 4.4999996 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 V 7.5000124 C 18,7.2500132 18.05775,7.1897863 18.132813,7.1230593 18.207883,7.0563323 18.347222,7.0000124 18.5,7.0000124 c 0.152778,0 0.29212,0.05632 0.367188,0.1230469 C 18.942257,7.1897863 19,7.2500132 19,7.5000124 v 8.4999996 c 0,2.773264 -2.226737,5 -5,5 h -1.792969 c -1.683258,2.84e-4 -3.2499888,-0.844202 -4.1757809,-2.25 C 7.9666006,18.651612 7.9020338,18.553821 7.8378907,18.455091 7.6050608,18.097637 6.4633694,16.118475 4.5859376,12.781262 4.4478483,12.535817 4.5221315,12.252246 4.763672,12.107434 5.1090604,11.900193 5.5392385,11.95364 5.8242188,12.238294 l 1.46875,1.46875 a 1,1 0 0 0 0.2871094,0.191406 1,1 0 0 0 0.078125,0.0332 1,1 0 0 0 0.3417969,0.06836 1,1 0 0 0 0.3417969,-0.06836 1,1 0 0 0 0.078125,-0.0332 1,1 0 0 0 0.2871093,-0.191406 1,1 0 0 0 0.1484375,-0.19336 1,1 0 0 0 0.013672,-0.02148 1,1 0 0 0 0.085937,-0.205078 1,1 0 0 0 0.015625,-0.05078 1,1 0 0 0 0.027344,-0.220704 1,1 0 0 0 0.00195,-0.01563 V 5.5000124 c 0,-0.2499992 0.057745,-0.3102261 0.1328125,-0.3769531 0.075068,-0.066727 0.21441,-0.1230469 0.3671875,-0.1230469 0.1527775,0 0.2921196,0.05632 0.3671875,0.1230469 C 9.9422555,5.1897863 10,5.2500132 10,5.5000124 v 6.4999996 a 1,1 0 0 0 1,1 1,1 0 0 0 1,-1 v -6.4999996 -2 C 12,3.2500132 12.057744,3.1897863 12.132813,3.1230593 12.207881,3.0563322 12.347222,3.0000124 12.5,3.0000124 Z" /></g><g
|
||||
style="fill:none;stroke:#ffffff;stroke-width:1.66995;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:1"
|
||||
id="g1"
|
||||
transform="translate(-2.3125001,-0.8750124)"><path
|
||||
stroke="none"
|
||||
d="M 0,0 H 24 V 24 H 0 Z"
|
||||
fill="none"
|
||||
id="path1-6"
|
||||
style="stroke-width:1.66995" /><path
|
||||
d="M 8,13 V 5.5 a 1.5,1.5 0 0 1 3,0 V 12"
|
||||
id="path2-5"
|
||||
style="stroke-width:1.66995" /><path
|
||||
d="m 11,5.5 v -2 a 1.5,1.5 0 1 1 3,0 V 12"
|
||||
id="path3"
|
||||
style="stroke-width:1.66995" /><path
|
||||
d="m 14,5.5 a 1.5,1.5 0 0 1 3,0 V 12"
|
||||
id="path4-0"
|
||||
style="stroke-width:1.66995" /><path
|
||||
d="m 17,7.5 a 1.5,1.5 0 0 1 3,0 V 16 a 6,6 0 0 1 -6,6 h -2 0.208 A 6,6 0 0 1 7.196,19.3 69.74,69.74 0 0 1 7,19 C 6.688,18.521 5.593,16.612 3.714,13.272 A 1.5,1.5 0 0 1 4.25,11.25 1.867,1.867 0 0 1 6.53,11.53 L 8,13"
|
||||
id="path5"
|
||||
style="stroke-width:1.66995" /></g></g></svg>
|
||||
|
After Width: | Height: | Size: 5.6 KiB |
43
gui/pointer/assets/cursors/pointer-hand.svg.import
Normal file
43
gui/pointer/assets/cursors/pointer-hand.svg.import
Normal file
@@ -0,0 +1,43 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dvhdx85dspbnp"
|
||||
path="res://.godot/imported/pointer-hand.svg-e8ceb5416e6a6ffce06ddb266901a3e8.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://gui/pointer/assets/cursors/pointer-hand.svg"
|
||||
dest_files=["res://.godot/imported/pointer-hand.svg-e8ceb5416e6a6ffce06ddb266901a3e8.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=1
|
||||
svg/scale=1.0
|
||||
editor/scale_with_editor_scale=false
|
||||
editor/convert_colors_with_editor_theme=false
|
||||
@@ -77,13 +77,7 @@ func _process(delta):
|
||||
|
||||
update_inspector(get_current_inspected())
|
||||
|
||||
var cursor := default_cursor
|
||||
if not Pause.pause and player and not action_disabled:
|
||||
if can_interact:
|
||||
cursor = action_cursor
|
||||
elif current_selected_item and current_selected_item.get_pointer():
|
||||
cursor = current_selected_item.get_pointer()
|
||||
Input.set_custom_mouse_cursor(cursor)
|
||||
update_cursor()
|
||||
|
||||
if player:
|
||||
if dragging_inspected:
|
||||
@@ -157,7 +151,7 @@ func process_player_actions(delta: float):
|
||||
if Input.is_action_just_pressed("action"):
|
||||
if inspected is InventoryGuiItemMouseDetector:
|
||||
GameInfo.game_data.player_data.inventory.set_current_item(inspected.index)
|
||||
elif can_use_item and not current_selected_item.is_action_need_press_time() and current_selected_item.get_action_is_hold():
|
||||
elif can_use_item and not current_selected_item.is_action_need_press_time() and current_selected_item.deactivate_interactable():
|
||||
player.try_use_item(current_selected_item, player.get_global_mouse_position())
|
||||
elif can_interact:
|
||||
var interactable = inspected as Interactable
|
||||
@@ -171,7 +165,7 @@ func process_player_actions(delta: float):
|
||||
if (
|
||||
Input.is_action_just_released("action")
|
||||
and can_use_item
|
||||
and current_selected_item.get_action_is_hold()
|
||||
and current_selected_item.deactivate_interactable()
|
||||
):
|
||||
if dragging_inspected:
|
||||
player.try_use_item(current_selected_item, player.get_global_mouse_position())
|
||||
@@ -247,11 +241,7 @@ func update_inspector(current_inspected):
|
||||
%ActionText.text = item.name
|
||||
else:
|
||||
%Action.visible = false
|
||||
elif current_selected_item and current_selected_item.use_text() != "" and current_selected_item.get_action_is_hold():
|
||||
%Action.visible = true
|
||||
%ActionText.text = current_selected_item.use_text()
|
||||
%Action.modulate = DEFAULT_ACTION_COLOR
|
||||
elif can_interact and inspected and inspected is Interactable:
|
||||
elif can_interact and inspected and inspected is Interactable and (not current_selected_item or not current_selected_item.deactivate_interactable()):
|
||||
%Action.visible = true
|
||||
%ActionText.text = inspected.interact_text()
|
||||
%Action.modulate = DEFAULT_ACTION_COLOR if inspected.interaction_cost(player) == 0 else ENERGY_ACTION_COLOR
|
||||
@@ -269,6 +259,22 @@ func update_inspector(current_inspected):
|
||||
else:
|
||||
%Action.visible = false
|
||||
|
||||
func update_cursor():
|
||||
var cursor := default_cursor
|
||||
var hotspot : = Vector2(0.,0.)
|
||||
if not Pause.pause and player and not action_disabled:
|
||||
if current_selected_item and current_selected_item.get_pointer():
|
||||
cursor = current_selected_item.get_pointer()
|
||||
|
||||
if Input.is_action_pressed("action") and current_selected_item.get_clicked_pointer():
|
||||
cursor = current_selected_item.get_clicked_pointer()
|
||||
|
||||
if current_selected_item.is_pointer_center():
|
||||
hotspot = Vector2(cursor.get_width()/2., cursor.get_height()/2.)
|
||||
elif can_interact:
|
||||
cursor = action_cursor
|
||||
Input.set_custom_mouse_cursor(cursor,0,hotspot)
|
||||
|
||||
func stop_inspect(node: Node):
|
||||
if not dragging_inspected:
|
||||
all_inspected.erase(node)
|
||||
|
||||
@@ -45,6 +45,7 @@ directories/dch_directory={
|
||||
"mysterious_demeter": "res://dialogs/characters/mysterious_demeter.dch"
|
||||
}
|
||||
directories/dtl_directory={
|
||||
"6_vending_machine_presentation": "res://dialogs/timelines/1_waking_up/6_vending_machine_presentation.dtl",
|
||||
"8_venus_departure": "res://dialogs/timelines/1_waking_up/8_venus_departure.dtl",
|
||||
"9_borea": "res://dialogs/timelines/1_waking_up/9_borea.dtl",
|
||||
"cave": "res://dialogs/timelines/1_waking_up/4_cave.dtl",
|
||||
@@ -111,7 +112,7 @@ variables={
|
||||
"whoareyou": "false",
|
||||
"whynorth": "false"
|
||||
}
|
||||
translation/id_counter=276
|
||||
translation/id_counter=280
|
||||
translation/locales=[]
|
||||
history/visited_event_history_enabled=true
|
||||
audio/type_sound_bus="Sfx"
|
||||
@@ -247,7 +248,7 @@ zoom_out={
|
||||
[internationalization]
|
||||
|
||||
locale/translation_remaps={}
|
||||
locale/translations=PackedStringArray("res://translation/game/gui.en.translation", "res://translation/game/gui.fr.translation", "res://translation/dialogs/dialogic_character_translations.en.translation", "res://translation/dialogs/dialogic_demeter_ship_failed_translation.en.translation", "res://translation/dialogs/dialogic_demeter_ship_failed_translation.fr.translation", "res://translation/dialogs/dialogic_1_waking_up_translation.en.translation", "res://translation/dialogs/dialogic_1_waking_up_translation.fr.translation", "res://translation/dialogs/dialogic_2_demeter_intro_translation.en.translation", "res://translation/dialogs/dialogic_2_demeter_intro_translation.fr.translation", "res://translation/dialogs/dialogic_3_demeter_ship_presentation_translation.en.translation", "res://translation/dialogs/dialogic_3_demeter_ship_presentation_translation.fr.translation", "res://translation/dialogs/dialogic_4_cave_translation.en.translation", "res://translation/dialogs/dialogic_4_cave_translation.fr.translation", "res://translation/dialogs/dialogic_5_mercury_arrival_translation.en.translation", "res://translation/dialogs/dialogic_5_mercury_arrival_translation.fr.translation", "res://translation/dialogs/dialogic_6_mercury_departure_translation.en.translation", "res://translation/dialogs/dialogic_6_mercury_departure_translation.fr.translation", "res://translation/dialogs/dialogic_7_venus_arrival_translation.en.translation", "res://translation/dialogs/dialogic_7_venus_arrival_translation.fr.translation", "res://translation/dialogs/dialogic_8_venus_departure_translation.en.translation", "res://translation/dialogs/dialogic_8_venus_departure_translation.fr.translation", "res://translation/dialogs/dialogic_9_borea_translation.en.translation", "res://translation/dialogs/dialogic_cave_translation.en.translation", "res://translation/dialogs/dialogic_cave_translation.fr.translation", "res://translation/dialogs/dialogic_character_translations.fr.translation")
|
||||
locale/translations=PackedStringArray("res://translation/game/gui.en.translation", "res://translation/game/gui.fr.translation", "res://translation/dialogs/dialogic_character_translations.en.translation", "res://translation/dialogs/dialogic_demeter_ship_failed_translation.en.translation", "res://translation/dialogs/dialogic_demeter_ship_failed_translation.fr.translation", "res://translation/dialogs/dialogic_1_waking_up_translation.en.translation", "res://translation/dialogs/dialogic_1_waking_up_translation.fr.translation", "res://translation/dialogs/dialogic_2_demeter_intro_translation.en.translation", "res://translation/dialogs/dialogic_2_demeter_intro_translation.fr.translation", "res://translation/dialogs/dialogic_3_demeter_ship_presentation_translation.en.translation", "res://translation/dialogs/dialogic_3_demeter_ship_presentation_translation.fr.translation", "res://translation/dialogs/dialogic_4_cave_translation.en.translation", "res://translation/dialogs/dialogic_4_cave_translation.fr.translation", "res://translation/dialogs/dialogic_5_mercury_arrival_translation.en.translation", "res://translation/dialogs/dialogic_5_mercury_arrival_translation.fr.translation", "res://translation/dialogs/dialogic_6_mercury_departure_translation.en.translation", "res://translation/dialogs/dialogic_6_mercury_departure_translation.fr.translation", "res://translation/dialogs/dialogic_7_venus_arrival_translation.en.translation", "res://translation/dialogs/dialogic_7_venus_arrival_translation.fr.translation", "res://translation/dialogs/dialogic_8_venus_departure_translation.en.translation", "res://translation/dialogs/dialogic_8_venus_departure_translation.fr.translation", "res://translation/dialogs/dialogic_9_borea_translation.en.translation", "res://translation/dialogs/dialogic_cave_translation.en.translation", "res://translation/dialogs/dialogic_cave_translation.fr.translation", "res://translation/dialogs/dialogic_character_translations.fr.translation", "res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.en.translation", "res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.fr.translation")
|
||||
locale/test="fr"
|
||||
|
||||
[rendering]
|
||||
|
||||
@@ -100,6 +100,8 @@ func _ready():
|
||||
GameInfo.game_data.player_data.inventory.add_item(Pickaxe.new())
|
||||
GameInfo.game_data.player_data.inventory.add_item(Fork.new())
|
||||
GameInfo.game_data.player_data.inventory.add_item(ShipPortal.new())
|
||||
if not GameInfo.game_data.current_run.story_step is StartStoryStep:
|
||||
GameInfo.game_data.player_data.inventory.add_item(TractorBeam.new())
|
||||
|
||||
plant_grid = PlantGrid.new(self)
|
||||
add_child(plant_grid)
|
||||
|
||||
@@ -2,8 +2,8 @@ extends Resource
|
||||
class_name RegionParameter
|
||||
|
||||
const DEFAULT_ROCK_THRESHOLD = 0.3
|
||||
const DEFAULT_DECONTAMINATION_THRESHOLD = 0.1
|
||||
const DEFAULT_CRISTAL_THRESHOLD = 0.3
|
||||
const DEFAULT_DECONTAMINATION_THRESHOLD = 0.3
|
||||
const DEFAULT_CRISTAL_THRESHOLD = 0.1
|
||||
const DEFAULT_CHARGE = 10
|
||||
const DEFAULT_TALION_CELL_CHANCE : Array[int] = [0,0,0,1,1]
|
||||
const DEFAULT_ENERGY_CELL_CHANCE : Array[int] = [1,2,2,2,3]
|
||||
|
||||
@@ -24,17 +24,6 @@ Choice/112/disabled_text,,
|
||||
Choice/113/text,Oh no ! But I've been away just a moment !,Oh non ! Mais je ne me suis absenté qu'un instant !
|
||||
Choice/113/disabled_text,,
|
||||
Text/114/text,"Uhm, I actually repaired the ship over two full months; I didn't wake you up just after the save, I thought that you wouldn't want to wait that long!","Euh… En fait, j'ai réparé le vaisseau pendant plus de deux mois ; je ne t'ai pas réveillé tout de suite après la sauvegarde, je me suis dit que tu ne voudrais pas attendre aussi longtemps !"
|
||||
Text/ce/text,"Luckily, I've found something that might help you. I've cataloged ancient human ruins all over the planet, and some of them contain ""vending machines,"" machines for exchanging items for money.","J'ai heureusement déniché quelque chose qui pourrait t'aider. J'ai répertorié des anciennes ruines humaines un peu partout sur la planète, et dans certaines, on trouve des ""distributeurs"", des machines d'échange d'objet contre de l'argent."
|
||||
Choice/101/text,Thanks !,Merci !
|
||||
Choice/101/disabled_text,,
|
||||
Choice/cf/text,Vending machines?,Des distributeurs ?
|
||||
Choice/cf/disabled_text,,
|
||||
Text/d0/text,"Yes, that's where they used to get the energy they needed, for a completely unreasonable price.","Oui c'est là qu'ils récupéraient de quoi se réalimenter en énergie, pour un prix complètement déraisonnable."
|
||||
Text/d1/text,"Before, real people were in charge of transactions, but for some reason, humans spent all of recent history figuring out how to encounter as few humans as possible. Maybe they couldn't stand each other anymore...","Avant, de vraies personnes étaient chargées de ces transactions, mais va savoir pourquoi les humains ont passé toute leur histoire récente à trouver comment croiser le moins d'humains possible. Peut-être qu'ils ne pouvaient plus se supporter..."
|
||||
Choice/d2/text,Money?,De l'argent ?
|
||||
Choice/d2/disabled_text,,
|
||||
Text/d3/text,"Yes, each human had a sum of an imaginary unit they called money. They based their entire social hierarchy on this unit.","Oui, chaque humain avait une somme d'une unité imaginaire qu'ils appelaient argent. Ils basaient toute leur échelle sociale en fonction de cette unité."
|
||||
Text/d4/text,"In any case, I've updated their system. They'll probably need some energy to function, but they might bring you some interesting items.","En-tout-cas, j'ai mis à jour leur système, ils auront sûrement besoin d'un peu d'énergie pour fonctionner, mais ils t'apporteront peut-être des objets intéressants."
|
||||
Text/d5/text,"As usual, you can use your detector to find the entrance to these ruins.","Comme d'habitude, tu peux utiliser ton détecteur pour trouver la porte d'entrée de ces ruines."
|
||||
Text/d6/text,"[b]These artifacts will be placed on a shelf in your ship[/b], but remember that if you ran out of energy and I have to teleport the ship, you'll lose them.","[b]Ces artefacts seront placés sur une étagère dans le vaisseau[/b], mais si tu tombes à court d'énergie, je devrais téléporter le vaisseau et tu perdras tous les objets à l'intérieur !"
|
||||
Text/115/text,"I've updated you in the meantime, and you'll discover a new tool I just added, a tractable beam!","Je t'ai mis à jour pendant ce temps, et tu découvriras en sortant un nouvel outil : un rayon tracteur."
|
||||
Text/116/text,"If you were in trouble for sorting your seeds, it might help you.","Si tu avais des difficulté pour trier tes graines, cela te sera utile."
|
||||
Text/d7/text,Good luck with the [color=#FFA617]Venus Relay Base[/color]; it's a little further than the last one.,Bon courage pour la [color=#FFA617]Base Vénus[/color] elle est un petit peu plus loin que la dernière.
|
||||
|
||||
|
@@ -0,0 +1,15 @@
|
||||
keys,en,fr
|
||||
Text/117/text,"I've found something that might help you. I've cataloged ancient human ruins all over the planet, and some of them contain ""vending machines,"" machines for exchanging items for money.",,"J'ai déniché quelque chose qui pourrait t'aider. J'ai répertorié des anciennes ruines humaines un peu partout sur la planète, et dans certaines, on trouve des ""distributeurs"", des machines d'échange d'objet contre de l'argent."
|
||||
Choice/101/text,Thanks !,Merci !
|
||||
Choice/101/disabled_text,,
|
||||
Choice/cf/text,Vending machines?,Des distributeurs ?
|
||||
Choice/cf/disabled_text,,
|
||||
Text/d0/text,"Yes, that's where they used to get the energy they needed, for a completely unreasonable price.","Oui c'est là qu'ils récupéraient de quoi se réalimenter en énergie, pour un prix complètement déraisonnable."
|
||||
Text/d1/text,"Before, real people were in charge of transactions, but for some reason, humans spent all of recent history figuring out how to encounter as few humans as possible. Maybe they couldn't stand each other anymore...","Avant, de vraies personnes étaient chargées de ces transactions, mais va savoir pourquoi les humains ont passé toute leur histoire récente à trouver comment croiser le moins d'humains possible. Peut-être qu'ils ne pouvaient plus se supporter..."
|
||||
Choice/d2/text,Money?,De l'argent ?
|
||||
Choice/d2/disabled_text,,
|
||||
Text/d3/text,"Yes, each human had a sum of an imaginary unit they called money. They based their entire social hierarchy on this unit.","Oui, chaque humain avait une somme d'une unité imaginaire qu'ils appelaient argent. Ils basaient toute leur échelle sociale en fonction de cette unité."
|
||||
Text/d4/text,"In any case, I've updated their system. They'll probably need some energy to function, but they might bring you some interesting items.","En-tout-cas, j'ai mis à jour leur système, ils auront sûrement besoin d'un peu d'énergie pour fonctionner, mais ils t'apporteront peut-être des objets intéressants."
|
||||
Text/d5/text,"As usual, you can use your detector to find the entrance to these ruins.","Comme d'habitude, tu peux utiliser ton détecteur pour trouver la porte d'entrée de ces ruines."
|
||||
Text/d6/text,"[b]These artifacts will be placed on a shelf in your ship[/b], but remember that if you ran out of energy and I have to teleport the ship, you'll lose them.","[b]Ces artefacts seront placés sur une étagère dans le vaisseau[/b], mais si tu tombes à court d'énergie, je devrais téléporter le vaisseau et tu perdras tous les objets à l'intérieur !"
|
||||
Text/118/text,"It could really help you, so go fetch them.","Ils te seront très utiles, alors tu devrais aller les chercher !"
|
||||
|
@@ -0,0 +1,19 @@
|
||||
[remap]
|
||||
|
||||
importer="csv_translation"
|
||||
type="Translation"
|
||||
uid="uid://bpstv3r2f6cpg"
|
||||
|
||||
[deps]
|
||||
|
||||
files=["res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.en.translation", "res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.fr.translation"]
|
||||
|
||||
source_file="res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.csv"
|
||||
dest_files=["res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.en.translation", "res://translation/dialogs/dialogic_6_vending_machine_presentation_translation.fr.translation"]
|
||||
|
||||
[params]
|
||||
|
||||
compress=1
|
||||
delimiter=0
|
||||
unescape_keys=false
|
||||
unescape_translations=true
|
||||
@@ -99,6 +99,8 @@ DETECT_USE_TEXT,"Search near signals","Rechercher les signaux proches"
|
||||
SHIP_TELEPORT,Ship Portal,Portail vers le vaisseau
|
||||
SHIP_TELEPORT_DESC_TEXT,"A mysterious technology that get you to the [b]Internode[/b].","Une mystèrieuse technologie qui t'amène sur l'[b]Internode[/b]"
|
||||
SHIP_TELEPORT_USE_TEXT,"Teleport on the ship","Téléportation sur le vaisseau"
|
||||
TRACTOR_BEAM,Tractor Beam,Rayon Tracteur
|
||||
TRACTOR_BEAM_DESC_TEXT,"A technology that allows objects to be moved remotely, very useful for sorting seeds","Une technologie qui permet de déplacer les objets à distance, très utile pour trier les graines"
|
||||
HARVEST,Harvest,Récolter
|
||||
KNIFE,Knife,Couteau
|
||||
KNIFE_DESC_TEXT,"Use it to [b]harvest mature plants[/b]. Does not consume energy.",Utilise-le pour [b]récolter les plantes mature[/b]. Ne consomme pas d’énergie.
|
||||
|
||||
|
Reference in New Issue
Block a user