Unverified Commit 310f5c88 authored by Geri's avatar Geri Committed by GitHub
Browse files

Add files via upload

parent 82aab308
Loading
Loading
Loading
Loading

LICENSE.md

0 → 100644
+19 −0
Original line number Diff line number Diff line
Copyright (c) 2021 Geri

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

LICENSE.md.meta

0 → 100644
+7 −0
Original line number Diff line number Diff line
fileFormatVersion: 2
guid: 535f36a1918d4d2479031f3ca2725323
TextScriptImporter:
  externalObjects: {}
  userData: 
  assetBundleName: 
  assetBundleVariant: 

README.md

0 → 100644
+92 −0
Original line number Diff line number Diff line
# Simple Tools

## Features

- **AudioManager** with Play, Pause and most of the other basic things, as well as some effects like FadeIn or FadeOut.
- Some Cinemachine tools for making a **camera trigger** and an easy way for creating a **screen shake camera.**
- Basic **dialogue system** that works with TextMeshPro.
- Basic menu with **music and SFX sliders** as well as **resolution and quality dropdowns.**
- An **object pooler** with the ability to create pools with an undetermined size.
- A basic **scene manager** with a loading screen with progress bar.

All of that comes with some editor menu items for creating all of that as fast as possible.

## How to install

First install the TextMeshPro and Cinemachine into your Unity project

### Git Installation (Best way to get latest version)

If you have git in your computer, you can open Package Manager inside Unity, select "Add package from Git url...", and paste link [https://github.com/IntoTheDev/Save-System-for-Unity.git](https://github.com/IntoTheDev/Save-System-for-Unity.git)

or

Open the manifest.json file of your Unity project. Add "com.geri.simpletools": "[https://github.com/IntoTheDev/Save-System-for-Unity.git](https://github.com/IntoTheDev/Save-System-for-Unity.git)"

### Manual Installation

Download latest package from the Release section Import SimpleTools.unitypackage to your Unity Project

## Usage

### AudioManager

```csharp
AudioManager.instance.Play("Name"); //Plays the sound with that name
AudioManager.instance.Play("Name", 1f); //Starts playing the sound "Name" in 1 second
AudioManager.instance.PlayOneShot("Name"); //Plays one shot of that sound (Useful for repeated sounds)

AudioManager.instance.Pause("Name"); //Pauses the sound
AudioManager.instance.UnPause("Name"); //Unpauses the sound

AudioManager.instance.Stop("Name"); //Stops the sound
AudioManager.instance.StopAll(); //Stops all the sounds that are being played

AudioManager.instance.GetSource("Name"); //Gets the AudioSource with that name

AudioManager.instance.FadeIn("Name", 1f); //Fade In the source with a specific duration
AudioManager.instance.FadeOut("Name", 1f); //Fade Out the source with a specific duration

AudioManager.instance.PlayMuted("Name"); //Play a sound muted
AudioManager.instance.FadeMutedIn("Name", 1f); //Fade In a muted sound with a specific duration
AudioManager.instance.FadeMutedOut("Name", 1f); //Fade Out a sound without stopping it
```

### ObjectPooler

The SpawnFromPool function always return a GameObject

```csharp
Pool pool; //The pool scriptable object goes here
Pooler.CreatePools(pool); //Create the pool, without creating it you cannot spawn it
Pool[] pools;
Pooler.CreatePools(pools); //Create multiple pools
Pooler.SpawnFromPool("Name", Vector3.zero); //Spawns an object into a specific position
Pooler.SpawnFromPool("Name", Vector3.zero, Quaternion.identity); //Spawn into a specific position and rotation
Pooler.SpawnFromPool("Name", Vector3.zero, transform); //Spawn into a specific position and parent
Pooler.SpawnFromPool("Name", Vector3.zero, Quaternion.identity, transform); //Spawn into a specific position, rotation and parent
Pooler.SpawnFromPool("Name", Vector3.zero, transform, true); //Spawn into a specific position, parent and instantiate in worldSpace or not
Pooler.SpawnFromPool("Name", Vector3.zero, Quaternion.identity, transform, true); //Spawn into a specific position, rotation, parent and instantiate in worldSpace or not
```

### Dialogue System

The Dialogue function returns a bool (true if it's talking, false if it has ended)

```csharp
Dialogue dialogue; //The dialogue scriptable object goes here
DialogueSystem.instance.Dialogue(dialogue); //Start/Continue the dialogue
```

### SceneManager

```csharp
Loader.Load(0); //Loads a scene with a specific build index
Loader.Load("Scene"); //Loads a scene with a specific name
```

### ScreenShake

```csharp
ScreenShake.Shake(1f, .25f); //Shakes the camera with an intensity and duration
```
 No newline at end of file

README.md.meta

0 → 100644
+7 −0
Original line number Diff line number Diff line
fileFormatVersion: 2
guid: e9c1d398f3d17184a97bce327ff06621
TextScriptImporter:
  externalObjects: {}
  userData: 
  assetBundleName: 
  assetBundleVariant: 

Tools.meta

0 → 100644
+8 −0
Original line number Diff line number Diff line
fileFormatVersion: 2
guid: 78a1b199ab0716542b34cc9a3dd3a9df
folderAsset: yes
DefaultImporter:
  externalObjects: {}
  userData: 
  assetBundleName: 
  assetBundleVariant: 
Loading