[ZScript] Get carrying sector velocity

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

[ZScript] Get carrying sector velocity

Postby dodopod » Tue Jan 15, 2019 2:13 pm

Is there any way, in ZScript, to get the velocity at which an actor is being moved by a carrying sector? For example, suppose the player is on a conveyor belt, and I want to know how fast the player can run in a given direction.
dodopod
 
Joined: 04 Oct 2017

Re: [ZScript] Get carrying sector velocity

Postby Graf Zahl » Thu Jan 17, 2019 2:22 am

No, not really. Player movement works by acceleration so the carry scrollers do a lot of fudging to make the player reach the same movement speed as the scrolling texture.
User avatar
Graf Zahl
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [ZScript] Get carrying sector velocity

Postby Matt » Thu Jan 17, 2019 3:04 am

A lot of times I'll just get the actor's position one moment and its position a tick (or more) later, since that way it'll cover conveyors and platforms and at least some monster chase movement.
User avatar
Matt
Putting the XD into *xdeath since 2007
 
 
 
Joined: 04 Jan 2004
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia


Return to Scripting

Who is online

Users browsing this forum: No registered users and 1 guest