The problem I'm having is when my characters mount the ladder their z (height) value appears to change from 0 to 4. There is nowhere in my script where I have the z-value changing to 4. I simply want the hero's z to remain the same when they mount the ladder.
I have done a lot of searching for the cause of this and still cannot figure it out. If anyone can find the problem, or suggest some troubleshooting technique that would be great, thanks.
The code is:
Code: Select all
### Zone 1 - Changes party hero sprites to default
If (read zone (1, x, y)) then(
set hero speed(me, 4)
set hero z (0, 0)
If (hero by slot (0) == hero:Taras) then(
set hero picture (0, 71)
) else if (hero by slot (0) == hero:Antonina) then(
set hero picture (0, 18)
)
embiggen now
)
If (read zone (1, a, b)) then(
set hero speed(me, 4)
set hero z (1, 0)
If (hero by slot (1) == hero:Taras) then(
set hero picture (1, 71)
) else if (hero by slot (1) == hero:Antonina) then(
set hero picture (1, 18)
)
embiggen now
)
### Zone 2 - Changes sprites to ladder
If (read zone (2, x, y)) then(
set hero speed(me, 4)
set hero z (0, 0)
If (hero by slot (0) == hero:Taras) then(
set hero picture (0, 84)
) else if (hero by slot (0) == hero:Antonina) then(
set hero picture (0, 85)
)
embiggen now
)
If (read zone (2, a, b)) then(
set hero speed(me, 4)
set hero z (1, 0)
If (hero by slot (1) == hero:Taras) then(
set hero picture (1, 84)
) else if (hero by slot (1) == hero:Antonina) then(
set hero picture (1, 85)
)
embiggen now
)