Page 1 of 1

runcommand("viewheight default");

Posted: Fri Nov 30, 2007 0:16
by Enjay
I've been using the following in a fragglescript at the start of a map to simulate the player picking himself up off the floor - after the previous map finished with the E1M8 "almost kill the player and end the level" special.

Code: Select all

[scripts] 

script 254
{
	runcommand("viewheight 16");
	wait(30);
	runcommand("viewheight 41");
}

startscript(254);
However, I've also just started messing with custom player classes with altered view heights. This means that the player could be using a number of different view heights, depending on which class they have selected. Is there anyway to get the same effect but allow it to set the correct player view height for the current player class?

If not, might a command something like the title of this thread be a suitable addition to GZdoom?

Posted: Fri Nov 30, 2007 9:11
by Graf Zahl
No. Legacy doesn't support this feature and this is solely to handle Legacy hacks, nothing more.

Posted: Fri Nov 30, 2007 15:30
by Enjay
Hmmm, OK, an editing work around might be to place the player in a small sector with a floor lower than the surrounding room, make it look like the rest of the room using transfer heights and raise the sector silently at the start of the map. I'll just have to ensure that the sector is not so low that the players eye height drops below the fake floor. I'll try that when I get home. If it works out, it'll actually be more convenient than having to use fraggle script anyway.