Ah, thanks.
And another question. Sorry. ^^
I have this NPC 4 times in the room, each on a hot tile:
None, invis:
Label "Loop"
Wait for event Player burned
If...
Wait until var _X = _MyX
If...
Wait until var _Y = _MyY
Build floor at (where corresponding hot tile is)
Disappear
If End
Wait 0 turn(s)
If End
Wait 0 turn(s)
Go to "Loop"
These work as intended. They "
shut"
the hot tile after walking on them and getting burned.
The following is what acts really strange:
Aumtlich, visible
Behaviour Beam attack
Label "ALoop0"
If...
Wait for event player burned
Go to "ALoop1"
If End
Wait 0 turn(s)
Go to "ALoop0"
Label "ALoop1"
Wait 1 turn(s)
If...
Wait for event player burned
Go to "ALoop2"
If End
Wait 0 turn(s)
Go to "ALoop1"
Label "ALoop2"
Wait 1 turn(s)
If...
Wait for event player burned
Go to "ALoop3"
If End
Wait 0 turn(s)
Go to "ALoop2"
Label "ALoop3"
Wait 1 turn(s)
If...
Wait for event player burned
Disappear
If End
Wait 0 turn(s)
Go to "ALoop3"
This should work like the following:
Each time the player gets burned, the NPC goes to the next loop.
When it is in Loop3 and you get burned, it disappears.
That works for normal hot tiles. Walk on 4 of them and the NPC disappears and the beam with it.
But it works differently for the hot tiles the first NPC is on.
I have four of those, each the same with the exception of the position they are in and that their loops are labeled "
NLoop"
, "
WLoop"
, "
ELoop"
and "
SLoop"
for their positions (North, West, East, South).
If I walk on the four hot tiles in almost any order the Aumtlich will NOT disappear.
But when I walk in the order "
North, South, West, East"
or in the order "
East, West, South, North"
the Aumtlich does disappear. Why is this??
I actually find this pretty useful as I can make a riddle out of this. But why does it work this way?
EDIT: I added another loop to the hot tile NPCs:
They switch to Loop2 after they build floor over the hot tile. The second loop checks if a pressure plate is pressed and then builds the hot tile again and switches back to the first loop.
That works in rebuilding the hot tiles but that makes the Aumtlichs behave even stranger. The same combinations don't work when the pressure plate is pressed in between. In some cases it still does, in most it doesn't. Also running over the same (rebuilt) hot tile doesn't kill the Aumtlich either.
That also messes with a reset loop I wanted to built into the aumtlich, where it checks in every loop, if the pressure plate was pressed and resets the "
hot tile walked"
counter to 0.
EDIT2: Also when I enter another room in test mode and come back, the order seems to become random.
=========================
=========================
EDIT3: Another topic: I seem to be doing equipment wrong. I used custom equipment in scripts only.
The following Character is supposed to be an armor:
Spiderbite
Behaviour Attack first
Wait for player to touch me
Disappear
Set var _X = _MyX
Set var _Y = _MyY
Equipment Swap Armor Spiderbite
That works when I place the character somewhere. Also works on other armors (like the healing one from above).
Also works when I give it to the player in the following script:
LevelUps
Imperative Make script global
Label "1"
If...
Wait until var _REP > 4
[...]
Equipment Swap Armor Spiderbite
Go to "2"
Else
Wait 0 turn(s)
[...]
But I cannot give the armor via the F4 menu to the player. The ID gives me an accessory with the same name but it has no accessory picture (the chest) and does not work properly. (E.g the healing effect from earlier is not applied.)
What's the problem here? Is there a command to make a character be an equipment that I have not found?
EDIT4: [Was another problem, fixed it myself.]
EDIT5: Solved the ground part. Just had to swap the loop to the bottom whoops. Still doesn't work with giving it via custom ID in the F4 screen.
EDIT6: Now I have yet another problem with the equipment. It ceases working after I leave a room. That didn't happen before.
Why does everything break all the time. It's really frustrating. Pretty annoying to work with...
[Fixed this, but I don't know how.]
EDIT7: [retracted]
[Last edited by Aquitanius at 06-03-2016 03:05 AM]