Skip to content

Commit

Permalink
Merge remote-tracking branch 'EVE_dev/jascha_dev_1.3'
Browse files Browse the repository at this point in the history
  • Loading branch information
jugdemon committed Aug 14, 2019
2 parents b937c33 + dcbad8b commit 3ab594e
Show file tree
Hide file tree
Showing 47 changed files with 1,168 additions and 1,144 deletions.
Binary file modified Assets/EVE/Resources/Prefabs/EvaluationCamera.prefab
Binary file not shown.
Binary file modified Assets/EVE/Resources/Prefabs/HUD_Canvas_4_panels.prefab
Binary file not shown.
Binary file modified Assets/EVE/Resources/Prefabs/Menus/Canvas.prefab
Binary file not shown.
Binary file modified Assets/EVE/Resources/Prefabs/Menus/Evaluation/EvaluationMap.prefab
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified Assets/EVE/Resources/Prefabs/Player/Character Placement.prefab
Binary file not shown.
Binary file modified Assets/EVE/Resources/Prefabs/Player/FPSController.prefab
Binary file not shown.
10 changes: 6 additions & 4 deletions Assets/EVE/Resources/Setup_EVE_DB.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ CREATE TABLE IF NOT EXISTS `EVE`.`questions` (
UNIQUE INDEX `name_UNIQUE` (`name` ASC))
ENGINE = InnoDB
AUTO_INCREMENT = 197
DEFAULT CHARACTER SET = latin1;
DEFAULT CHARACTER SET = utf8;


-- -----------------------------------------------------
Expand Down Expand Up @@ -109,7 +109,8 @@ CREATE TABLE IF NOT EXISTS `EVE`.`sessions` (
ON DELETE CASCADE
ON UPDATE NO ACTION)
ENGINE = InnoDB
DEFAULT CHARACTER SET = latin1;
AUTO_INCREMENT = 0
DEFAULT CHARACTER SET = utf8;


-- -----------------------------------------------------
Expand All @@ -122,7 +123,7 @@ CREATE TABLE IF NOT EXISTS `EVE`.`store_strings` (
PRIMARY KEY (`id`),
UNIQUE INDEX `id_UNIQUE` (`id` ASC))
ENGINE = InnoDB
DEFAULT CHARACTER SET = latin1;
DEFAULT CHARACTER SET = utf8;


-- -----------------------------------------------------
Expand Down Expand Up @@ -160,7 +161,7 @@ CREATE TABLE IF NOT EXISTS `EVE`.`user_answers` (
ON UPDATE NO ACTION)
ENGINE = InnoDB
AUTO_INCREMENT = 386
DEFAULT CHARACTER SET = latin1;
DEFAULT CHARACTER SET = utf8;


-- -----------------------------------------------------
Expand Down Expand Up @@ -543,3 +544,4 @@ ENGINE = InnoDB;
SET SQL_MODE=@OLD_SQL_MODE;
SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;

Binary file modified Assets/EVE/Scenes/Launcher.unity
Binary file not shown.
Binary file modified Assets/EVE/Scenes/Tasks/JRD_3d.unity
Binary file not shown.
Binary file modified Assets/EVE/Scenes/Tasks/JRD_Drag_and_drop.unity
Binary file not shown.
Binary file modified Assets/EVE/Scenes/Training/Maze.unity
Binary file not shown.
Binary file modified Assets/EVE/Scenes/Training/Maze/LightingData.asset
Binary file not shown.
5 changes: 2 additions & 3 deletions Assets/EVE/Scenes/Training/Maze/LightingData.asset.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 19 additions & 5 deletions Assets/EVE/Scenes/Training/Maze/ReflectionProbe-0.exr.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion Assets/EVE/Scripts/LevelLoader/LaunchManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ void Awake()
FirstPersonController.SetActive(false);
DontDestroyOnLoad(FirstPersonController);
MenuCanvas = GameObjectUtils.InstatiatePrefab("Prefabs/Menus/Canvas");GameObject.FindGameObjectWithTag("MenuCanvas");
MenuCanvas.GetComponent<Canvas>().worldCamera = GameObject.FindWithTag("MainCamera").GetComponent<Camera>();
DontDestroyOnLoad(MenuCanvas);

