Skip to content

Commit

Permalink
wrote how to build app, changed unity version to most recent
Browse files Browse the repository at this point in the history
  • Loading branch information
Pietrek14 committed Mar 5, 2022
1 parent 2751ef1 commit b26c215
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 35 deletions.
38 changes: 31 additions & 7 deletions Assets/Resources/Scripts/PlayerControls.cs
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
// GENERATED AUTOMATICALLY FROM 'Assets/Resources/InputActions/PlayerControls.inputactions'
//------------------------------------------------------------------------------
// <auto-generated>
// This code was auto-generated by com.unity.inputsystem:InputActionCodeGenerator
// version 1.3.0
// from Assets/Resources/InputActions/PlayerControls.inputactions
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine.InputSystem;
using UnityEngine.InputSystem.Utilities;

public class @PlayerControls : IInputActionCollection, IDisposable
public partial class @PlayerControls : IInputActionCollection2, IDisposable
{
public InputActionAsset asset { get; }
public @PlayerControls()
Expand All @@ -24,15 +33,17 @@ public @PlayerControls()
""id"": ""65745c6f-bddd-446d-a9b7-6505ef3a4989"",
""expectedControlType"": ""Button"",
""processors"": """",
""interactions"": """"
""interactions"": """",
""initialStateCheck"": false
},
{
""name"": ""Move"",
""type"": ""Value"",
""id"": ""2bc67559-6eb1-4ded-8097-822fb12b7d64"",
""expectedControlType"": ""Vector2"",
""processors"": """",
""interactions"": """"
""interactions"": """",
""initialStateCheck"": true
}
],
""bindings"": [
Expand Down Expand Up @@ -202,23 +213,26 @@ public @PlayerControls()
""id"": ""4b483e7f-ae08-4901-b07b-cd51f90fee81"",
""expectedControlType"": ""Button"",
""processors"": """",
""interactions"": """"
""interactions"": """",
""initialStateCheck"": false
},
{
""name"": ""Restart"",
""type"": ""Button"",
""id"": ""7002d68c-73e9-40c6-9321-d25c391841af"",
""expectedControlType"": ""Button"",
""processors"": """",
""interactions"": """"
""interactions"": """",
""initialStateCheck"": false
},
{
""name"": ""NextLevel"",
""type"": ""Button"",
""id"": ""6daffcf9-f5b0-44cc-ae15-041b5f243d1e"",
""expectedControlType"": ""Button"",
""processors"": """",
""interactions"": """"
""interactions"": """",
""initialStateCheck"": false
}
],
""bindings"": [
Expand Down Expand Up @@ -347,6 +361,16 @@ public void Disable()
{
asset.Disable();
}
public IEnumerable<InputBinding> bindings => asset.bindings;

public InputAction FindAction(string actionNameOrId, bool throwIfNotFound = false)
{
return asset.FindAction(actionNameOrId, throwIfNotFound);
}
public int FindBinding(InputBinding bindingMask, out InputAction action)
{
return asset.FindBinding(bindingMask, out action);
}

// Gameplay
private readonly InputActionMap m_Gameplay;
Expand Down
12 changes: 6 additions & 6 deletions Packages/manifest.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{
"dependencies": {
"com.unity.2d.animation": "5.0.9",
"com.unity.2d.animation": "5.1.0",
"com.unity.2d.pixel-perfect": "4.0.1",
"com.unity.2d.psdimporter": "4.1.2",
"com.unity.2d.psdimporter": "4.2.0",
"com.unity.2d.sprite": "1.0.0",
"com.unity.2d.spriteshape": "5.1.5",
"com.unity.2d.spriteshape": "5.2.0",
"com.unity.2d.tilemap": "1.0.0",
"com.unity.collab-proxy": "1.13.5",
"com.unity.collab-proxy": "1.15.12",
"com.unity.ide.rider": "2.0.7",
"com.unity.ide.visualstudio": "2.0.11",
"com.unity.ide.visualstudio": "2.0.14",
"com.unity.ide.vscode": "1.2.4",
"com.unity.inputsystem": "1.0.2",
"com.unity.inputsystem": "1.3.0",
"com.unity.test-framework": "1.1.29",
"com.unity.textmeshpro": "3.0.6",
"com.unity.timeline": "1.4.8",
Expand Down
34 changes: 14 additions & 20 deletions Packages/packages-lock.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"dependencies": {
"com.unity.2d.animation": {
"version": "5.0.9",
"version": "5.1.0",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.2d.common": "4.0.3",
"com.unity.2d.common": "4.1.0",
"com.unity.mathematics": "1.1.0",
"com.unity.2d.sprite": "1.0.0",
"com.unity.modules.animation": "1.0.0",
Expand All @@ -14,7 +14,7 @@
"url": "https://packages.unity.com"
},
"com.unity.2d.common": {
"version": "4.0.3",
"version": "4.1.0",
"depth": 1,
"source": "registry",
"dependencies": {
Expand All @@ -38,12 +38,12 @@
"url": "https://packages.unity.com"
},
"com.unity.2d.psdimporter": {
"version": "4.1.2",
"version": "4.2.0",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.2d.common": "4.0.3",
"com.unity.2d.animation": "5.0.9",
"com.unity.2d.common": "4.1.0",
"com.unity.2d.animation": "5.1.0",
"com.unity.2d.sprite": "1.0.0"
},
"url": "https://packages.unity.com"
Expand All @@ -55,12 +55,12 @@
"dependencies": {}
},
"com.unity.2d.spriteshape": {
"version": "5.1.5",
"version": "5.2.0",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.mathematics": "1.1.0",
"com.unity.2d.common": "4.0.3",
"com.unity.2d.common": "4.1.0",
"com.unity.2d.path": "4.0.2",
"com.unity.modules.physics2d": "1.0.0"
},
Expand All @@ -73,11 +73,10 @@
"dependencies": {}
},
"com.unity.collab-proxy": {
"version": "1.13.5",
"version": "1.15.12",
"depth": 0,
"source": "registry",
"dependencies": {
"com.unity.nuget.newtonsoft-json": "2.0.0",
"com.unity.services.core": "1.0.1"
},
"url": "https://packages.unity.com"
Expand All @@ -99,7 +98,7 @@
"url": "https://packages.unity.com"
},
"com.unity.ide.visualstudio": {
"version": "2.0.11",
"version": "2.0.14",
"depth": 0,
"source": "registry",
"dependencies": {
Expand All @@ -115,10 +114,12 @@
"url": "https://packages.unity.com"
},
"com.unity.inputsystem": {
"version": "1.0.2",
"version": "1.3.0",
"depth": 0,
"source": "registry",
"dependencies": {},
"dependencies": {
"com.unity.modules.uielements": "1.0.0"
},
"url": "https://packages.unity.com"
},
"com.unity.mathematics": {
Expand All @@ -128,13 +129,6 @@
"dependencies": {},
"url": "https://packages.unity.com"
},
"com.unity.nuget.newtonsoft-json": {
"version": "2.0.0",
"depth": 1,
"source": "registry",
"dependencies": {},
"url": "https://packages.unity.com"
},
"com.unity.services.core": {
"version": "1.0.1",
"depth": 1,
Expand Down
4 changes: 2 additions & 2 deletions ProjectSettings/ProjectVersion.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
m_EditorVersion: 2020.3.22f1
m_EditorVersionWithRevision: 2020.3.22f1 (e1a7f79fd887)
m_EditorVersion: 2020.3.30f1
m_EditorVersionWithRevision: 2020.3.30f1 (1fb1bf06830e)
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

Jest to nasza wersja gry Pang, stworzona w silniku Unity. Gra polega na niszczeniu skaczących piłek. Składa się z trzech modułów, zrealizowanych zgodnie ze specyfikacją.

## Proces budowania aplikacji
Do zbudowania aplikacji potrzebne jest środowisko Unity, dostępne przez platformę Unity Hub. Unity Hub jest dostępne do pobrania za darmo pod [tym adresem](https://unity.com/download) (należy nacisnąć przycisk "Download for Windows"). Następnie należy uruchomić instalator. Po zaakceptowaniu umowy licencyjnej można wybrać folder docelowy instalacji Unity Hub, a następnie wcisnąć przycisk "Zainstaluj". Po uruchomieniu Unity Hub należy wejść w zakładkę "Installs" po lewej stronie. W prawym gónym rogu pojawi się przycisk "Add". Po naciśnięciu na niego, program poprosi nas o wybranie wersji Unity, którą chcemy zainstalować. Wybieramy wersję Unity 2020.3.30f1, następnie naciskamy przycisk "Next". W następnym menu możemy odznaczyć wszystkie opcje poza "Windows Build Support (IL2CPP)" oraz wcisnąć przycisk "Done". Rozpocznie się instalacja Unity.

Po zainstalowaniu Unity należy wrócić do zakładki "Projects" (po lewej stronie). W prawym górnym rogu znajduje się przycisk "Add". Po wciśnięciu go program poprosi nas o wybranie folderu. Podajemy folder, w którym znajduje się kod źródłowy Panga. Na liście projektów pojawi się nowy projekt o nazwie "pang". Otwieramy go przez kliknięcie.

Po otwarciu projektu wchodzimy w menu "File" widoczne w lewym górnym rogu, a następnie wybieramy "Build And Run". Alternatywnie można zastosować skrót klawiszowy **Ctrl + B**. Podajemy folder, do któego ma zostać zbudowana aplikacja. Po zbudowaniu, aplikacja uruchomi sie automatycznie.

## Sterowanie

Gra obsługuje wejście z klawiatury oraz kontrolera do gier.
Expand Down

0 comments on commit b26c215

Please sign in to comment.