Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
T
tuseGameColor
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
shujianhe
tuseGameColor
Commits
ac8baf3f
Commit
ac8baf3f
authored
Aug 07, 2023
by
shujianhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
b3e87a9a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
29 deletions
+24
-29
Android.zip.meta
Assets/Plugins/Android.zip.meta
+0
-7
salaScene.unity
Assets/Scenes/salaScene.unity
+1
-1
gameUserInfos.cs
Assets/scripts/Views/gameScene/gameUserInfos.cs
+1
-0
mainGameView.cs
Assets/scripts/common/mainGameView.cs
+20
-20
utilsDB.cs
Assets/scripts/utils/utilsDB.cs
+2
-1
No files found.
Assets/Plugins/Android.zip.meta
deleted
100644 → 0
View file @
b3e87a9a
fileFormatVersion: 2
guid: f2ecd7a0e0eead542999710d3149cbdf
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Assets/Scenes/salaScene.unity
View file @
ac8baf3f
...
...
@@ -285,7 +285,7 @@ RectTransform:
m_GameObject
:
{
fileID
:
514566347
}
m_LocalRotation
:
{
x
:
0
,
y
:
0
,
z
:
0
,
w
:
1
}
m_LocalPosition
:
{
x
:
0
,
y
:
0
,
z
:
0
}
m_LocalScale
:
{
x
:
1
,
y
:
1
,
z
:
1
}
m_LocalScale
:
{
x
:
0.4
,
y
:
0.4
,
z
:
1
}
m_ConstrainProportionsScale
:
0
m_Children
:
-
{
fileID
:
1246613933
}
...
...
Assets/scripts/Views/gameScene/gameUserInfos.cs
View file @
ac8baf3f
...
...
@@ -236,6 +236,7 @@ public class gameUserInfos : MonoBehaviour, IEventHandler
}
var
gameBackJavaData
=
utilsTools
.
getGDataByKey
<
GameBackJavaData
>(
"gameBackJavaData"
,
null
);
gameBackJavaData
.
schedule
=
schedule
;
gameBackJavaData
.
path
=
gameScenUserInfo
.
getLocalThumbnailPath
();
utilsTools
.
setGDataByKey
(
"gameBackJavaData"
,
gameBackJavaData
);
updateProgress
();
...
...
Assets/scripts/common/mainGameView.cs
View file @
ac8baf3f
...
...
@@ -32,7 +32,6 @@ public class mainGameView : MonoBehaviour
private
Texture2D
colorTexure2d
=
null
;
protected
short
nowSelectgid
=
-
1
;
protected
bool
fillAnimation
=
true
;
private
bool
thumbnailIsChange
=
false
;
private
string
[]
initDigitMatrixs
=
{
""
,
""
,
""
};
protected
Dictionary
<
short
,
short
>
aid2selectOrderIdx
=
new
Dictionary
<
short
,
short
>();
protected
GameScenUserInfo
gameScenUseInfo
=
null
;
...
...
@@ -133,7 +132,11 @@ public class mainGameView : MonoBehaviour
if
(
allColor
.
ContainsKey
(
"line"
)
==
false
)
allColor
.
Add
(
"line"
,
lineTexture2d
.
GetPixels
(
0
,
0
,
gameidJsondata
.
width
,
gameidJsondata
.
height
));
else
allColor
.
Add
(
"line"
,
lineTexture2d
.
GetPixels
(
0
,
0
,
gameidJsondata
.
width
,
gameidJsondata
.
height
));
allColor
[
"line"
]
=
lineTexture2d
.
GetPixels
(
0
,
0
,
gameidJsondata
.
width
,
gameidJsondata
.
height
);
if
(
allColor
.
ContainsKey
(
"thumbnail"
)
==
false
)
allColor
.
Add
(
"thumbnail"
,
thumbnailTexture2d
.
GetPixels
(
0
,
0
,
thumbnailTexture2d
.
width
,
thumbnailTexture2d
.
height
));
else
allColor
[
"thumbnail"
]
=
thumbnailTexture2d
.
GetPixels
(
0
,
0
,
thumbnailTexture2d
.
width
,
thumbnailTexture2d
.
height
);
TaskItemBack
taskItemBack
=
(
System
.
Object
[]
param
)
=>
{
int
start
=
(
int
)
param
[
0
];
...
...
@@ -158,9 +161,13 @@ public class mainGameView : MonoBehaviour
{
var
color
=
colorTexure2d
.
GetPixelBilinear
(
x
/
width
,
y
/
height
);
color
.
a
=
1f
;
colors
[
index
]
=
color
;
allColor
[
"thumbnail"
]
[
index
]
=
color
;
}
else
{
allColor
[
"thumbnail"
][
index
]
=
new
Color
(
1
,
1
,
1
,
1
);
}
if
(
nowValue
.
Equals
(
fullShow
))
{
Color
color1
=
allColor
[
"line"
][
index
];
...
...
@@ -170,9 +177,6 @@ public class mainGameView : MonoBehaviour
}
}
//thumbnailTexture2d.SetPixels(start, 0, step, gameidJsondata.height,colors);
int
diff
=
utilsTools
.
getTotalMillisecond
()
-
a1
;
Debug
.
Log
(
"*****---- makeThumbnail "
+
start
.
ToString
()
+
" diff = "
+
diff
.
ToString
());
};
loopAddTaskBack
(
gameidJsondata
.
width
,
340
,
taskItemBack
);
tm
.
addTask
(
this
,
(
System
.
Object
[]
param
)
=>
...
...
@@ -858,11 +862,6 @@ public class mainGameView : MonoBehaviour
public
virtual
bool
switchShowAreaGroup
(
short
gid
,
OnAreaHandler
onAreaHandler
=
null
)
{
//utilsTools.setGDataByKey("makeThumbnailBegin", utilsTools.getTotalMillisecond());
if
(
utilsTools
.
ContainsKeyGDataByKey
(
"firstSwitchShowAreaBegin"
)
==
false
)
{
utilsTools
.
setGDataByKey
(
"firstSwitchShowAreaBegin"
,
utilsTools
.
getTotalMillisecond
());
}
if
(
gid
.
Equals
(
nowSelectgid
))
{
if
(
onAreaHandler
!=
null
)
...
...
@@ -894,8 +893,6 @@ public class mainGameView : MonoBehaviour
{
allColor
[
"low"
]
=
lowImgTexture2d
.
GetPixels
(
0
,
0
,
lowImgTexture2d
.
width
,
lowImgTexture2d
.
height
);
}
if
(
thumbnailTexture2d
!=
null
&&
allColor
.
ContainsKey
(
"thumbnail"
)
==
false
)
allColor
.
Add
(
"thumbnail"
,
thumbnailTexture2d
.
GetPixels
(
0
,
0
,
thumbnailTexture2d
.
width
,
thumbnailTexture2d
.
height
));
if
(
nowSelectgid
>
0
)
{
...
...
@@ -915,7 +912,6 @@ public class mainGameView : MonoBehaviour
{
if
(
digitMatrix
.
Data
[
pt
.
x
,
pt
.
y
]
==
bianlun
)
continue
;
color
.
a
=
0f
;
//lowImgTexture2d.SetPixel(pt.y, pt.x, color);
allColor
[
"low"
][
pt
.
y
*
gameidJsondata
.
width
+
pt
.
x
]
=
color
;
}
}
...
...
@@ -945,12 +941,14 @@ public class mainGameView : MonoBehaviour
this
.
nowSelectColors
.
getTiledColor
(
pt
.
x
,
pt
.
y
,
ref
color
);
color
.
a
=
1f
;
allColor
[
"low"
][
pt
.
y
*
gameidJsondata
.
width
+
pt
.
x
]
=
color
;
//lowImgTexture2d.SetPixel(pt.y, pt.x, color);
}
}
lowImgTexture2d
.
SetPixels
(
0
,
0
,
lowImgTexture2d
.
width
,
lowImgTexture2d
.
height
,
allColor
[
"low"
]);
lowImgTexture2d
.
Apply
();
lowImg
.
SetActive
(
true
);
if
(
utilsTools
.
getGDataByKey
<
bool
>(
"autoFillColor"
,
false
)
==
false
)
{
lowImgTexture2d
.
SetPixels
(
0
,
0
,
lowImgTexture2d
.
width
,
lowImgTexture2d
.
height
,
allColor
[
"low"
]);
lowImgTexture2d
.
Apply
();
lowImg
.
SetActive
(
true
);
}
if
(
onAreaHandler
!=
null
)
onAreaHandler
(
gid
,
true
);
if
(
utilsTools
.
ContainsKeyGDataByKey
(
"firstSwitchShowAreaEnd"
)
==
false
)
...
...
@@ -1219,7 +1217,7 @@ public class mainGameView : MonoBehaviour
if
(
showAreaAnimationDatas
.
Count
==
0
)
{
//保存一次缩略遮罩图
thumbnailIsChange
=
true
;
if
(
utilsTools
.
isEqualByValue
(
gameScenUseInfo
.
progress
,
1.0
,
0.0000002f
))
{
TaskManages
.
getInstance
().
addTask
(
this
,
(
System
.
Object
[]
parma
)
=>
...
...
@@ -1255,7 +1253,6 @@ public class mainGameView : MonoBehaviour
int
y1
=
(
int
)((
float
)
y
/
(
float
)
gameidJsondata
.
height
*
colorTexure2d
.
height
);
thumbnail
[
value
]
=
jpgColors
[
y1
*
colorTexure2d
.
width
+
x1
];
}
thumbnailIsChange
=
true
;
};
for
(
int
i
=
0
;
i
<
aids
.
Count
;
i
++)
{
...
...
@@ -1362,6 +1359,7 @@ public class mainGameView : MonoBehaviour
return
0
;
}
}
//自动填充的主要计算方式
public
virtual
void
onAutoFillHandler
()
{
//恢复尺寸
...
...
@@ -1414,6 +1412,7 @@ public class mainGameView : MonoBehaviour
return
true
;
},
0.8
,
10
);
}
//提示的查找过程
public
void
onTipHandler
()
{
if
(
isDebugTestToEnd
==
false
)
...
...
@@ -1513,6 +1512,7 @@ public class mainGameView : MonoBehaviour
utilsTools
.
sendEventObjectParams
(
"gamePlayerEndHandler"
);
}
}
//加载小的选中图的保存过程,如果需要三合一的方式mainGameOneImageView的处理方式
protected
virtual
void
loadSelectImageTexture
(
Texture2D
nowSelectTexture
,
NotifyEmptParam
notify
,
int
width
=
0
,
int
height
=
0
)
{
if
(
width
==
0
||
height
==
0
)
...
...
Assets/scripts/utils/utilsDB.cs
View file @
ac8baf3f
...
...
@@ -15,7 +15,8 @@ public class utilsDB
private
static
Dictionary
<
string
,
Dictionary
<
String
,
List
<
System
.
Object
>>>
debugDBTables
=
new
Dictionary
<
string
,
Dictionary
<
string
,
List
<
System
.
Object
>>>();
static
utilsDB
()
{
PlayerPrefs
.
DeleteAll
();
if
(
utilsTools
.
IsWin
)
PlayerPrefs
.
DeleteAll
();
string
path
=
utilsTools
.
copyFile
(
"tsmi.db"
);
if
(
path
.
Equals
(
""
)
==
true
)
{
...
...
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