[?] MoveWorld Function

Post » Mon Aug 01, 2011 2:33 pm

So, I need some information on this function. I'm using a script with this function too make a trap, but it's not working.

Here is the script
begin stc_vre_bolttrapshort doneif ( Done == 0 )	if ( OnActivate == 1 )		stc_rve_bolttrap1->MoveWorld Y, 50		set done to 1	endifelse	if ( OnActivate == 1 )		Activate		return	endifendifend

stc_rve_bolttrap1 is the bolt, a huntsman bolt from BM that has be reassigned as a sword to allow a script to be attatched. It is also inside an interior cell. Now, I tried both Move and MoveWorld, and neither did anything. Is it because it's a weapon?

MWSFD didn't shed any light, so please don't point me to it. Any help appreciated :D
User avatar
Glu Glu
 
Posts: 3352
Joined: Sun Apr 01, 2007 5:39 am

Post » Mon Aug 01, 2011 10:14 am

the function works for 1 frame, so you have to keep calling it to move things (usually each frame for fluid movement) .
for example
begin stc_vre_bolttrapshort done; better to have a single onactivate call if possibleif ( OnActivate == 1 )	if ( done )		set done to 0		Activate	else		set done to 1	endifendifif ( done )	; keep moving each frame	stc_rve_bolttrap1->MoveWorld Y, 50endifend

User avatar
Dawn Farrell
 
Posts: 3522
Joined: Thu Aug 23, 2007 9:02 am

Post » Mon Aug 01, 2011 9:19 am

Alright, I used that script, and only 1 out of the 128 bolts moved. Is it possible to make them all move?
User avatar
Steve Fallon
 
Posts: 3503
Joined: Thu Aug 23, 2007 12:29 am


Return to III - Morrowind