ajout de la plant champ et suppression de la texture planted (ajout de la graine à la place) #55
This commit is contained in:
@@ -20,7 +20,12 @@ func is_one_time_use():
|
||||
return true
|
||||
|
||||
func can_use(player : Player, zone : Area2D) -> bool:
|
||||
return not player.planet.is_there_contamination(zone.global_position)
|
||||
var is_there_a_plant_here = false
|
||||
for area in zone.get_overlapping_areas() :
|
||||
if area is Plant:
|
||||
is_there_a_plant_here = true
|
||||
|
||||
return not is_there_a_plant_here and not player.planet.is_there_contamination(zone.global_position)
|
||||
|
||||
func use(player : Player, zone : Area2D) -> bool:
|
||||
player.play_sfx("dig")
|
||||
|
||||
Reference in New Issue
Block a user