Merge final changes into master #2
18
.github/workflows/activation.yaml
vendored
Normal file
18
.github/workflows/activation.yaml
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
name: Acquire activation file
|
||||
on:
|
||||
workflow_dispatch: {}
|
||||
jobs:
|
||||
activation:
|
||||
name: Request manual activation file
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Request manual activation file
|
||||
- name: Request manual activation file
|
||||
id: getManualLicenseFile
|
||||
uses: game-ci/unity-request-activation-file@v2
|
||||
# Upload artifact (Unity_v20XX.X.XXXX.alf)
|
||||
- name: Expose as artifact
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: ${{ steps.getManualLicenseFile.outputs.filePath }}
|
||||
path: ${{ steps.getManualLicenseFile.outputs.filePath }}
|
||||
54
.github/workflows/main.yaml
vendored
Normal file
54
.github/workflows/main.yaml
vendored
Normal file
@@ -0,0 +1,54 @@
|
||||
name: Actions
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build project
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Checkout (without LFS)
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
|
||||
# Git LFS
|
||||
- name: Create LFS file list
|
||||
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id
|
||||
|
||||
- name: Restore LFS cache
|
||||
uses: actions/cache@v2
|
||||
id: lfs-cache
|
||||
with:
|
||||
path: .git/lfs
|
||||
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
|
||||
|
||||
- name: Git LFS Pull
|
||||
run: |
|
||||
git lfs pull
|
||||
git add .
|
||||
git reset --hard
|
||||
|
||||
# Cache
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: Library
|
||||
key: Library-${{ hashFiles('Assets/**', 'Packages/**', 'ProjectSettings/**') }}
|
||||
restore-keys: |
|
||||
Library-
|
||||
|
||||
# Build
|
||||
- name: Build project
|
||||
uses: game-ci/unity-builder@v2
|
||||
env:
|
||||
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
|
||||
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
|
||||
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
|
||||
with:
|
||||
targetPlatform: WebGL
|
||||
|
||||
# Output
|
||||
- uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: Build
|
||||
path: build
|
||||
|
||||
@@ -1063,6 +1063,134 @@ CanvasRenderer:
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 619783808}
|
||||
m_CullTransparentMesh: 1
|
||||
--- !u!1 &701875521
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 701875522}
|
||||
- component: {fileID: 701875523}
|
||||
m_Layer: 0
|
||||
m_Name: DamageSound
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &701875522
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 701875521}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 2036477790}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!82 &701875523
|
||||
AudioSource:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 701875521}
|
||||
m_Enabled: 1
|
||||
serializedVersion: 4
|
||||
OutputAudioMixerGroup: {fileID: 0}
|
||||
m_audioClip: {fileID: 8300000, guid: 9f3c3c28564416d49b2e71899119032d, type: 3}
|
||||
m_PlayOnAwake: 0
|
||||
m_Volume: 1
|
||||
m_Pitch: 1
|
||||
Loop: 0
|
||||
Mute: 0
|
||||
Spatialize: 0
|
||||
SpatializePostEffects: 0
|
||||
Priority: 128
|
||||
DopplerLevel: 1
|
||||
MinDistance: 1
|
||||
MaxDistance: 500
|
||||
Pan2D: 0
|
||||
rolloffMode: 0
|
||||
BypassEffects: 0
|
||||
BypassListenerEffects: 0
|
||||
BypassReverbZones: 0
|
||||
rolloffCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
- serializedVersion: 3
|
||||
time: 1
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
panLevelCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
spreadCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 0
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
reverbZoneMixCustomCurve:
|
||||
serializedVersion: 2
|
||||
m_Curve:
|
||||
- serializedVersion: 3
|
||||
time: 0
|
||||
value: 1
|
||||
inSlope: 0
|
||||
outSlope: 0
|
||||
tangentMode: 0
|
||||
weightedMode: 0
|
||||
inWeight: 0.33333334
|
||||
outWeight: 0.33333334
|
||||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
--- !u!1 &733797115
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -1714,7 +1842,7 @@ ParticleSystem:
|
||||
ringBufferLoopRange: {x: 0, y: 1}
|
||||
emitterVelocityMode: 1
|
||||
looping: 1
|
||||
prewarm: 1
|
||||
prewarm: 0
|
||||
playOnAwake: 1
|
||||
useUnscaledTime: 0
|
||||
autoRandomSeed: 1
|
||||
@@ -6564,6 +6692,7 @@ MonoBehaviour:
|
||||
direction: 0
|
||||
speedIncrease: 1
|
||||
isLit: 0
|
||||
damageSfx: {fileID: 701875523}
|
||||
camera: {fileID: 85715039}
|
||||
--- !u!65 &1153618774
|
||||
BoxCollider:
|
||||
@@ -7597,6 +7726,7 @@ Transform:
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 765275277}
|
||||
- {fileID: 701875522}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 3
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
||||
@@ -327,7 +327,7 @@ RectTransform:
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 20, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
@@ -858,7 +858,7 @@ RectTransform:
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_SizeDelta: {x: 10, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
@@ -998,7 +998,7 @@ GameObject:
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &1607933371
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -1213,7 +1213,7 @@ MonoBehaviour:
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_text: Creative and unique game title
|
||||
m_text: Lightcycle
|
||||
m_isRightToLeft: 0
|
||||
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
|
||||
m_sharedMaterial: {fileID: 2100000, guid: e73a58f6e2794ae7b1b7e50b7fb811b0, type: 2}
|
||||
@@ -1306,7 +1306,7 @@ GameObject:
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &1706518355
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
||||
@@ -68,7 +68,7 @@ public class ScoreboardManager : MonoBehaviour
|
||||
form.AddField("username", username);
|
||||
form.AddField("score", playerScore);
|
||||
form.AddField("additional_data", additional_data);
|
||||
using (UnityWebRequest www = UnityWebRequest.Post("http://vps5.minzkraut.com:3030/scores", form))
|
||||
using (UnityWebRequest www = UnityWebRequest.Post("https://bhj22sb.minzkraut.com/scores", form))
|
||||
{
|
||||
yield return www.SendWebRequest();
|
||||
|
||||
@@ -89,7 +89,7 @@ public class ScoreboardManager : MonoBehaviour
|
||||
|
||||
IEnumerator GetScores()
|
||||
{
|
||||
using (UnityWebRequest webRequest = UnityWebRequest.Get("http://vps5.minzkraut.com:3030/scores"))
|
||||
using (UnityWebRequest webRequest = UnityWebRequest.Get("https://bhj22sb.minzkraut.com/scores"))
|
||||
{
|
||||
// Request and wait for the desired page.
|
||||
yield return webRequest.SendWebRequest();
|
||||
|
||||
@@ -13,6 +13,7 @@ public class Player : MonoBehaviour
|
||||
public List<ParticleCollisionEvent> collisionEvents;
|
||||
public float speedIncrease;
|
||||
public bool isLit;
|
||||
public AudioSource damageSfx;
|
||||
|
||||
public Camera camera;
|
||||
|
||||
@@ -65,6 +66,7 @@ public class Player : MonoBehaviour
|
||||
if (isLit && Time.timeSinceLevelLoad > 2)
|
||||
{
|
||||
health -= 100.0f * Time.deltaTime;
|
||||
damageSfx.Play();
|
||||
}
|
||||
|
||||
//if health below 0 die
|
||||
|
||||
BIN
Assets/Sfx/Damaged.wav
(Stored with Git LFS)
Normal file
BIN
Assets/Sfx/Damaged.wav
(Stored with Git LFS)
Normal file
Binary file not shown.
22
Assets/Sfx/Damaged.wav.meta
Normal file
22
Assets/Sfx/Damaged.wav.meta
Normal file
@@ -0,0 +1,22 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9f3c3c28564416d49b2e71899119032d
|
||||
AudioImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 6
|
||||
defaultSettings:
|
||||
loadType: 0
|
||||
sampleRateSetting: 0
|
||||
sampleRateOverride: 44100
|
||||
compressionFormat: 1
|
||||
quality: 1
|
||||
conversionMode: 0
|
||||
platformSettingOverrides: {}
|
||||
forceToMono: 0
|
||||
normalize: 1
|
||||
preloadAudioData: 1
|
||||
loadInBackground: 0
|
||||
ambisonic: 0
|
||||
3D: 1
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
8
Assets/WebGLTemplates.meta
Normal file
8
Assets/WebGLTemplates.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1683f91108c55e34d8eb6a1776baadb2
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
8
Assets/WebGLTemplates/BetterMinimal.meta
Normal file
8
Assets/WebGLTemplates/BetterMinimal.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 74e94c2985aadd94db8ae257dd4799c9
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
110
Assets/WebGLTemplates/BetterMinimal/index.html
Normal file
110
Assets/WebGLTemplates/BetterMinimal/index.html
Normal file
@@ -0,0 +1,110 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en-us">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<title>{{{ PRODUCT_NAME }}}</title>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
background: {{{ BACKGROUND || '#000' }}};
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow: visible;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
div#gameContainer {
|
||||
background: transparent !important;
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
div#gameContainer canvas {
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
div#gameContainer canvas[data-pixel-art="true"] {
|
||||
position: absolute;
|
||||
image-rendering: optimizeSpeed;
|
||||
image-rendering: -webkit-crisp-edges;
|
||||
image-rendering: -moz-crisp-edges;
|
||||
image-rendering: -o-crisp-edges;
|
||||
image-rendering: crisp-edges;
|
||||
image-rendering: -webkit-optimize-contrast;
|
||||
image-rendering: optimize-contrast;
|
||||
image-rendering: pixelated;
|
||||
-ms-interpolation-mode: nearest-neighbor;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="gameContainer">
|
||||
<canvas id="unity-canvas" data-pixel-art="{{{ OPTIMIZE_FOR_PIXEL_ART }}}"></canvas>
|
||||
<script src="Build/{{{ LOADER_FILENAME }}}"></script>
|
||||
<script>
|
||||
var canvas = document.querySelector("#unity-canvas");
|
||||
var config = {
|
||||
dataUrl: "Build/{{{ DATA_FILENAME }}}",
|
||||
frameworkUrl: "Build/{{{ FRAMEWORK_FILENAME }}}",
|
||||
codeUrl: "Build/{{{ CODE_FILENAME }}}",
|
||||
#if MEMORY_FILENAME
|
||||
memoryUrl: "Build/{{{ MEMORY_FILENAME }}}",
|
||||
#endif
|
||||
#if SYMBOLS_FILENAME
|
||||
symbolsUrl: "Build/{{{ SYMBOLS_FILENAME }}}",
|
||||
#endif
|
||||
streamingAssetsUrl: "StreamingAssets",
|
||||
companyName: "{{{ COMPANY_NAME }}}",
|
||||
productName: "{{{ PRODUCT_NAME }}}",
|
||||
productVersion: "{{{ PRODUCT_VERSION }}}",
|
||||
};
|
||||
var scaleToFit;
|
||||
try {
|
||||
scaleToFit = !!JSON.parse("{{{ SCALE_TO_FIT }}}");
|
||||
} catch (e) {
|
||||
scaleToFit = true;
|
||||
}
|
||||
function progressHandler(progress) {
|
||||
var percent = progress * 100 + '%';
|
||||
canvas.style.background = 'linear-gradient(to right, white, white ' + percent + ', transparent ' + percent + ', transparent) no-repeat center';
|
||||
canvas.style.backgroundSize = '100% 1rem';
|
||||
}
|
||||
function onResize() {
|
||||
var container = canvas.parentElement;
|
||||
var w;
|
||||
var h;
|
||||
|
||||
if (scaleToFit) {
|
||||
w = window.innerWidth;
|
||||
h = window.innerHeight;
|
||||
|
||||
var r = {{{ HEIGHT }}} / {{{ WIDTH }}};
|
||||
|
||||
if (w * r > window.innerHeight) {
|
||||
w = Math.min(w, Math.ceil(h / r));
|
||||
}
|
||||
h = Math.floor(w * r);
|
||||
} else {
|
||||
w = {{{ WIDTH }}};
|
||||
h = {{{ HEIGHT }}};
|
||||
}
|
||||
|
||||
container.style.width = canvas.style.width = w + "px";
|
||||
container.style.height = canvas.style.height = h + "px";
|
||||
container.style.top = Math.floor((window.innerHeight - h) / 2) + "px";
|
||||
container.style.left = Math.floor((window.innerWidth - w) / 2) + "px";
|
||||
}
|
||||
createUnityInstance(canvas, config, progressHandler).then(function (instance) {
|
||||
canvas = instance.Module.canvas;
|
||||
onResize();
|
||||
});
|
||||
window.addEventListener('resize', onResize);
|
||||
onResize();
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
7
Assets/WebGLTemplates/BetterMinimal/index.html.meta
Normal file
7
Assets/WebGLTemplates/BetterMinimal/index.html.meta
Normal file
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 37a9d5a027433fa48bfd3747e2ae1e4e
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
BIN
Assets/WebGLTemplates/BetterMinimal/thumbnail.png
(Stored with Git LFS)
Normal file
BIN
Assets/WebGLTemplates/BetterMinimal/thumbnail.png
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/WebGLTemplates/BetterMinimal/thumbnail.png.meta
Normal file
7
Assets/WebGLTemplates/BetterMinimal/thumbnail.png.meta
Normal file
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5b2f040f7cf80dc4b992608533c3255e
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -431,7 +431,10 @@ PlayerSettings:
|
||||
openGLRequireES31: 0
|
||||
openGLRequireES31AEP: 0
|
||||
openGLRequireES32: 0
|
||||
m_TemplateCustomTags: {}
|
||||
m_TemplateCustomTags:
|
||||
BACKGROUND:
|
||||
OPTIMIZE_FOR_PIXEL_ART:
|
||||
SCALE_TO_FIT:
|
||||
mobileMTRendering:
|
||||
Android: 1
|
||||
iPhone: 1
|
||||
@@ -692,7 +695,7 @@ PlayerSettings:
|
||||
webGLDebugSymbols: 0
|
||||
webGLEmscriptenArgs:
|
||||
webGLModulesDirectory:
|
||||
webGLTemplate: APPLICATION:Default
|
||||
webGLTemplate: PROJECT:BetterMinimal
|
||||
webGLAnalyzeBuildSize: 0
|
||||
webGLUseEmbeddedResources: 0
|
||||
webGLCompressionFormat: 1
|
||||
|
||||
Reference in New Issue
Block a user