Skip to content
Snippets Groups Projects
Commit 285f7e34 authored by Meike Wienholt's avatar Meike Wienholt
Browse files

some changes in *.cs files

parent b9be90e0
No related branches found
No related tags found
No related merge requests found
......@@ -13,6 +13,7 @@ public class AnimalsInInventory : MonoBehaviour
public GameObject Parent;
// here is the script attached to
public GameObject currentObject;
public int entityIDtoActivate;
// Start is called before the first frame update
......
......@@ -4,6 +4,7 @@ using UnityEngine;
public class CanBePickedUP : MonoBehaviour
{
static public CanBePickedUP core;
public GameObject Item;
public int entityID;
public int stageID;
......
......@@ -4,6 +4,7 @@ using UnityEngine;
public class ChangeScenery : MonoBehaviour
{
static public ChangeScenery core;
public GameObject oldSprite;
public GameObject neueSprite;
public int entityID;
......@@ -26,6 +27,7 @@ public class ChangeScenery : MonoBehaviour
*/
if (Database.core.entities[SupportFunctions.core.findEntityIndexById(entityID)].entityStageId == stage)
{
//it has to be this way because we can not access the unique components via code in another way.
oldSprite.GetComponent<SpriteRenderer>().enabled = false;
neueSprite.GetComponent<SpriteRenderer>().enabled = true;
......
......@@ -4,6 +4,7 @@ using UnityEngine;
public class CheckIfAllowed : MonoBehaviour
{
static public CheckIfAllowed core;
public int QuestID;
public GameObject Entity;
public int nodesIndex;
......
......@@ -19,6 +19,7 @@ public class DestroyOnStage : MonoBehaviour
public int entityID;
public int stageID;
public GameObject ToDestroy;
public int ItemID;
public bool shallReactivate;
void Start()
......@@ -43,7 +44,7 @@ public class DestroyOnStage : MonoBehaviour
{
/*this is a specific case and I need to change it to a more universal approach
*/
if (Database.core.items[SupportFunctions.core.findItemIndexById(29)].acquired)
if (Database.core.items[SupportFunctions.core.findItemIndexById(ItemID)].acquired)
{
ToDestroy.SetActive(true);
Database.core.entities[SupportFunctions.core.findEntityIndexById(entityID)].entityStageId++;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment