Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added MIGU channel identifiers #17687

Merged
merged 1 commit into from
Oct 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions cc.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,13 @@
"ccGlobal": true,
"internal": false
},
"MIGU": {
"comment": "Running in the migu's quick game.",
"type": "boolean",
"value": false,
"ccGlobal": true,
"internal": false
},

"EDITOR": {
"comment": "Running in the editor.",
Expand Down
1 change: 1 addition & 0 deletions pal/system-info/enum-type/platform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,5 @@ export enum Platform {
COCOSPLAY = 'COCOSPLAY',
LINKSURE_MINI_GAME = 'LINKSURE_MINI_GAME',
QTT_MINI_GAME = 'QTT_MINI_GAME',
MIGU_MINI_GAME = 'MIGU_MINI_GAME',
}
4 changes: 3 additions & 1 deletion pal/system-info/minigame/system-info.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
THE SOFTWARE.
*/

import { ALIPAY, BAIDU, BYTEDANCE, COCOSPLAY, HUAWEI, LINKSURE, OPPO, QTT, VIVO, WECHAT, XIAOMI, DEBUG, TEST, TAOBAO, TAOBAO_MINIGAME, WECHAT_MINI_PROGRAM } from 'internal:constants';
import { ALIPAY, BAIDU, BYTEDANCE, COCOSPLAY, HUAWEI, LINKSURE, OPPO, QTT, VIVO, MIGU, WECHAT, XIAOMI, DEBUG, TEST, TAOBAO, TAOBAO_MINIGAME, WECHAT_MINI_PROGRAM } from 'internal:constants';

Check warning on line 25 in pal/system-info/minigame/system-info.ts

View workflow job for this annotation

GitHub Actions / Run ESLint

This line has a length of 189. Maximum allowed is 150
import { minigame } from 'pal/minigame';
import { IFeatureMap } from 'pal/system-info';
import { EventTarget } from '../../../cocos/core/event';
Expand Down Expand Up @@ -60,6 +60,8 @@
currentPlatform = Platform.LINKSURE_MINI_GAME;
} else if (QTT) {
currentPlatform = Platform.QTT_MINI_GAME;
} else if (MIGU) {
currentPlatform = Platform.MIGU_MINI_GAME;
}

let isVersionGreaterOrEqualTo;
Expand Down
1 change: 1 addition & 0 deletions platforms/runtime/platforms/migu-mini-game/engine/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
require('../../../common/engine/index');
Loading