Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
colourful-love
Project
Overview
Details
Activity
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
Eko Simanjuntak
colourful-love
Commits
12b486c5
Commit
12b486c5
authored
Dec 08, 2017
by
Eko Simanjuntak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug fix obstacle not change
parent
08f5c2da
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
2 deletions
+4
-2
storage.ide
.vs/Colorful Love/v15/sqlite3/storage.ide
+0
-0
Level 1.unity
Assets/Scenes/Level 1.unity
+0
-0
BackgroundChanger.cs
Assets/Scripts/BackgroundChanger.cs
+4
-2
No files found.
.vs/Colorful Love/v15/sqlite3/storage.ide
View file @
12b486c5
No preview for this file type
Assets/Scenes/Level 1.unity
View file @
12b486c5
This source diff could not be displayed because it is too large. You can
view the blob
instead.
Assets/Scripts/BackgroundChanger.cs
View file @
12b486c5
...
...
@@ -8,7 +8,6 @@ public class BackgroundChanger : MonoBehaviour {
private
List
<
GameObject
>
obstacleGroup
=
new
List
<
GameObject
>();
private
GameObject
[]
gameObjectGroup
;
private
GameObject
background
;
private
GameObject
obstacle
;
private
string
[]
colors
=
{
"Blue"
,
"Green"
};
public
void
Start
()
...
...
@@ -31,10 +30,13 @@ public class BackgroundChanger : MonoBehaviour {
{
foreach
(
string
color
in
colors
)
{
obstacle
=
GameObject
.
FindWithTag
(
color
+
"Obstacle"
);
gameObjectGroup
=
GameObject
.
FindGameObjectsWithTag
(
color
+
"Obstacle"
);
foreach
(
GameObject
obstacle
in
gameObjectGroup
)
{
obstacleGroup
.
Add
(
obstacle
);
}
}
}
public
void
Update
()
{
...
...
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