Skip to content

Commit 14f34c7

Browse files
authored
Merge pull request #164 from oneleif/master
version 0.5.0
2 parents 05996c7 + b80972c commit 14f34c7

File tree

267 files changed

+107349
-93303
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

267 files changed

+107349
-93303
lines changed

.github/workflows/CD_Linux.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: 📦 Linux
2+
3+
on:
4+
pull_request: { branches: [master] }
5+
push: { branches: [development] }
6+
7+
env:
8+
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
9+
10+
jobs:
11+
readmeWorkflow:
12+
name: Build Linux
13+
runs-on: ubuntu-latest
14+
steps:
15+
# Checkout
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
with:
19+
lfs: true
20+
21+
# Test
22+
- name: Run tests
23+
uses: webbertakken/[email protected]
24+
with:
25+
projectPath: BunnyHopMaster
26+
unityVersion: 2019.3.9f1
27+
28+
# Build
29+
- name: Build project
30+
uses: webbertakken/[email protected]
31+
with:
32+
projectPath: BunnyHopMaster
33+
unityVersion: 2019.3.9f1
34+
targetPlatform: StandaloneLinux64
35+
36+
# Output
37+
- uses: actions/upload-artifact@v1
38+
with:
39+
name: LinuxBuild
40+
path: build
41+

.github/workflows/CD_MacOS.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: 📦 MacOS
2+
3+
on:
4+
pull_request: { branches: [master] }
5+
push: { branches: [development] }
6+
7+
env:
8+
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
9+
10+
jobs:
11+
readmeWorkflow:
12+
name: Build MacOS
13+
runs-on: ubuntu-latest
14+
steps:
15+
# Checkout
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
with:
19+
lfs: true
20+
21+
# Test
22+
- name: Run tests
23+
uses: webbertakken/[email protected]
24+
with:
25+
projectPath: BunnyHopMaster
26+
unityVersion: 2019.3.9f1
27+
28+
# Build
29+
- name: Build project
30+
uses: webbertakken/[email protected]
31+
with:
32+
projectPath: BunnyHopMaster
33+
unityVersion: 2019.3.9f1
34+
targetPlatform: StandaloneOSX
35+
36+
# Output
37+
- uses: actions/upload-artifact@v1
38+
with:
39+
name: MacOSBuild
40+
path: build
41+

.github/workflows/CD_Windows.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: 📦 Windows
2+
3+
on:
4+
pull_request: { branches: [master] }
5+
push: { branches: [development] }
6+
7+
env:
8+
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
9+
10+
jobs:
11+
readmeWorkflow:
12+
name: Build Windows
13+
runs-on: ubuntu-latest
14+
steps:
15+
# Checkout
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
with:
19+
lfs: true
20+
21+
# Test
22+
- name: Run tests
23+
uses: webbertakken/[email protected]
24+
with:
25+
projectPath: BunnyHopMaster
26+
unityVersion: 2019.3.9f1
27+
28+
# Build
29+
- name: Build project
30+
uses: webbertakken/[email protected]
31+
with:
32+
projectPath: BunnyHopMaster
33+
unityVersion: 2019.3.9f1
34+
targetPlatform: StandaloneWindows64
35+
36+
# Output
37+
- uses: actions/upload-artifact@v1
38+
with:
39+
name: WindowsBuild
40+
path: build
41+
42+

.github/workflows/CI.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: 🧪 Unity
2+
3+
on: [push]
4+
5+
env:
6+
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
7+
8+
jobs:
9+
readmeWorkflow:
10+
name: Test Workflow
11+
runs-on: ubuntu-latest
12+
steps:
13+
# Checkout
14+
- name: Checkout repository
15+
uses: actions/checkout@v2
16+
with:
17+
lfs: true
18+
19+
# Test
20+
- name: Run tests
21+
uses: webbertakken/[email protected]
22+
with:
23+
projectPath: BunnyHopMaster
24+
unityVersion: 2019.3.9f1
25+

.github/workflows/activation.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Acquire activation file
2+
3+
on: [push]
4+
5+
jobs:
6+
activation:
7+
name: Request manual activation file 🔑
8+
runs-on: ubuntu-latest
9+
steps:
10+
11+
# Request manual activation file
12+
- name: Request manual activation file
13+
id: getManualLicenseFile
14+
uses: webbertakken/[email protected]
15+
with:
16+
unityVersion: 2019.3.9f1
17+
18+
# Upload artifact (Unity_v20XX.X.XXXX.alf)
19+
- name: Expose as artifact
20+
uses: actions/upload-artifact@v1
21+
with:
22+
name: ${{ steps.getManualLicenseFile.outputs.filePath }}
23+
path: ${{ steps.getManualLicenseFile.outputs.filePath }}

.github/workflows/artifacts/.init

Whitespace-only changes.
Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
using UnityEditor;
5+
6+
[CustomEditor(typeof(SurfRampMeshGenerator))]
7+
public class CreateSurfRamp : Editor
8+
{
9+
public override void OnInspectorGUI()
10+
{
11+
DrawDefaultInspector();
12+
13+
SurfRampMeshGenerator myScript = (SurfRampMeshGenerator)target;
14+
15+
if (GUILayout.Button("Build Object"))
16+
{
17+
myScript.BuildObject();
18+
}
19+
}
20+
}

BunnyHopMaster/Assets/Editor/CreateSurfRamp.cs.meta

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
using UnityEngine;
2+
using UnityEditor;
3+
4+
public class ReplaceWithPrefab : EditorWindow
5+
{
6+
[SerializeField] private GameObject prefab;
7+
8+
[MenuItem("Tools/Replace With Prefab")]
9+
private static void CreateReplaceWithPrefab()
10+
{
11+
GetWindow<ReplaceWithPrefab>();
12+
}
13+
14+
[System.Obsolete]
15+
private void OnGUI()
16+
{
17+
prefab = (GameObject)EditorGUILayout.ObjectField("Prefab", prefab, typeof(GameObject), false);
18+
19+
if (GUILayout.Button("Replace"))
20+
{
21+
var selection = Selection.gameObjects;
22+
23+
for (var i = selection.Length - 1; i >= 0; --i)
24+
{
25+
var selected = selection[i];
26+
PrefabType prefabType = PrefabUtility.GetPrefabType(prefab);
27+
GameObject newObject;
28+
29+
if (prefabType == PrefabType.Prefab)
30+
{
31+
newObject = (GameObject)PrefabUtility.InstantiatePrefab(prefab);
32+
}
33+
else
34+
{
35+
newObject = Instantiate(prefab);
36+
newObject.name = prefab.name;
37+
}
38+
39+
if (newObject == null)
40+
{
41+
Debug.LogError("Error instantiating prefab");
42+
break;
43+
}
44+
45+
Undo.RegisterCreatedObjectUndo(newObject, "Replace With Prefabs");
46+
newObject.transform.parent = selected.transform.parent;
47+
newObject.transform.localPosition = selected.transform.localPosition;
48+
newObject.transform.localRotation = selected.transform.localRotation;
49+
newObject.transform.localScale = selected.transform.localScale;
50+
newObject.name += " (" + i + ")";
51+
newObject.transform.SetSiblingIndex(selected.transform.GetSiblingIndex());
52+
Undo.DestroyObjectImmediate(selected);
53+
}
54+
}
55+
56+
GUI.enabled = false;
57+
EditorGUILayout.LabelField("Selection count: " + Selection.objects.Length);
58+
}
59+
}

0 commit comments

Comments
 (0)