void OnEnable() { miniMapController = GameObject.Find("CanvasMiniMap").GetComponent <MiniMapController> (); mme = new MiniMapEntity(); mme.icon = icon; mme.rotation = initialIconRotation; mme.size = size; mme.upAxis = upAxis; mme.rotateWithObject = rotateWithObject; mme.clampInBorder = clampIconInBorder; mme.clampDist = clampDistance; mmo = miniMapController.RegisterMapObject(this.gameObject, mme); }
// References //public GameDataManager GameDataManager.instance; ///////////////////////End of Variables///////////////////////// ///////////////////////////Functions//////////////////////////// // Use this for initialization void Start() { // Assign the reference to the game data manager //GameDataManager.instance = GameDataManager.instance; // Set the character icons and characters -- male selected if (GameDataManager.instance.SelectedGender() == GENDER.MALE) { MiniMapController.RegisterMapObject(gameObject, miniMapImageMale); } // Set the character icons and characters -- female selected else if (GameDataManager.instance.SelectedGender() == GENDER.FEMALE) { MiniMapController.RegisterMapObject(gameObject, miniMapImageFemale); } }
// References //public GameDataManager GameDataManager.instance; ///////////////////////End of Variables///////////////////////// ///////////////////////////Functions//////////////////////////// // Use this for initialization void Start() { // Assign the reference to the game data manager //GameDataManager.instance = GameDataManager.instance; // Set the character icons and characters -- male selected if (GameDataManager.instance.CivillianType() == CIVILLIANTYPE.MALE) { MiniMapController.RegisterMapObject(gameObject, miniMapImageMale); } // Set the character icons and characters -- female selected else if (GameDataManager.instance.CivillianType() == CIVILLIANTYPE.FEMALE) { MiniMapController.RegisterMapObject(gameObject, miniMapImageFemale); } // Set the character icons and characters -- female selected else if (GameDataManager.instance.CivillianType() == CIVILLIANTYPE.CAT) { MiniMapController.RegisterMapObject(gameObject, miniMapImageCat); } }
void Start() { MiniMapController.RegisterMapObject(this.gameObject, image); }
public Image image; //choose the image that we want to hook up the object // Use this for initialization void Start() { //At the start, register the object and it's image to the object list that will be rendered MiniMapController.RegisterMapObject(gameObject, image); }
///////////////////////End of Variables///////////////////////// ///////////////////////////Functions//////////////////////////// // Use this for initialization void Start() { MiniMapController.RegisterMapObject(gameObject, miniMapImage); }