//this method is used to fetch and load data from the JSON text file
    public void loadPlayerDataFromFile()
    {
        if (File.Exists(Application.dataPath + "/Resources/SaveData/FloorTransitionData.txt"))
        {
            //fetching and creating references to players current scripts
            player_log       = gameObject.GetComponent <Player_Log>();
            characterStats   = gameObject.GetComponent <CharacterStats>();
            player_Inventory = gameObject.GetComponent <Player_Inventory>();
            skillsManager    = gameObject.GetComponent <SkillsManager>();

            Data = (PlayerObjectData)ScriptableObject.CreateInstance("PlayerObjectData");
            TextAsset jsonFile = Resources.Load("SaveData/FloorTransitionData") as TextAsset;
            JsonUtility.FromJsonOverwrite(jsonFile.text, Data);

            characterStats.loadData(Data);
            skillsManager.loadData(Data);
            player_log.loadData(Data);
            player_Inventory.loadData(Data);

            Debug.Log("Data Loaded from previous Floor");
        }
        else
        {
            Debug.Log("Transition Save Data not found");
        }
    }