Adds screenshot previews to save files
parent
d55df21e82
commit
6a6afc79cb
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,75 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using UnityEngine;
|
||||||
|
using SiegeSong;
|
||||||
|
|
||||||
|
namespace SiegeSong
|
||||||
|
{
|
||||||
|
public class HeadTurn : MonoBehaviour
|
||||||
|
{
|
||||||
|
public Transform HeadBone;
|
||||||
|
public Transform RibcageBone;
|
||||||
|
public Transform LookTarget;
|
||||||
|
public CameraManager CameraManager;
|
||||||
|
public Motor Motor;
|
||||||
|
|
||||||
|
private float rotationXMin = 350.0f;
|
||||||
|
private float rotationXMax = 350.0f;
|
||||||
|
private float rotationYMin = -60.0f;
|
||||||
|
private float rotationYMax = 80.0f;
|
||||||
|
|
||||||
|
private float rotationXOffset = 0.0f;
|
||||||
|
private float rotationYOffset = 180.0f;
|
||||||
|
|
||||||
|
private float rotationXModifier = 1.0f;
|
||||||
|
private float rotationYModifier = 1.0f;
|
||||||
|
private float rotationZModifier = 1.0f;
|
||||||
|
|
||||||
|
private float previousX;
|
||||||
|
private float previousY;
|
||||||
|
private float previousZ;
|
||||||
|
|
||||||
|
|
||||||
|
void Start()
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void LateUpdate()
|
||||||
|
{
|
||||||
|
if (Motor.Moving == false)
|
||||||
|
{
|
||||||
|
var direction = new Vector3(1, -1, 1);
|
||||||
|
if (LookTarget == null)
|
||||||
|
direction = new Vector3(
|
||||||
|
(CameraManager.ActiveCamera.transform.rotation.eulerAngles.x + rotationXOffset) * rotationXModifier,
|
||||||
|
(CameraManager.ActiveCamera.transform.rotation.eulerAngles.y + rotationYOffset) * rotationYModifier,
|
||||||
|
-CameraManager.ActiveCamera.transform.rotation.eulerAngles.z * rotationZModifier);
|
||||||
|
else
|
||||||
|
direction = LookTarget.position - HeadBone.position;
|
||||||
|
|
||||||
|
var resetingHeadTurn = true;
|
||||||
|
if (direction.y - rotationYOffset > rotationYMax)
|
||||||
|
{
|
||||||
|
previousY = direction.y;
|
||||||
|
resetingHeadTurn = false;
|
||||||
|
}
|
||||||
|
if (direction.y + rotationYOffset < rotationYMin)
|
||||||
|
{
|
||||||
|
previousY = direction.y;
|
||||||
|
resetingHeadTurn = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (resetingHeadTurn)
|
||||||
|
{
|
||||||
|
direction.y = previousY;
|
||||||
|
resetingHeadTurn = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
HeadBone.eulerAngles = direction;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ad1fd1255c13b834fbf89aebd46db885
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@ -1,75 +1,75 @@
|
|||||||
using System.Collections;
|
//using System.Collections;
|
||||||
using System.Collections.Generic;
|
//using System.Collections.Generic;
|
||||||
using UnityEngine;
|
//using UnityEngine;
|
||||||
using SiegeSong;
|
//using SiegeSong;
|
||||||
|
|
||||||
namespace SiegeSong
|
//namespace SiegeSong
|
||||||
{
|
//{
|
||||||
public class HeadTurn : MonoBehaviour
|
// public class HeadTurn : MonoBehaviour
|
||||||
{
|
// {
|
||||||
public Transform HeadBone;
|
// public Transform HeadBone;
|
||||||
public Transform RibcageBone;
|
// public Transform RibcageBone;
|
||||||
public Transform LookTarget;
|
// public Transform LookTarget;
|
||||||
public CameraManager CameraManager;
|
// public CameraManager CameraManager;
|
||||||
public Motor Motor;
|
// public Motor Motor;
|
||||||
|
|
||||||
private float rotationXMin = 350.0f;
|
// private float rotationXMin = 350.0f;
|
||||||
private float rotationXMax = 350.0f;
|
// private float rotationXMax = 350.0f;
|
||||||
private float rotationYMin = -60.0f;
|
// private float rotationYMin = -60.0f;
|
||||||
private float rotationYMax = 80.0f;
|
// private float rotationYMax = 80.0f;
|
||||||
|
|
||||||
private float rotationXOffset = 0.0f;
|
// private float rotationXOffset = 0.0f;
|
||||||
private float rotationYOffset = 180.0f;
|
// private float rotationYOffset = 180.0f;
|
||||||
|
|
||||||
private float rotationXModifier = 1.0f;
|
// private float rotationXModifier = 1.0f;
|
||||||
private float rotationYModifier = 1.0f;
|
// private float rotationYModifier = 1.0f;
|
||||||
private float rotationZModifier = 1.0f;
|
// private float rotationZModifier = 1.0f;
|
||||||
|
|
||||||
private float previousX;
|
// private float previousX;
|
||||||
private float previousY;
|
// private float previousY;
|
||||||
private float previousZ;
|
// private float previousZ;
|
||||||
|
|
||||||
|
|
||||||
void Start()
|
// void Start()
|
||||||
{
|
// {
|
||||||
|
|
||||||
}
|
// }
|
||||||
|
|
||||||
void LateUpdate()
|
// void LateUpdate()
|
||||||
{
|
// {
|
||||||
if (Motor.Moving == false)
|
// if (Motor.Moving == false)
|
||||||
{
|
// {
|
||||||
var direction = new Vector3(1, -1, 1);
|
// var direction = new Vector3(1, -1, 1);
|
||||||
if (LookTarget == null)
|
// if (LookTarget == null)
|
||||||
direction = new Vector3(
|
// direction = new Vector3(
|
||||||
(CameraManager.ActiveCamera.transform.rotation.eulerAngles.x + rotationXOffset) * rotationXModifier,
|
// (CameraManager.ActiveCamera.transform.rotation.eulerAngles.x + rotationXOffset) * rotationXModifier,
|
||||||
(CameraManager.ActiveCamera.transform.rotation.eulerAngles.y + rotationYOffset) * rotationYModifier,
|
// (CameraManager.ActiveCamera.transform.rotation.eulerAngles.y + rotationYOffset) * rotationYModifier,
|
||||||
-CameraManager.ActiveCamera.transform.rotation.eulerAngles.z * rotationZModifier);
|
// -CameraManager.ActiveCamera.transform.rotation.eulerAngles.z * rotationZModifier);
|
||||||
else
|
// else
|
||||||
direction = LookTarget.position - HeadBone.position;
|
// direction = LookTarget.position - HeadBone.position;
|
||||||
|
|
||||||
var resetingHeadTurn = true;
|
// var resetingHeadTurn = true;
|
||||||
if (direction.y - rotationYOffset > rotationYMax)
|
// if (direction.y - rotationYOffset > rotationYMax)
|
||||||
{
|
// {
|
||||||
previousY = direction.y;
|
// previousY = direction.y;
|
||||||
resetingHeadTurn = false;
|
// resetingHeadTurn = false;
|
||||||
}
|
// }
|
||||||
if (direction.y + rotationYOffset < rotationYMin)
|
// if (direction.y + rotationYOffset < rotationYMin)
|
||||||
{
|
// {
|
||||||
previousY = direction.y;
|
// previousY = direction.y;
|
||||||
resetingHeadTurn = false;
|
// resetingHeadTurn = false;
|
||||||
}
|
// }
|
||||||
|
|
||||||
if (resetingHeadTurn)
|
// if (resetingHeadTurn)
|
||||||
{
|
// {
|
||||||
direction.y = previousY;
|
// direction.y = previousY;
|
||||||
resetingHeadTurn = false;
|
// resetingHeadTurn = false;
|
||||||
}
|
// }
|
||||||
else
|
// else
|
||||||
{
|
// {
|
||||||
HeadBone.eulerAngles = direction;
|
// HeadBone.eulerAngles = direction;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
|
|||||||
@ -1 +0,0 @@
|
|||||||
{"Title":"Human Being - Save Game 1","PlayerFullName":"Human Being","PlayerLevel":1,"PlayerActiveQuestFriendlyName":"None","LastPlayedOn":"08:42PM 24/10/2022","InGameDate":"00:48PM 1/00/1136","PreviewImageBase64DataString":"","FileNameSuffix":"00001"}
|
|
||||||
@ -1 +0,0 @@
|
|||||||
{"Actors":[{"ID":0,"InstanceID":"CAAAA","LocationX":114.89908599853516,"LocationY":61.764015197753909,"LocationZ":289.1904296875,"RotationX":-1.4622918154127974e-10,"RotationY":266.3935546875,"RotationZ":-8.537744520253909e-7,"InventoryItemIDs":[],"InventoryItemQuantities":[],"ActiveInventoryItemIDs":[],"SpeciesKey":"_Human","FirstName":"Human","LastName":"Being","Alive":true,"IsPlayer":true,"HairstyleID":0,"FacialHairID":0,"FacialDetailID":0,"HairColorR":0,"HairColorG":0,"HairColorB":0,"HairColorA":0,"Recoil":false,"NoiseBeingProduced":2,"VisualStealthRating":0,"StaminaRecoveryRate":0.20000000298023225,"MagicRecoveryRate":0.20000000298023225,"HealthRecoveryRate":0.20000000298023225,"MaxHealth":100,"MaxStamina":100,"MaxMagic":100,"Health":100.0,"Stamina":100.0,"Magic":100.0,"SprintCost":2,"InCombat":false,"Staggered":false,"OffBalance":false,"Fallen":false,"Invincible":false,"Hunger":0,"Thirst":0,"Exhaustion":0,"Heat":0,"CarryWeight":0,"MaxCarryWeight":100,"Gold":0,"Level":1,"Experience":0,"ExperienceToNextLevel":1000,"CanHealH":true,"CanHealS":true,"CanHealM":true,"StaminaTemporarilyRemovedIncrements":[],"MagicTemporarilyRemovedIncrements":[],"HealthTemporarilyRemovedIncrements":[]}],"Year":1136,"Day":1,"Hour":12,"Minute":48}
|
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue