Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
GalaxySmash
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Hà Trung (NEGAXY)
GalaxySmash
Commits
840b3c08
Commit
840b3c08
authored
Dec 13, 2021
by
Hà Trung (NEGAXY)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Trung: Fix bug
parent
71b8e980
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
3 deletions
+10
-3
ExplosionCount.cs
.../OSG Infinity Square Space/Main/Scripts/ExplosionCount.cs
+1
-1
Controller.cs
...ts/OSG Infinity Square Space/Player/Scripts/Controller.cs
+9
-2
No files found.
Assets/OSG Infinity Square Space/Main/Scripts/ExplosionCount.cs
View file @
840b3c08
...
@@ -82,7 +82,7 @@ public class ExplosionCount : MonoBehaviour
...
@@ -82,7 +82,7 @@ public class ExplosionCount : MonoBehaviour
coll
.
SetActive
(
true
);
coll
.
SetActive
(
true
);
coll
.
transform
.
DOScale
(
80
,
0.4f
);
coll
.
transform
.
DOScale
(
80
,
0.4f
);
InterfaceOperation
.
Instance
.
CheckStar
(
1
);
InterfaceOperation
.
Instance
.
CheckStar
(
1
);
Interface
.
instance
.
healthPlanet
.
fill
.
fillAmount
=
0
;
Interface
.
instance
.
healthPlanet
.
fill
.
fillAmount
=
1f
;
//Interface.instance.healthPlanet.text.text = "0";
//Interface.instance.healthPlanet.text.text = "0";
if
(
DataManager
.
Instance
.
IsVibrationOn
())
if
(
DataManager
.
Instance
.
IsVibrationOn
())
Handheld
.
Vibrate
();
Handheld
.
Vibrate
();
...
...
Assets/OSG Infinity Square Space/Player/Scripts/Controller.cs
View file @
840b3c08
...
@@ -613,6 +613,7 @@ public class Controller : MonoBehaviour
...
@@ -613,6 +613,7 @@ public class Controller : MonoBehaviour
CheckInput
();
CheckInput
();
}
}
private
Vector2
_controlRotation
;
private
Vector2
_controlRotation
;
private
float
rotate_value
=
0f
;
private
void
CheckInput
()
private
void
CheckInput
()
{
{
Vector2
input
=
Interface
.
instance
.
joystick
.
Direction
;
Vector2
input
=
Interface
.
instance
.
joystick
.
Direction
;
...
@@ -630,6 +631,12 @@ public class Controller : MonoBehaviour
...
@@ -630,6 +631,12 @@ public class Controller : MonoBehaviour
SetControlRotation
(
new
Vector2
(
pitchAngle
,
yawAngle
));
SetControlRotation
(
new
Vector2
(
pitchAngle
,
yawAngle
));
transform
.
rotation
=
Quaternion
.
Euler
(
_controlRotation
.
x
,
_controlRotation
.
y
,
0f
);
transform
.
rotation
=
Quaternion
.
Euler
(
_controlRotation
.
x
,
_controlRotation
.
y
,
0f
);
//Vector3 localAngles = currentShip.transform.localEulerAngles.SetZ(input.x * -2f);
//currentShip.transform.rotation = Quaternion.Lerp(currentShip.transform.rotation,
// Quaternion.Euler(localAngles.x, localAngles.y, localAngles.z), Time.deltaTime * 10f);
rotate_value
=
Mathf
.
Lerp
(
rotate_value
,
input
.
x
*
-
4f
,
Time
.
deltaTime
*
10f
);
currentShip
.
transform
.
localEulerAngles
=
currentShip
.
transform
.
localEulerAngles
.
SetZ
(
rotate_value
);
}
}
public
Vector2
GetControlRotation
()
public
Vector2
GetControlRotation
()
{
{
...
@@ -823,7 +830,7 @@ public class Controller : MonoBehaviour
...
@@ -823,7 +830,7 @@ public class Controller : MonoBehaviour
{
{
DataManager
.
Instance
.
AddSkill
(
1
,
-
1
);
DataManager
.
Instance
.
AddSkill
(
1
,
-
1
);
CheckRemainAmmo
(
1
);
CheckRemainAmmo
(
1
);
Interface
.
instance
.
skillSelectionManager
.
skills
[
1
].
CountDown
(
3
f
);
Interface
.
instance
.
skillSelectionManager
.
skills
[
1
].
CountDown
(
2
f
);
default_attacking
=
false
;
default_attacking
=
false
;
//-----------
//-----------
if
(
laserTrigger0
==
false
)
Class_Controller
.
laserMouseButtonDown
=
true
;
if
(
laserTrigger0
==
false
)
Class_Controller
.
laserMouseButtonDown
=
true
;
...
@@ -1013,7 +1020,7 @@ public class Controller : MonoBehaviour
...
@@ -1013,7 +1020,7 @@ public class Controller : MonoBehaviour
{
{
DataManager
.
Instance
.
AddSkill
(
4
,
-
1
);
DataManager
.
Instance
.
AddSkill
(
4
,
-
1
);
CheckRemainAmmo
(
4
);
CheckRemainAmmo
(
4
);
Interface
.
instance
.
skillSelectionManager
.
skills
[
4
].
CountDown
(
3
f
);
Interface
.
instance
.
skillSelectionManager
.
skills
[
4
].
CountDown
(
2
f
);
default_attacking
=
false
;
default_attacking
=
false
;
//-----------
//-----------
...
...
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