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
338dc35a
Commit
338dc35a
authored
Feb 13, 2019
by
18손재민
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
머지함
parent
49c2853e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
6 deletions
+10
-6
Player animator.controller
Assets/Animation/Player/Player animator.controller
+1
-1
PlayerIcon.prefab
Assets/Prefabs/TetrisMap/PlayerIcon.prefab
+1
-1
PlayScene.unity
Assets/Scenes/PlayScene.unity
+5
-0
PlayerController.cs
Assets/Scripts/Characters/PlayerController.cs
+3
-4
No files found.
Assets/Animation/Player/Player animator.controller
View file @
338dc35a
...
@@ -564,7 +564,7 @@ AnimatorState:
...
@@ -564,7 +564,7 @@ AnimatorState:
m_IKOnFeet
:
0
m_IKOnFeet
:
0
m_WriteDefaultValues
:
1
m_WriteDefaultValues
:
1
m_Mirror
:
0
m_Mirror
:
0
m_SpeedParameterActive
:
0
m_SpeedParameterActive
:
1
m_MirrorParameterActive
:
0
m_MirrorParameterActive
:
0
m_CycleOffsetParameterActive
:
0
m_CycleOffsetParameterActive
:
0
m_TimeParameterActive
:
0
m_TimeParameterActive
:
0
...
...
Assets/Prefabs/TetrisMap/PlayerIcon.prefab
View file @
338dc35a
...
@@ -34,7 +34,7 @@ Transform:
...
@@ -34,7 +34,7 @@ Transform:
m_PrefabInternal
:
{
fileID
:
100100000
}
m_PrefabInternal
:
{
fileID
:
100100000
}
m_GameObject
:
{
fileID
:
1704656476422024
}
m_GameObject
:
{
fileID
:
1704656476422024
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
-0
,
w
:
1
}
m_LocalRotation
:
{
x
:
-0
,
y
:
-0
,
z
:
-0
,
w
:
1
}
m_LocalPosition
:
{
x
:
48
,
y
:
0
,
z
:
-2
}
m_LocalPosition
:
{
x
:
96
,
y
:
0
,
z
:
-2
}
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_Children
:
[]
m_Children
:
[]
m_Father
:
{
fileID
:
0
}
m_Father
:
{
fileID
:
0
}
...
...
Assets/Scenes/PlayScene.unity
View file @
338dc35a
...
@@ -997,6 +997,11 @@ Prefab:
...
@@ -997,6 +997,11 @@ Prefab:
value
:
value
:
objectReference
:
{
fileID
:
11400000
,
guid
:
b556ab3a4d3d2db4b89081d94cca006c
,
objectReference
:
{
fileID
:
11400000
,
guid
:
b556ab3a4d3d2db4b89081d94cca006c
,
type
:
2
}
type
:
2
}
-
target
:
{
fileID
:
114144154128578016
,
guid
:
afe4a2cb44239b649a3ffa70af5c2d84
,
type
:
2
}
propertyPath
:
timeToFallTetrimino
value
:
5
objectReference
:
{
fileID
:
0
}
m_RemovedComponents
:
[]
m_RemovedComponents
:
[]
m_SourcePrefab
:
{
fileID
:
100100000
,
guid
:
afe4a2cb44239b649a3ffa70af5c2d84
,
type
:
2
}
m_SourcePrefab
:
{
fileID
:
100100000
,
guid
:
afe4a2cb44239b649a3ffa70af5c2d84
,
type
:
2
}
m_IsPrefabAsset
:
0
m_IsPrefabAsset
:
0
...
...
Assets/Scripts/Characters/PlayerController.cs
View file @
338dc35a
...
@@ -116,12 +116,12 @@ public class PlayerController : MonoBehaviour
...
@@ -116,12 +116,12 @@ public class PlayerController : MonoBehaviour
if
(
GameManager
.
gameState
==
GameState
.
Ingame
&&
MapManager
.
isDoorWorking
!=
true
)
if
(
GameManager
.
gameState
==
GameState
.
Ingame
&&
MapManager
.
isDoorWorking
!=
true
)
{
{
/*
if
(
playerState
==
PlayerState
.
Attack
)
if
(
playerState
==
PlayerState
.
Attack
)
{
{
rb.gravityScale = rb
.velocity.y < 0 ? rbAttackGravityScale : rb
GravityScale;
rb
.
gravityScale
=
rbGravityScale
;
}
}
*/
if
(
isGrounded
)
if
(
isGrounded
)
isJumpable
=
true
;
isJumpable
=
true
;
if
(
playerState
!=
PlayerState
.
Attack
)
if
(
playerState
!=
PlayerState
.
Attack
)
...
@@ -230,7 +230,6 @@ public class PlayerController : MonoBehaviour
...
@@ -230,7 +230,6 @@ public class PlayerController : MonoBehaviour
float
xVelocity
=
rb
.
velocity
.
x
;
float
xVelocity
=
rb
.
velocity
.
x
;
float
yVelocity
=
rb
.
velocity
.
y
;
float
yVelocity
=
rb
.
velocity
.
y
;
float
airResistance
=
isGrounded
?
1f
:
0.5f
;
float
airResistance
=
isGrounded
?
1f
:
0.5f
;
playerState
=
PlayerState
.
Idle
;
float
direction
=
Mathf
.
Sign
(
xVelocity
);
float
direction
=
Mathf
.
Sign
(
xVelocity
);
xVelocity
=
Mathf
.
Abs
(
xVelocity
)
-
deceleration
*
airResistance
*
Time
.
fixedDeltaTime
;
xVelocity
=
Mathf
.
Abs
(
xVelocity
)
-
deceleration
*
airResistance
*
Time
.
fixedDeltaTime
;
if
(
xVelocity
<
0
)
xVelocity
=
0
;
if
(
xVelocity
<
0
)
xVelocity
=
0
;
...
...
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