https://sureai.net/forum/viewtopic.php?t=628
SCN MQ01BootScript
Float XAchsePosition
Float XAchse
Float Timer
Short BootState
Short BootAnkunft
Short BootAnkunft2
Begin OnActivate
if (Player.IsCurrentFurnitureRef "MQ01BootPlayerStuhl" != 1)
Message "Ihr müsst Euch erst auf euren Platz am Heck setzen, damit das Boot ablegen kann."
endif
End
Begin GameMode
if (MQ01PorimRef.GetDistance, "MQ01BootPorimStuhlRef" <= 100) && (BootState == 0)
Set Storyvar to 5
endif
End
Begin GameMode
if (Player.IsCurrentFurnitureRef "MQ01BootPlayerStuhl" == 1) && (Storyvar == 5) && (BootState == 0)
DisablePlayerControls
Set Timer to Timer + getSecondsPassed
if ( Timer >= 5 )
PlaySound3d DRSMetalOpen01
Message "Das Boot legt ab."
Set BootState to 1
Set Storyvar to 10
Message "Das Boot legt ab." ;Nachricht
endif
endif
End
Begin GameMode
if (BootState == 1)
Set XAchsePosition to GetPos X
Set XAchse to XachsePosition +11
SetPos X Xachse
endif
End
Begin GameMode
if (MQ01BootRef.GetDistance, MQ01BootMarker01 <= 300) && (Storyvar == 10)
Set Storyvar to 15
Set BootAngreifer to 1
endif
End
Begin GameMode
if (MQ01BootRef.GetDistance, MQ01BootMarker05 <= 100) && (BootState == 1)
Set Bootstate to 2
Set Storyvar to 20
SetStage MQ01Porim 15
Set BootAnkunft to 1
endif
End
Begin GameMode
if (Bootstate == 2)
Set XAchsePosition to GetPos X
Set XAchse to XachsePosition +0
SetPos X Xachse
Player.EnablePlayerControls
endif
End
Begin GameMode
if (Storyvar == 20) && (BootAnkunft2 == 0)
MQ01PorimRef.moveto "MQ01BootMarkerPorim02"
Set BootAnkunft2 to 1
endif
EndBegin gamemode
if (bootstate == 1)
set xachserotation to get pos x
set xachse to xachserotation +2
set pos x xachse
player. xachserotation to get pos x
player.xachse to xachserotation +2
player.set pos x xachse
Chair. xachserotation to get pos x
Chair.xachse to xachserotation +2
Chair.set pos x xachse
endif
endscn RotateXPlus05
Float XAchse
Float xAchseMoved
Begin GameMode
Set XAchse to GetAngle X
Set XAchseMoved to XAchse + 0.5
SetAngle X XAchseMoved
end