![]() |
Attention | Topic was automatically imported from the old Question2Answer platform. |
![]() |
Asked By | Dead_lucky_32 |
func create new enemy (type),
Var enemy = Battle Units. Enemy
var oppcheck = randongen.chance(0)
create new opp()
Elif enemy == null
If type == 'null'
Enemies.shuttle()
var Enemy = Enemies. Front()
var CreateEnemy = Enemy. instance()
EP.add child CreateEnemy)
if CreateEnemy.name = "Chest";
CreateEnemy. fake = true
hideMagicButtons()
battleButtonContainer.hide ()
battleOppContafiner.show()
O battleOppContainer.get_node("OpenActionButton).show()
print("Mimic Created")
else:
CreateEnemy.connect("on_death", self, _on_Enemy_Death)
else:
var CreateEnemy = type, instance()
EP.add child(createEnemy)
I can’t see to find the error or at least how to fix it, btw I used Google lens to get the text because I’m using my phone so sorry if it’s a little hard to read I fixed it up a bit to be more readable