![错误信息图片] [1]
脚本在本地计算机上运行正常。当尝试在远程计算机上运行时,它无法读取位于脚本当前目录中的config.xml文件。 这是我的代码:
--GameManager.cs
public class GameManager : MonoBehaviour{
[SerializeField] private CreatureDatabase creatureDatabase;
private Creature SummonMoonDancer(){
CreatureData creatureData;
bool success = creatureDatabase.CreatureDatabaseDictionary.TryGetValue(typeof(Creature_MoonDancer), out creatureData);
if(success == false){
Debug.LogError("Tried summoning MoonDancer when creature database did not have a typeof(MoonDancer) key");
}
else{
return new Creature_MoonDancer(creatureData), Player.GetInt("NumberOfMoonorbsInPlayersPouch");
}
}
}