Exemplo n.º 1
0
    public void OrderConvertSavage(IVillageItem item)
    {
        IPeon p = PopPeon();

        if (p != null)
            p.SeekSavageToConvert(item);
    }
Exemplo n.º 2
0
	public void SeekVillageItem(IVillageItem item) {
		if (actionState != ActionState.eIdle)
			return;
	}
Exemplo n.º 3
0
    public void OrderSacrificeItem(IVillageItem item, int queueSlot)
    {
        IPeon p = PopPeon();

        if (p != null)
            p.SeekVillageItem(item, queueSlot);
        else
        {
            item.Unselect();
            SacrificeQueue.GetInstance().FreeSlot(queueSlot);
        }
    }
Exemplo n.º 4
0
 public void SeekSavageToConvert(IVillageItem item)
 {
     mTarget = ((VillageItem)item).transform;
     actionState = State.eGetSavageForConversion;
     MoveToPoint(mTarget.position);
 }
Exemplo n.º 5
0
    public void SeekVillageItem(IVillageItem item, int queueSlot)
	{
		mTarget = ((VillageItem)item).transform;
		mQueueSlot = queueSlot;

		actionState = State.eRetrievingItem;

		MoveToPoint(mTarget.position);
	}
Exemplo n.º 6
0
    public void RetrieveSavage(IVillageItem item)
    {
        Payload.ShowPayload(VillageItemEnum.eSavage);
        GameObject.Destroy((item as VillageItem).gameObject);

        actionState = State.eConvertSavage;
        MoveToPoint(Chapel.GetInstance().GetEntrace());
    }
Exemplo n.º 7
0
	public void RetrieveVillageItem(IVillageItem item)
	{
        IStorageArea a = Village.GetGlobalInstance().AnimalsArea;
        switch ( item.ItemType)
        {
            case VillageItemEnum.eFruit:
                a = Village.GetGlobalInstance().FruitsArea;
                break;
            case VillageItemEnum.eSavage:
                a = Village.GetGlobalInstance().SavagesArea;
                break;
        }

        VillageItem sI = item as VillageItem;
        if ( a.retriveList.Contains( sI ))
        {
            a.retriveList.Remove(sI);
        }

		payLoadVillageItem = item.ItemType;
		actionState = State.eQueueingItem;
		Payload.ShowPayload(item.ItemType);

		MoveToPoint(SacrificeQueue.GetInstance().GetSlotPos(mQueueSlot));
        GameObject.Destroy((item as VillageItem).gameObject);
        mTarget = null;
	}