Rotate and Move Props Using Markers
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
using { /UnrealEngine.com/Temporary/Diagnostics }
using { /UnrealEngine.com/Temporary/SpatialMath }
verse_prop_manipulator := class(creative_device):
@editable MovableProp : creative_prop = creative_prop { }
@editable var LocationMarker : []creative_prop = array { }
@editable Rotate : float = 0.0
@editable Time : float = 3.0
@editable Looping : logic = false
var ThisMarker : int = 0
var NumberOfMarkers : int = 0
var SelectedLocationMarker : creative_prop = creative_prop { }
OnBegin<override>()<suspends>:void=
#Array operations must be inside of a failable expression(true of false)
if(MarkerTest := LocationMarker[ThisMarker], PropTest := MovableProp):
set NumberOfMarkers = LocationMarker.Length
SelectMarker()
SelectMarker()<suspends> : void=
if(Element := LocationMarker[ThisMarker]):
set SelectedLocationMarker = Element
PrepPosition(SelectedLocationMarker)
PrepPosition(Prop : creative_prop) : void= #Prop is LocationMarker
Transform := Prop.GetTransform()
Position := Transform.Translation
You're reading a preview
The full reference is free for BrainDeadGuild Discord members — sign in to read it all, or open the original at the source.
Sign in with your BrainDead.TV / BrainDeadGuild Discord account for full access.