Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
tetra-tower
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Oenos
tetra-tower
Commits
8230759b
Commit
8230759b
authored
Feb 08, 2019
by
18손재민
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'tetra-tower/sound'
parents
c1144fc3
87daab92
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
136 additions
and
2 deletions
+136
-2
Player.prefab
Assets/Prefabs/Characters/Player.prefab
+96
-0
PlayerController.cs
Assets/Scripts/Characters/PlayerController.cs
+10
-2
Sounds.meta
Assets/Sounds.meta
+8
-0
p_movement_1.wav
Assets/Sounds/p_movement_1.wav
+0
-0
p_movement_1.wav.meta
Assets/Sounds/p_movement_1.wav.meta
+22
-0
No files found.
Assets/Prefabs/Characters/Player.prefab
View file @
8230759b
...
@@ -26,6 +26,7 @@ GameObject:
...
@@ -26,6 +26,7 @@ GameObject:
-
component
:
{
fileID
:
114906702720267008
}
-
component
:
{
fileID
:
114906702720267008
}
-
component
:
{
fileID
:
95992411616135034
}
-
component
:
{
fileID
:
95992411616135034
}
-
component
:
{
fileID
:
114880704145925944
}
-
component
:
{
fileID
:
114880704145925944
}
-
component
:
{
fileID
:
82529156342294766
}
m_Layer
:
0
m_Layer
:
0
m_Name
:
Player
m_Name
:
Player
m_TagString
:
Player
m_TagString
:
Player
...
@@ -176,6 +177,101 @@ BoxCollider2D:
...
@@ -176,6 +177,101 @@ BoxCollider2D:
serializedVersion
:
2
serializedVersion
:
2
m_Size
:
{
x
:
0.53
,
y
:
1
}
m_Size
:
{
x
:
0.53
,
y
:
1
}
m_EdgeRadius
:
0
m_EdgeRadius
:
0
---
!u!82
&82529156342294766
AudioSource
:
m_ObjectHideFlags
:
1
m_CorrespondingSourceObject
:
{
fileID
:
0
}
m_PrefabInternal
:
{
fileID
:
100100000
}
m_GameObject
:
{
fileID
:
1623439448163086
}
m_Enabled
:
1
serializedVersion
:
4
OutputAudioMixerGroup
:
{
fileID
:
0
}
m_audioClip
:
{
fileID
:
8300000
,
guid
:
0cf34a382e05cdb4e80c61a05d3d150e
,
type
:
3
}
m_PlayOnAwake
:
1
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!95
&95992411616135034
---
!u!95
&95992411616135034
Animator
:
Animator
:
serializedVersion
:
3
serializedVersion
:
3
...
...
Assets/Scripts/Characters/PlayerController.cs
View file @
8230759b
...
@@ -7,6 +7,7 @@ public class PlayerController : MonoBehaviour
...
@@ -7,6 +7,7 @@ public class PlayerController : MonoBehaviour
{
{
private
Rigidbody2D
rb
;
// RigidBody2D of this game object
private
Rigidbody2D
rb
;
// RigidBody2D of this game object
private
Animator
anim
;
private
Animator
anim
;
private
AudioSource
audio
;
[
SerializeField
]
[
SerializeField
]
private
float
rbGravityScale
;
private
float
rbGravityScale
;
[
SerializeField
]
[
SerializeField
]
...
@@ -64,8 +65,9 @@ public class PlayerController : MonoBehaviour
...
@@ -64,8 +65,9 @@ public class PlayerController : MonoBehaviour
void
Start
()
void
Start
()
{
{
rb
=
gameObject
.
GetComponent
<
Rigidbody2D
>();
rb
=
GetComponent
<
Rigidbody2D
>();
anim
=
GetComponent
<
Animator
>();
anim
=
GetComponent
<
Animator
>();
audio
=
GetComponent
<
AudioSource
>();
}
}
void
Update
()
void
Update
()
...
@@ -100,7 +102,13 @@ public class PlayerController : MonoBehaviour
...
@@ -100,7 +102,13 @@ public class PlayerController : MonoBehaviour
private
void
FixedUpdate
()
private
void
FixedUpdate
()
{
{
isGrounded
=
IsGrounded
();
bool
tmp
=
IsGrounded
();
if
(!
isGrounded
&&
tmp
)
{
audio
.
enabled
=
false
;
audio
.
enabled
=
true
;
}
isGrounded
=
tmp
;
if
(
GameManager
.
gameState
==
GameState
.
Ingame
&&
MapManager
.
isDoorClosing
!=
true
)
if
(
GameManager
.
gameState
==
GameState
.
Ingame
&&
MapManager
.
isDoorClosing
!=
true
)
{
{
...
...
Assets/Sounds.meta
0 → 100644
View file @
8230759b
fileFormatVersion: 2
guid: 9cd5f946de152e342b960f44df8b8628
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Assets/Sounds/p_movement_1.wav
0 → 100644
View file @
8230759b
File added
Assets/Sounds/p_movement_1.wav.meta
0 → 100644
View file @
8230759b
fileFormatVersion: 2
guid: 0cf34a382e05cdb4e80c61a05d3d150e
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:
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment