Constructor
new BigMath_StarScoreBoard()
Properties:
| Name | Type | Description |
|---|---|---|
topicNumber |
Number | 游戏题目总数 - 默认值:3 |
marginDistance |
Number | 星星间隔值 - 默认值:80 |
starBgLocation |
Object | 背景位置 - 默认值:{x:34,y:36} |
StarScoreBoard |
String | 计分板 - 默认值:"image_StarScoreBoard" |
starLocation |
Object | 第一颗星星位置 - 默认值:{x:63,y:55} |
bgIcon |
String | 默认状态的星星 - 默认值:"image_starIdle" |
loseIcon |
String | 失败状态的星星 - 默认值:"image_starLose" |
lightSpineName |
String | 成功状态的星星动效名称 - 默认值:"animation_star" |
lightAniName |
String | 成功状态的星星播放的动画名称 - 默认值:"star_in" |
starPathSpineName |
String | 星星飞的路径动效名称 - 默认值:"animation_starflash" |
starPathAniName |
String | 星星飞的路径播放的动画名称 - 默认值:"starflash_in" |
starSound |
String | 星星组件的音频配置 - 默认值:"audio_starSound" |
Example
import {Easy} from "pubtool4pixi"
Easy.create("BigMath_StarScoreBoard",{
topicNumber : 3,
marginDistance:80,
starBgLocation:{
x:34,y:36
},
}).show();
Extends
Methods
(static) addLoseStar(presentTopicNumber) → {Promise}
添加失败星星
Parameters:
| Name | Type | Description |
|---|---|---|
presentTopicNumber |
Number | 当前关卡的下标 |
Returns:
添加完成后
- Type
- Promise
(static) addWinStar(presentTopicNumber) → {Promise}
添加成功星星
Parameters:
| Name | Type | Description |
|---|---|---|
presentTopicNumber |
Number | 当前关卡的下标 |
Returns:
星星与路径动效播放完成
- Type
- Promise
(static) playAudio() → {Promise}
播放星星音频
Returns:
音频播放完成
- Type
- Promise
(static) reset()
重置星星动效
(static) starPath() → {Promise}
播放星星路径动效
Returns:
路径动效播放完成
- Type
- Promise