Post new topic    
Plotscripting problem... 
 PostMon Aug 04, 2014 7:28 am
Send private message Reply with quote
Lol, just when I was thinking I was getting a knack for it.

Quote:
include, plotscr.hsd
include, jamesdopp.hsi

plotscript, forstarters, begin
suspend player
show backdrop (5)
show text box (5)
wait for text box
show text box (6)
wait for text box
fade screen out
show map
wait (15)
fade screen in
wait (15)
show text box (7)
wait for text box
set hero speed (me, 8)
set hero direction (me,east)
walk hero (me,east,2)
wait for hero (me)
set hero direction (me,north)
wait for hero (me)
wait (10)
destroy NPC (2)
wait (10)
set hero direction (me,south)
walk hero (me,south,3)
wait for hero (me)

set hero direction (me,east)
walk hero (me,east,4)
wait for hero (me)
set hero direction (me,south)
walk hero (me,south,3)
use door (4)
walk hero (me,south,3)
wait for hero (me)
show text box (23)
wait for text box
resume player
set hero speed (me, 4)
fight formation (1)
show text box (16)
wait for text box
end


At this point the character freezes in place and won't stop walking south. I've been through the script 3 times now and didn't see where I went wrong.
Care to help me out by giving me advice on my game? Get the early demo by clicking here
Demo updated 8/13/2014
Metal Slime
Send private message
 
 PostMon Aug 04, 2014 7:39 am
Send private message Reply with quote
The only thing I see "off" with your script is where you set the player's speed to 8. Most walking speeds are evenly divisible into 20 (1,2,4,5,10,20), so they won't end up clipping through wall and tile boundaries.

As a possible workaround, what happens if you replace the word "south" with "down"?

Also, if your hero is going to immediately start heading south, it not required to have them face south first - they'll face south automatically.
To friends long gone, and those I've yet to meet - thank you.
 
 PostMon Aug 04, 2014 8:05 am
Send private message Reply with quote
Fenrir-Lunaris wrote:
The only thing I see "off" with your script is where you set the player's speed to 8. Most walking speeds are evenly divisible into 20 (1,2,4,5,10,20), so they won't end up clipping through wall and tile boundaries.

As a possible workaround, what happens if you replace the word "south" with "down"?

Also, if your hero is going to immediately start heading south, it not required to have them face south first - they'll face south automatically.


Thank you. I set the speed to 10 and that fixed it right up.
Care to help me out by giving me advice on my game? Get the early demo by clicking here
Demo updated 8/13/2014
Display posts from previous: