public FieldObject(FieldObjectEntity objectField, WorldAnchor anchor) : base(objectField.collisionWidth, objectField.collisionHeight, anchor) { this.objectField = objectField; this.overlapEvent = objectField.overlapEventType; vectorControl = new VectorControl(this); }
public FieldInstance(E_OverlapEvent overlapEvent, ObjectField objectField, WorldAnchor anchor) : base(objectField.CollisionWidth, objectField.CollisionHeigth, anchor) { this.objectField = objectField; this.overlapEvent = overlapEvent; vectorControl = new VectorControl(this); }
public LayerRect(LayerPoint point, float width, float height, WorldAnchor anchor) { this.point = point; this.width = width; this.height = height; this.anchor = anchor; CalcCornerPoints(out TopLeft, out BottomRight); Rect = RectTool.Create(TopLeft.InLayerPoint, BottomRight.InLayerPoint); }
public Tile(LayerInfo layerInfo, WorldAnchor anchor) : base(layerInfo.width, layerInfo.height, anchor) { if (layerInfo == null) { Debug.LogError("must not be null"); } this.tileInfo = layerInfo; }
public static Rect Apply(Rect rect, WorldAnchor anchor) { if (anchor == WorldAnchor.TopLeft || anchor == WorldAnchor.MiddleLeft || anchor == WorldAnchor.BottomLeft) { rect.x += rect.width / 2; } else if (anchor == WorldAnchor.TopRight || anchor == WorldAnchor.MiddleRight || anchor == WorldAnchor.BottomRight) { rect.x -= rect.width / 2; } if (anchor == WorldAnchor.TopLeft || anchor == WorldAnchor.TopCenter || anchor == WorldAnchor.TopRight) { rect.y -= rect.height / 2; } else if (anchor == WorldAnchor.BottomLeft || anchor == WorldAnchor.BottomCenter || anchor == WorldAnchor.BottomRight) { rect.y += rect.height / 2; } return rect; }
public FieldObject(OverlapEventType overlapEvent, float width, float height, WorldAnchor anchor) : base(width, height, anchor) { this.overlapEvent = overlapEvent; vectorControl = new VectorControl(this); }
public FieldInstance(E_OverlapEvent overlapEvent, float width, float height, WorldAnchor anchor) : base(width, height, anchor) { this.overlapEvent = overlapEvent; vectorControl = new VectorControl(this); }
private Subject2 AddSubject(float initX, float initY, float width, float height, WorldAnchor anchor) { return null; }
public Subject2(float width, float height, WorldAnchor anchor) { this.width = width; this.height = height; this.anchor = anchor; }
public ObjectHolder(float width, float height, WorldAnchor anchor) : base(width, height, anchor) { }