SceneManager.sceneLoaded += OnSceneLoaded;
Expand Down Expand Up @@ -179,7 +180,8 @@ private void OnSceneLoaded(Scene scene, LoadSceneMode mode)
var subSceneName = sceneList[_currentScene].Name;
Debug.Log("Scene " + _currentScene + ":" + subSceneName + " in " + _activeSceneName);
LoggingManager.InsertLiveSystemEvent("SceneFlow","switch",null, "Scene " + _currentScene + ":" + subSceneName.Substring(0, Math.Min(subSceneName.Length, 25)) + " in " + _activeSceneName.Substring(0, Math.Min(_activeSceneName.Length, 25)));

FirstPersonController.transform.position = Vector3.zero;
FirstPersonController.transform.rotation = Quaternion.identity;
FirstPersonController.SetActive(false);
if (_activeSceneName == "Launcher" && !_inQuestionnaire && !_configureLabchart)
{ //coming back from a scene
Expand All @@ -197,11 +199,13 @@ private void OnSceneLoaded(Scene scene, LoadSceneMode mode)
{
_currentScene++;
LoadCurrentScene();
return;
}
else
{
MenuManager.InstantiateAndShowMenu("Finish Menu","Launcher");
SessionParameters.Clear();
return;
}
}
}
Expand Down
21 changes: 13 additions & 8 deletions Assets/EVE/Scripts/Logging/EvaluationMapGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ public class EvaluationMapGenerator : MonoBehaviour
private string filePathRoot;
private string sceneName;

public Camera Camera;

// Use this for
void Start()
{
Expand Down Expand Up @@ -46,15 +48,16 @@ void Start()
}
if (computeMapImage)
{
Camera camera = GetComponent<Camera>();
camera.pixelRect = new Rect(0, 0, width, height);
Camera.enabled = true;
//Camera camera = GetComponent<Camera>();
Camera.pixelRect = new Rect(0, 0, width, height);
RenderTexture rt = new RenderTexture(width, height, 24);
camera.targetTexture = rt;
Camera.targetTexture = rt;
Texture2D screenShot = new Texture2D(width, height, TextureFormat.RGB24, false);
camera.Render();
Camera.Render();
RenderTexture.active = rt;
screenShot.ReadPixels(new Rect(0, 0, width, height), 0, 0);
camera.targetTexture = null;
Camera.targetTexture = null;
RenderTexture.active = null; // JC: added to avoid errors
Destroy(rt);
byte[] bytes = screenShot.EncodeToPNG();
Expand All @@ -66,22 +69,24 @@ void Start()
ns.Add("", "");
XmlWriterSettings settings = new XmlWriterSettings { Indent = true };

XmlSerializer xmls = new XmlSerializer(camera.worldToCameraMatrix.GetType());
XmlSerializer xmls = new XmlSerializer(Camera.worldToCameraMatrix.GetType());
using (var stream = File.Open(filePathRoot + sceneName + "_worldToCameraMatrix.xml", FileMode.Create))
{
using (var xmlWriter = XmlWriter.Create(stream, settings))
{
xmls.Serialize(xmlWriter, camera.worldToCameraMatrix, ns);
xmls.Serialize(xmlWriter, Camera.worldToCameraMatrix, ns);
}
}

using (var stream = File.Open(filePathRoot + sceneName + "_projectionMatrix.xml", FileMode.Create))
{
using (var xmlWriter = XmlWriter.Create(stream, settings))
{
xmls.Serialize(xmlWriter, camera.projectionMatrix, ns);
xmls.Serialize(xmlWriter, Camera.projectionMatrix, ns);
}
}

Camera.enabled = false;
}
Destroy(this);
}
Expand Down
Loading

0 comments on commit 3ab594e

Please sign in to comment.