Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xiaoxiaole
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
xiaoxiaole
Commits
dfd0b96c
Commit
dfd0b96c
authored
Mar 18, 2020
by
wildfirecode
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
09551666
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
3 deletions
+9
-3
Tool.ts
egret/src/something/Tool.ts
+1
-0
Element.ts
egret/src/something/class/Element.ts
+1
-1
HoneyPot.ts
egret/src/something/class/HoneyPot.ts
+1
-0
HoneyPotElement.ts
egret/src/something/class/HoneyPotElement.ts
+2
-2
cloneElement.ts
egret/src/something/cloneElement.ts
+4
-0
No files found.
egret/src/something/Tool.ts
View file @
dfd0b96c
...
...
@@ -276,6 +276,7 @@ export class Tool {
lat
.
element
.
hasState
(
StateType
.
HONEY
)
||
lat
.
element
.
hasState
(
StateType
.
BLOCK_LOCK
)
||
lat
.
element
.
monster
||
lat
.
element
.
type
==
ElementType
.
HONEY_POT
||
lat
.
element
.
type
==
ElementType
.
JELLY
||
lat
.
element
.
type
==
ElementType
.
JELLY_MONSTER
||
lat
.
element
.
type
==
ElementType
.
FIREWORKS_SHOOTER
||
...
...
egret/src/something/class/Element.ts
View file @
dfd0b96c
...
...
@@ -674,7 +674,7 @@ export class Element extends eui.Component {
return
ele
}
get
candy
()
{
return
this
.
_candy
}
resetView
(){}
resetView
(
...
args
){}
onElimiate
(){}
get
isActive
()
{
return
false
}
canElimite
:
boolean
;
...
...
egret/src/something/class/HoneyPot.ts
View file @
dfd0b96c
...
...
@@ -53,6 +53,7 @@ export class HoneyPot extends eui.Component {
* 状态变化 0,1,2,3
*/
private
_statusNum
:
number
;
get
statusNum
(){
return
this
.
_statusNum
}
private
_honeyPotElement
:
HoneyPotElement
;
private
_mvList
:
any
[];
...
...
egret/src/something/class/HoneyPotElement.ts
View file @
dfd0b96c
...
...
@@ -8,8 +8,8 @@ export default class HoneyPotElement extends Element {
}
honeyPot
:
HoneyPot
;
resetView
()
{
this
.
honeyPot
=
new
HoneyPot
(
this
);
resetView
(
statusNum
)
{
this
.
honeyPot
=
new
HoneyPot
(
this
,
statusNum
);
this
.
addChild
(
this
.
honeyPot
);
this
.
showImage
.
alpha
=
0
;
}
...
...
egret/src/something/cloneElement.ts
View file @
dfd0b96c
import
{
Tool
}
from
"./Tool"
;
import
{
Element
}
from
"./class/Element"
;
import
{
ElementType
}
from
"./enum/ElementType"
;
import
HoneyPotElement
from
"./class/HoneyPotElement"
;
export
default
(
fromElement
:
Element
)
=>
{
let
ele
=
Tool
.
getElement
(
fromElement
.
type
);
...
...
@@ -33,6 +34,9 @@ export default (fromElement: Element) => {
if
(
fromElement
.
type
==
ElementType
.
FISH
)
{
ele
.
resetToFishView
(
fromElement
[
'fish'
].
state
);
}
if
(
fromElement
.
type
==
ElementType
.
HONEY_POT
)
{
ele
.
resetView
(
(
fromElement
as
HoneyPotElement
).
honeyPot
.
statusNum
);
}
return
ele
;
}
\ No newline at end of file
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