Ejemplo n.º 1
0
 // initialize key values called from the belt this belongs to
 public void Initialize(Transform parent, Vector3 position, WhirlwindBelt belt)
 {
     transform.parent = parent;
     transform.position = position;
     this.belt = belt;
     Enable(false);
 }
Ejemplo n.º 2
0
    // initialize important information passed from the belt this item belongs to
    public void Initialize(WhirlwindBelt belt, float radius, Vector3 idlePosition, BookInfo bookInfo)
    {
        this.belt = belt;
        this.radius = radius;
        this.idlePosition = idlePosition;
        this.bookInfo = bookInfo;

        itemImage.GetComponent<SpriteRenderer>().sprite = GetItemSprite(bookInfo.FileName);

        transform.position = idlePosition;
    }