diff --git a/MoCha/Assets/Prefabs/Progress Bars & Text.prefab b/MoCha/Assets/Prefabs/Progress Bars & Text.prefab index a511dc4..0154166 100644 Binary files a/MoCha/Assets/Prefabs/Progress Bars & Text.prefab and b/MoCha/Assets/Prefabs/Progress Bars & Text.prefab differ diff --git a/MoCha/Assets/Scenes/Goals.unity b/MoCha/Assets/Scenes/Goals.unity index 4292e3c..6820354 100644 Binary files a/MoCha/Assets/Scenes/Goals.unity and b/MoCha/Assets/Scenes/Goals.unity differ diff --git a/MoCha/Assets/Scenes/Home.unity b/MoCha/Assets/Scenes/Home.unity index a229a1d..3354a83 100644 Binary files a/MoCha/Assets/Scenes/Home.unity and b/MoCha/Assets/Scenes/Home.unity differ diff --git a/MoCha/Assets/Scripts/GetGoals.cs b/MoCha/Assets/Scripts/GetGoals.cs index d61e680..66323e9 100644 --- a/MoCha/Assets/Scripts/GetGoals.cs +++ b/MoCha/Assets/Scripts/GetGoals.cs @@ -12,6 +12,9 @@ namespace PedometerU.Tests public class GetGoals : MonoBehaviour { + // For HTTP requests to the server. + private MochaParser mp; + // Goals Progress Bar public Image pbbg; public Image pbf; @@ -23,6 +26,7 @@ namespace PedometerU.Tests private string[] items = { "circle_eye", "crazy_hair", "circle_head", "gap_mouth", "pig_nose", "crown" }; // Display Text + public Text rivalText; public Text goalText; public Text stepText; public Text pointsText; @@ -74,6 +78,9 @@ namespace PedometerU.Tests void Start () { + // This should later only get caleld per goal + StartCoroutine(updateRival()); + savedSteps = PlayerPrefs.GetInt("currentSteps"); savedPoints = PlayerPrefs.GetInt("totalPoints"); // Create a new pedometer @@ -184,6 +191,15 @@ namespace PedometerU.Tests return output; } + // Shell function for now to update rival text. + // You'll wanna call this with startcoroutine(). + public IEnumerator updateRival() + { + mp = new MochaParser (); + yield return mp.MakeRequest ("http://corder.tech/mocha/random"); + rivalText.text = "You are being chased by " + mp.players [0].username; + } + void Update() { updateTimeRemaining (); diff --git a/MoCha/Assets/Sprites/Asset 1.png b/MoCha/Assets/Sprites/Asset 1.png new file mode 100644 index 0000000..da06c58 Binary files /dev/null and b/MoCha/Assets/Sprites/Asset 1.png differ diff --git a/MoCha/Assets/Sprites/Asset 1.png.meta b/MoCha/Assets/Sprites/Asset 1.png.meta new file mode 100644 index 0000000..d8f1345 --- /dev/null +++ b/MoCha/Assets/Sprites/Asset 1.png.meta @@ -0,0 +1,107 @@ +fileFormatVersion: 2 +guid: 5e61f4351ff403445a1633bb46270048 +timeCreated: 1525112241 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: WebGL + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/MoCha/Assets/Sprites/running_man.png b/MoCha/Assets/Sprites/running_man.png new file mode 100644 index 0000000..fb0a07c Binary files /dev/null and b/MoCha/Assets/Sprites/running_man.png differ diff --git a/MoCha/Assets/Sprites/running_man.png.meta b/MoCha/Assets/Sprites/running_man.png.meta new file mode 100644 index 0000000..2400708 --- /dev/null +++ b/MoCha/Assets/Sprites/running_man.png.meta @@ -0,0 +1,107 @@ +fileFormatVersion: 2 +guid: b868443409c4bd7488485b342bebc4d6 +timeCreated: 1525111249 +licenseType: Free +TextureImporter: + fileIDToRecycleName: {} + externalObjects: {} + serializedVersion: 4 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + isReadable: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: -1 + aniso: -1 + mipBias: -1 + wrapU: 1 + wrapV: 1 + wrapW: -1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spritePixelsToUnits: 100 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + platformSettings: + - buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + - buildTarget: WebGL + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + spritePackingTag: + userData: + assetBundleName: + assetBundleVariant: diff --git a/MoCha/ProjectSettings/ProjectSettings.asset b/MoCha/ProjectSettings/ProjectSettings.asset index ca47127..3d00004 100644 Binary files a/MoCha/ProjectSettings/ProjectSettings.asset and b/MoCha/ProjectSettings/ProjectSettings.asset differ diff --git a/MoCha/ProjectSettings/ProjectVersion.txt b/MoCha/ProjectSettings/ProjectVersion.txt index e3618f1..27997c5 100644 --- a/MoCha/ProjectSettings/ProjectVersion.txt +++ b/MoCha/ProjectSettings/ProjectVersion.txt @@ -1 +1 @@ -m_EditorVersion: 2017.4.1f1 +m_EditorVersion: 2017.3.1f1