void Awake() { Director.getInstance().currentSceneController = this; guiCtrl = gameObject.AddComponent <FirstSceneGuiCtrl>() as FirstSceneGuiCtrl; loadResources(); graph = new statusGraph(numOfPirest, numOfDevil, true); }
// Use this for initialization void Start() { statusGraph tempGraph = new statusGraph(3, 3, false); node test = new node(3, 2, false); operation result = tempGraph.getNextStep(test); Debug.Log(result.P + " " + result.D); }
void Start() { SSDirector director = SSDirector.getInstance(); director.currentSceneController = this; loadResources(); actionManager = gameObject.AddComponent <CCActionManager>() as CCActionManager; judge = gameObject.AddComponent <Judge>() as Judge; judge.setJudge(characters, boat, this); tip = gameObject.AddComponent <statusGraph>() as statusGraph; tip.createGraph(); status = GameStatus.playing; }
private void initSettings() { status = GameStatus.playing; leftCoast.initSettings(); rightCoast.initSettings(); for (int i = 0; i < 6; i++) { characters[i].initSettings(); characters[i].setPosOnCoast(rightCoast.getVacantIndex()); } boat.initSettings(); Destroy(tip); tip = gameObject.AddComponent <statusGraph>() as statusGraph; tip.createGraph(); }