Add score-o mode and split game map HUD presentation
This commit is contained in:
@@ -30,7 +30,7 @@ type MapPageData = MapEngineViewState & {
|
||||
showRightButtonGroups: boolean
|
||||
showBottomDebugButton: boolean
|
||||
}
|
||||
const INTERNAL_BUILD_VERSION = 'map-build-157'
|
||||
const INTERNAL_BUILD_VERSION = 'map-build-166'
|
||||
const REMOTE_GAME_CONFIG_URL = 'https://oss-mbh5.colormaprun.com/wxmini/test/game.json'
|
||||
let mapEngine: MapEngine | null = null
|
||||
function buildSideButtonVisibility(mode: SideButtonMode) {
|
||||
@@ -98,10 +98,13 @@ Page({
|
||||
hudPanelIndex: 0,
|
||||
panelTimerText: '00:00:00',
|
||||
panelMileageText: '0m',
|
||||
panelActionTagText: '目标',
|
||||
panelDistanceTagText: '点距',
|
||||
panelDistanceValueText: '--',
|
||||
panelDistanceUnitText: '',
|
||||
panelProgressText: '0/0',
|
||||
gameSessionStatus: 'idle',
|
||||
gameModeText: '顺序赛',
|
||||
panelSpeedValueText: '0',
|
||||
panelTelemetryTone: 'blue',
|
||||
panelHeartRateZoneNameText: '--',
|
||||
@@ -160,10 +163,13 @@ Page({
|
||||
hudPanelIndex: 0,
|
||||
panelTimerText: '00:00:00',
|
||||
panelMileageText: '0m',
|
||||
panelActionTagText: '目标',
|
||||
panelDistanceTagText: '点距',
|
||||
panelDistanceValueText: '--',
|
||||
panelDistanceUnitText: '',
|
||||
panelProgressText: '0/0',
|
||||
gameSessionStatus: 'idle',
|
||||
gameModeText: '顺序赛',
|
||||
panelSpeedValueText: '0',
|
||||
panelTelemetryTone: 'blue',
|
||||
panelHeartRateZoneNameText: '--',
|
||||
@@ -442,6 +448,18 @@ Page({
|
||||
}
|
||||
},
|
||||
|
||||
handleSetClassicMode() {
|
||||
if (mapEngine) {
|
||||
mapEngine.handleSetGameMode('classic-sequential')
|
||||
}
|
||||
},
|
||||
|
||||
handleSetScoreOMode() {
|
||||
if (mapEngine) {
|
||||
mapEngine.handleSetGameMode('score-o')
|
||||
}
|
||||
},
|
||||
|
||||
handleOverlayTouch() {},
|
||||
|
||||
handlePunchAction() {
|
||||
|
||||
@@ -121,9 +121,9 @@
|
||||
<swiper class="race-panel-swiper" current="{{hudPanelIndex}}" bindchange="handleHudPanelChange" duration="220" easing-function="easeOutCubic">
|
||||
<swiper-item>
|
||||
<view class="race-panel race-panel--tone-{{panelTelemetryTone}}">
|
||||
<view class="race-panel__tag race-panel__tag--top-left">目标</view>
|
||||
<view class="race-panel__tag race-panel__tag--top-left">{{panelActionTagText}}</view>
|
||||
<view class="race-panel__tag race-panel__tag--top-right">里程</view>
|
||||
<view class="race-panel__tag race-panel__tag--bottom-left">点距</view>
|
||||
<view class="race-panel__tag race-panel__tag--bottom-left">{{panelDistanceTagText}}</view>
|
||||
<view class="race-panel__tag race-panel__tag--bottom-right">速度</view>
|
||||
|
||||
<view class="race-panel__line race-panel__line--center"></view>
|
||||
@@ -246,6 +246,10 @@
|
||||
<view class="debug-section__title">Session</view>
|
||||
<view class="debug-section__desc">当前局状态与主流程控制</view>
|
||||
</view>
|
||||
<view class="info-panel__row">
|
||||
<text class="info-panel__label">Mode</text>
|
||||
<text class="info-panel__value">{{gameModeText}}</text>
|
||||
</view>
|
||||
<view class="info-panel__row">
|
||||
<text class="info-panel__label">Game</text>
|
||||
<text class="info-panel__value">{{gameSessionStatus}}</text>
|
||||
@@ -262,6 +266,10 @@
|
||||
<text class="info-panel__label">Punch Hint</text>
|
||||
<text class="info-panel__value">{{punchHintText}}</text>
|
||||
</view>
|
||||
<view class="control-row">
|
||||
<view class="control-chip {{gameModeText === '顺序赛' ? 'control-chip--active' : 'control-chip--secondary'}}" bindtap="handleSetClassicMode">顺序赛</view>
|
||||
<view class="control-chip {{gameModeText === '积分赛' ? 'control-chip--active' : 'control-chip--secondary'}}" bindtap="handleSetScoreOMode">积分赛</view>
|
||||
</view>
|
||||
<view class="control-row">
|
||||
<view class="control-chip control-chip--primary" bindtap="handleRecenter">回到首屏</view>
|
||||
<view class="control-chip control-chip--secondary" bindtap="handleRotationReset">旋转归零</view>
|
||||
|
||||
Reference in New Issue
Block a user