public LightPanel(Puzzle owner) : base(owner) { defaultRight = Direction.NegX; Type = TypeName; deletable = true; OffsetAmount = LightOffsetAmount.Near; }
internal override void FinishReadProperties() { normal = ItemFacing.Normal; right = ItemFacing.Right; // Get offset float x = Math.Abs(localPosition.X); float y = Math.Abs(localPosition.Y); float z = Math.Abs(localPosition.Z); float v = Math.Max(x, Math.Max(y, z)); offsetAmount = (v == 0.125f) ? LightOffsetAmount.Near : LightOffsetAmount.Far; base.FinishReadProperties(); }