Esempio n. 1
0
 public BoardItem CreateInstance(Layer layer, Board board, int x, int y, int z, int zM, MapleBool r, MapleBool hide, MapleBool reactor, MapleBool flow, int? rx, int? ry, int? cx, int? cy, string name, string tags, List<ObjectInstanceQuest> questInfo, bool flip, bool parseOffsets)
 {
     ObjectInstance instance = new ObjectInstance(this, layer, board, x, y, z, zM, r, hide, reactor, flow, rx, ry, cx, cy, name, tags, questInfo, flip);
     if (parseOffsets) ParseOffsets(instance, board, x, y);
     return instance;
 }
Esempio n. 2
0
 public void ParseOffsets(ObjectInstance instance, Board board, int x, int y)
 {
     bool ladder = l0 == "ladder";
     if (footholdOffsets != null)
     {
         foreach (List<XNA.Point> anchorList in footholdOffsets)
         {
             List<FootholdAnchor> anchors = new List<FootholdAnchor>();
             foreach (XNA.Point foothold in anchorList)
             {
                 FootholdAnchor anchor = new FootholdAnchor(board, x + foothold.X, y + foothold.Y, instance.LayerNumber, instance.PlatformNumber, true);
                 board.BoardItems.FHAnchors.Add(anchor);
                 instance.BindItem(anchor, foothold);
                 anchors.Add(anchor);
             }
             CreateFootholdsFromAnchorList(board, anchors);
         }
     }
     if (chairOffsets != null)
     {
         foreach (XNA.Point chairPos in chairOffsets)
         {
             Chair chair = new Chair(board, x + chairPos.X, y + chairPos.Y);
             board.BoardItems.Chairs.Add(chair);
             instance.BindItem(chair, chairPos);
         }
     }
 }
Esempio n. 3
0
 public override BoardItem CreateInstance(Layer layer, Board board, int x, int y, int z, bool flip)
 {
     ObjectInstance instance = new ObjectInstance(this, layer, board, x, y, z, layer.zMDefault, false, false, false, false, null, null, null, null, null, null, null, flip);
     ParseOffsets(instance, board, x, y);
     return instance;
 }