-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Unity Editor", | ||
"type": "unity", | ||
"path": "/d:/UnityProjects/OpenGOAP/Library/EditorInstance.json", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "Windows Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "OSX Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "Linux Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "iOS Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "Android Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "Xbox One Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "PS4 Player", | ||
"type": "unity", | ||
"request": "launch" | ||
}, | ||
{ | ||
"name": "SwitchPlayer", | ||
"type": "unity", | ||
"request": "launch" | ||
} | ||
] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System.Collections; | ||
using System.Collections.Generic; | ||
using UnityEngine; | ||
|
||
public class Actor : Detectable | ||
{ | ||
/** | ||
* Class that can use SmartObjects | ||
*/ | ||
|
||
protected List<SmartObject> inventory; | ||
|
||
protected override void Start(){ | ||
base.Start(); | ||
inventory = new List<SmartObject>(); | ||
} | ||
|
||
public virtual void PickUp(SmartObject obj){ | ||
inventory.Add(obj); | ||
obj.PickedUp(); | ||
} | ||
public virtual void PutDown(SmartObject obj){ | ||
inventory.Remove(obj); | ||
obj.PutDown(); | ||
} | ||
public virtual void AddTo(SmartObject obj, SmartObject objToAdd){ | ||
inventory.Remove(objToAdd); | ||
obj.Add(objToAdd); | ||
} | ||
|
||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
using UnityEngine; | ||
|
||
public interface IActor | ||
{ | ||
void PickUp(SmartObject obj); | ||
void PutDown(SmartObject obj); | ||
void AddTo(SmartObject obj, SmartObject objToAdd); | ||
|
||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
%YAML 1.1 | ||
%TAG !u! tag:unity3d.com,2011: | ||
--- !u!21 &2100000 | ||
Material: | ||
serializedVersion: 6 | ||
m_ObjectHideFlags: 0 | ||
m_CorrespondingSourceObject: {fileID: 0} | ||
m_PrefabInstance: {fileID: 0} | ||
m_PrefabAsset: {fileID: 0} | ||
m_Name: Terrain | ||
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0} | ||
m_ShaderKeywords: | ||
m_LightmapFlags: 4 | ||
m_EnableInstancingVariants: 0 | ||
m_DoubleSidedGI: 0 | ||
m_CustomRenderQueue: -1 | ||
stringTagMap: {} | ||
disabledShaderPasses: [] | ||
m_SavedProperties: | ||
serializedVersion: 3 | ||
m_TexEnvs: | ||
- _BumpMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _DetailAlbedoMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _DetailMask: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _DetailNormalMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _EmissionMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _MainTex: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _MetallicGlossMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _OcclusionMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
- _ParallaxMap: | ||
m_Texture: {fileID: 0} | ||
m_Scale: {x: 1, y: 1} | ||
m_Offset: {x: 0, y: 0} | ||
m_Ints: [] | ||
m_Floats: | ||
- _BumpScale: 1 | ||
- _Cutoff: 0.5 | ||
- _DetailNormalMapScale: 1 | ||
- _DstBlend: 0 | ||
- _GlossMapScale: 1 | ||
- _Glossiness: 0.5 | ||
- _GlossyReflections: 1 | ||
- _Metallic: 0 | ||
- _Mode: 0 | ||
- _OcclusionStrength: 1 | ||
- _Parallax: 0.02 | ||
- _SmoothnessTextureChannel: 0 | ||
- _SpecularHighlights: 1 | ||
- _SrcBlend: 1 | ||
- _UVSec: 0 | ||
- _ZWrite: 1 | ||
m_Colors: | ||
- _Color: {r: 0, g: 0, b: 0, a: 1} | ||
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1} | ||
m_BuildTextureStacks: [] |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using UnityEngine; | ||
|
||
public interface ISmartObject | ||
{ | ||
void PickedUp(){} | ||
void PutDown(){} | ||
void Add(SmartObject obj){} | ||
void Remove(){} | ||
|
||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
using System.Collections; | ||
using System.Collections.Generic; | ||
using UnityEngine; | ||
|
||
public class SmartObject : Detectable, ISmartObject | ||
{ | ||
Renderer rend; | ||
protected override void Start() | ||
{ | ||
base.Start(); | ||
rend = GetComponent<Renderer>(); | ||
} | ||
|
||
public virtual void PickedUp(){ | ||
rend.enabled = false; | ||
} | ||
|
||
public virtual void PutDown(){ | ||
rend.enabled = true; | ||
} | ||
|
||
public virtual void Add(SmartObject obj){} | ||
|
||
public virtual void Remove(){ | ||
Destroy(this); | ||
} | ||
|
||
} |