Exemplo n.º 1
0
    private void OnGameStart()
    {
        MapManager.ImportMap(Application.streamingAssetsPath + "/" + maps[0] + ".map");
        MapManager.CreateEntities();

        InitiatePlayer("AK47", "M4A1", null);
    }
Exemplo n.º 2
0
 void OnGUI()
 {
     if (fb.draw())
     {
         output = (fb.outputFile == null)?"cancel hit":fb.outputFile.ToString();
         if (output.EndsWith(".png") || output.EndsWith(".jpg") || output.EndsWith(".JPG") || output.EndsWith(".PNG"))
         {
             Debug.Log("Image file detected;");
             tileMapGame.ImportTexture(output);
         }
         else if (output.EndsWith(".map") || output.EndsWith(".MAP"))
         {
             Debug.Log("Game file detected");
             tileMap.ImportMap(output);
         }
         gameObject.SetActive(false);
     }
 }