コード例 #1
0
 void PlaceBuildingInSelection()
 {
     if (canPlaceObject)
     {
         currentObject.transform.position = (Vector3)startNodePos;
         currentObject = null;
         //currentInputMode = InputMode.selectMode;
     }
     else
     {
         Destroy(currentObject);
         //currentInputMode = InputMode.selectMode;
     }
 }
コード例 #2
0
 public void SetNewBuilding(PlaceableAsset newObject)
 {
     currentObject    = Instantiate(newObject);
     currentInputMode = InputMode.buildMode;
 }