Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
new_taobao
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
wildfirecode13
new_taobao
Commits
99886dbb
Commit
99886dbb
authored
Oct 14, 2020
by
zhangjinzhou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码暂存
parent
e7d952ca
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
10 deletions
+23
-10
pagegamemain.js
taobao_jn/client/pages/pagegamemain/pagegamemain.js
+21
-8
pagepageindex.js
taobao_jn/client/pages/pagepageindex/pagepageindex.js
+2
-2
No files found.
taobao_jn/client/pages/pagegamemain/pagegamemain.js
View file @
99886dbb
...
@@ -22,10 +22,11 @@ const toolwarm = 1;//升温道具+温度值
...
@@ -22,10 +22,11 @@ const toolwarm = 1;//升温道具+温度值
const
taskwarm
=
1
;
//任务+温度值
const
taskwarm
=
1
;
//任务+温度值
const
invitewarm
=
1
;
//邀请+温度值
const
invitewarm
=
1
;
//邀请+温度值
const
toolcd
=
5
;
//
const
toolcd
=
5
;
//
const
paple1
=
"cloud://50A61CFE9CCC27602FFD480B36839784//paple1.svga"
;
const
paple2
=
"cloud://48FEB56992D156E3C9C05DC07DFEAC5C//paple2.svga"
;
const
paple1
=
"cloud://1C47337C3D86F381913E3741232B26EB//paple1.svga"
;
const
paple3
=
"cloud://003C0A5953796DA010090F2745FA02B5//paple3.svga"
;
const
paple2
=
"cloud://6E5D893BA34F99343C702D9FAA543C21//paple2.svga"
;
const
paple4
=
"cloud://1FFE377B99BB73F6D837D258262405DF//paple4.svga"
;
const
paple3
=
"cloud://F03F0071205084B1A58F9C560010C076//paple3.svga"
;
const
paple4
=
"cloud://650F093A4384DAB23C0C551A7818EE1F//paple4.svga"
;
Page
({
Page
({
data
:
{
data
:
{
resList
:
resList
,
resList
:
resList
,
...
@@ -106,15 +107,16 @@ Page({
...
@@ -106,15 +107,16 @@ Page({
avatar2
:
""
,
avatar2
:
""
,
avatar3
:
""
,
avatar3
:
""
,
avatar4
:
""
,
avatar4
:
""
,
canwin
:
false
;
canwin
:
false
},
},
onLoad
(
props
)
{
onLoad
(
props
)
{
console
.
log
(
"onLoad========>"
,
app
,
props
);
console
.
log
(
"onLoad========>"
,
app
,
props
);
let
step
=
1
;
let
step
=
1
;
let
sucgl
=
70
;
let
sucgl
=
70
;
let
nranksuc
=
Math
.
random
()
*
100
;
let
nranksuc
=
Math
.
random
()
*
100
;
let
canwin
=
false
;
if
(
nranksuc
<
sucgl
){
//能赢
if
(
nranksuc
<
sucgl
){
//能赢
canwin
=
true
;
}
}
let
roomnums
=
[
2
,
3
,
4
][
step
-
1
];
let
roomnums
=
[
2
,
3
,
4
][
step
-
1
];
if
(
roomnums
==
2
)
{
if
(
roomnums
==
2
)
{
...
@@ -139,14 +141,25 @@ Page({
...
@@ -139,14 +141,25 @@ Page({
roomdata
:
roomdata
,
roomdata
:
roomdata
,
attionlist
:
[],
attionlist
:
[],
showattionlist
:
[],
showattionlist
:
[],
canwin
:
canwin
,
});
});
let
attiontxt1
=
"游戏开始啦,共有"
+
roomnums
+
"名玩家加入游戏,快来升温队伍拿奖励吧。"
;
let
attiontxt1
=
"游戏开始啦,共有"
+
roomnums
+
"名玩家加入游戏,快来升温队伍拿奖励吧。"
;
this
.
addAttionTxt
(
attiontxt1
);
this
.
addAttionTxt
(
attiontxt1
);
this
.
changePashow
();
this
.
changePashow
();
this
.
updateAct
();
this
.
updateAct
();
// this.updateActInfo();
// this.updateActInfo();
this
.
doAiControl
();
// this.doAiControl();
this
.
newAiControl
();
},
//新ai逻辑
newAiControl
(){
let
canwin
=
this
.
data
.
canwin
;
let
roomnums
=
this
.
data
.
roomnums
-
1
;
if
(
canwin
){
// 机器不用操作
}
else
{
//机器使用道具
}
},
},
//其余机器人升温逻辑
//其余机器人升温逻辑
doAiControl
()
{
doAiControl
()
{
...
...
taobao_jn/client/pages/pagepageindex/pagepageindex.js
View file @
99886dbb
...
@@ -119,7 +119,7 @@ Page({
...
@@ -119,7 +119,7 @@ Page({
},
},
(
err
)
=>
{
(
err
)
=>
{
console
.
log
(
err
);
console
.
log
(
"aa"
,
err
);
}
}
)
)
SvgaParser
.
loadSvga
(
SvgaParser
.
loadSvga
(
...
@@ -133,7 +133,7 @@ Page({
...
@@ -133,7 +133,7 @@ Page({
},
},
(
err
)
=>
{
(
err
)
=>
{
console
.
log
(
err
);
console
.
log
(
"bb"
,
err
);
}
}
)
)
...
...
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