This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== Moving Level Elements, Rails and OneTimeRot ====== Whether you want levels to have moving platforms or for path/hazards to open up upon certain conditions, you will need to use Rails or OneTimeRot parameters. Note that if you want objects to stay how they were upon reset, leave Switchable--RespawnReset as 0, otherwise set it to 2. ===== Rails ===== <WRAP center round help 60%> Please help out this wiki by filling out details surrounding rails and their parameters </WRAP> Rails are listed in a separate structure as objects in a given level's byaml file. They come in different types, mainly differentiated by colour, although this writer does not understand the different between them. ==== UnitConfigName: Rail ==== <code> - Id: rail2 IsClosed: false IsLadder: false IsLinkDest: false LayerConfigName: Cmn Links: {} ModelName: null Priority: !l 100 RailPoints: - CheckPointIndex: !l 0 ControlPoints: - {X: 280.00000, Y: -25.00000, Z: 610.00000} - {X: 280.00000, Y: -25.00000, Z: 610.00000} Id: rail2/0 LayerConfigName: Cmn Links: {} OffsetX: 0.00000 OffsetY: 0.00000 OffsetZ: 0.00000 Rotate: {X: 0.00000, Y: 0.00000, Z: 0.00000} Scale: {X: 1.00000, Y: 1.00000, Z: 1.00000} Translate: {X: 280.00000, Y: -25.00000, Z: 490.00000} UnitConfigName: RailPoint UseOffset: false - CheckPointIndex: !l 0 ControlPoints: - {X: 280.00000, Y: -25.00000, Z: 610.00000} - {X: 280.00000, Y: -25.00000, Z: 610.00000} Id: rail2/1 LayerConfigName: Cmn Links: {} OffsetX: 0.00000 OffsetY: 0.00000 OffsetZ: 0.00000 Rotate: {X: 0.00000, Y: 0.00000, Z: 0.00000} Scale: {X: 1.00000, Y: 1.00000, Z: 1.00000} Translate: {X: 280.00000, Y: -25.00000, Z: 610.00000} UnitConfigName: RailPoint UseOffset: false RailType: Bezier Rotate: {X: 0.00000, Y: 0.00000, Z: 0.00000} Scale: {X: 1.00000, Y: 1.00000, Z: 1.00000} Translate: {X: 0.00000, Y: 0.00000, Z: 0.00000} UnitConfigName: Rail </code> The location of the rail itself does not matter, only that of the given RailPoints. You can use rails to rotate and even resize an object as well as dictate its path. RailType can either be set to Linear or Bezier. If a rail is linear, you do not need ControlPoints, and as a result are restricted to straight lines. Bezier curves use ControlPoints to control what a RailPoint's given curve looks like. ==== RailableParams ==== Objects are attached to rails using the RailableParams--Rail link. In the byaml it looks like this: <code> Links: RailableParams__Rail: - {DefinitionName: RailableParams__Rail, DestUnitId: rail3/0, UnitFileName: ''} RailableParams__AttCalc: !l 0 RailableParams__BreakFrame: !l 30 RailableParams__ConstantVelUnitLength: 2.50000 RailableParams__Interpolation: !l 1 RailableParams__MoveFrame: !l 60 RailableParams__Patrol: !l 2 RailableParams__StandbyFrame: !l 0 RailableParams__Vel: !l 0 </code> * ConstantVelUnitLength and MoveFrame describe the speed at which the object moves along the rail, with Vel performing some yet unknown role. * Patrol describes how many times and in what way the objects moves along the rail. 0 means it only moves once, 1 means it will start its cycle again, 2 means it will move back the way it came until it finds its start point.