Now, I can accept that the script is probably messy and I would welcome any suggestions to improve it. However, the bug isn't with the script per se, it is to do with the height changing function.
Save the following script to a FSGLOBAL lump and load it. Start a game and, at the console, type "give QuestItem1". When you do this, the player's viewheight drops to 25. So far so good.
Now type "take QuestItem1" at the console and the view height does not change. However, the command has been run because as soon as you go up a step, the viewheight alters to the required 41.
So, short version, if a FraggleScript is changing the viewheight from 25 to 41, the change will not take effect until the player walks up a step. Presumably it *should* take effect immediately the command is run?
Code: Select all
[scripts]
//include("lspec.h");
script 254
{
if (checkinventory(0, "QuestItem1",1))
{
runcommand("viewheight 25");
}
wait(35);
if (!checkinventory(0, "QuestItem1",1))
{
runcommand("viewheight 41");
}
wait(35);
startscript(254);
}
startscript(254); 