diff --git a/.gitignore b/.gitignore index 56e7afb..e202909 100644 --- a/.gitignore +++ b/.gitignore @@ -3,7 +3,7 @@ # Cocos Creator 3D Project #/////////////////////////// oops-plugin-bundle/ -oops-plugin-framework/ +# oops-plugin-framework/ oops-plugin-hot-update/ oops-plugin-excel-to-json/ oops_framework_remote/ diff --git a/assets/main.scene b/assets/main.scene index 51a2303..ee2c7d1 100644 --- a/assets/main.scene +++ b/assets/main.scene @@ -258,7 +258,7 @@ "_priority": 1073741824, "_fov": 45, "_fovAxis": 0, - "_orthoHeight": 360, + "_orthoHeight": 423.454157782516, "_near": 1, "_far": 2000, "_color": { diff --git a/assets/resources/gui/prefab/demo.prefab b/assets/resources/gui/prefab/demo.prefab index 107518f..9208770 100644 --- a/assets/resources/gui/prefab/demo.prefab +++ b/assets/resources/gui/prefab/demo.prefab @@ -35,18 +35,18 @@ ], "_active": true, "_components": [ - { - "__id__": 247 - }, { "__id__": 249 }, { "__id__": 251 + }, + { + "__id__": 253 } ], "_prefab": { - "__id__": 253 + "__id__": 255 }, "_lpos": { "__type__": "cc.Vec3", @@ -294,7 +294,7 @@ }, "_contentSize": { "__type__": "cc.Size", - "width": 155.7, + "width": 169.02, "height": 50.4 }, "_anchorPoint": { @@ -329,7 +329,7 @@ "b": 255, "a": 255 }, - "_string": "00:07:04", + "_string": "0-1:56:12", "_horizontalAlign": 1, "_verticalAlign": 1, "_actualFontSize": 40, @@ -346,7 +346,7 @@ "_isUnderline": false, "_underlineHeight": 2, "_cacheMode": 1, - "countDown": 424, + "countDown": -228, "dayFormat": "{0} day", "timeFormat": "{0}:{1}:{2}", "zeroize": true, @@ -2867,18 +2867,18 @@ ], "_active": true, "_components": [ - { - "__id__": 240 - }, { "__id__": 242 }, { "__id__": 244 + }, + { + "__id__": 246 } ], "_prefab": { - "__id__": 246 + "__id__": 248 }, "_lpos": { "__type__": "cc.Vec3", @@ -5191,18 +5191,18 @@ ], "_active": true, "_components": [ - { - "__id__": 232 - }, { "__id__": 234 }, { "__id__": 236 + }, + { + "__id__": 238 } ], "_prefab": { - "__id__": 239 + "__id__": 241 }, "_lpos": { "__type__": "cc.Vec3", @@ -5248,10 +5248,13 @@ }, { "__id__": 229 + }, + { + "__id__": 231 } ], "_prefab": { - "__id__": 231 + "__id__": 233 }, "_lpos": { "__type__": "cc.Vec3", @@ -5330,7 +5333,7 @@ "b": 0, "a": 255 }, - "_string": "长按按钮", + "_string": "长按", "_horizontalAlign": 1, "_verticalAlign": 1, "_actualFontSize": 20, @@ -5353,6 +5356,25 @@ "__type__": "cc.CompPrefabInfo", "fileId": "894Y0PR6FAMpQXUh/Kp9HA" }, + { + "__type__": "110c8vEd5NEPL/N9meGQnaX", + "_name": "", + "_objFlags": 0, + "node": { + "__id__": 226 + }, + "_enabled": true, + "__prefab": { + "__id__": 232 + }, + "_params": [], + "_dataID": "btn_long", + "_id": "" + }, + { + "__type__": "cc.CompPrefabInfo", + "fileId": "09qmDE5fxAuau2BZgr1K0R" + }, { "__type__": "cc.PrefabInfo", "root": { @@ -5375,7 +5397,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 233 + "__id__": 235 }, "_contentSize": { "__type__": "cc.Size", @@ -5402,7 +5424,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 235 + "__id__": 237 }, "_customMaterial": null, "_srcBlendFactor": 2, @@ -5446,7 +5468,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 237 + "__id__": 239 }, "once": false, "interval": 500, @@ -5454,7 +5476,7 @@ "time": 1, "clickEvents": [ { - "__id__": 238 + "__id__": 240 } ], "_id": "" @@ -5496,7 +5518,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 241 + "__id__": 243 }, "_contentSize": { "__type__": "cc.Size", @@ -5524,7 +5546,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 243 + "__id__": 245 }, "_resizeMode": 1, "_layoutType": 1, @@ -5562,7 +5584,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 245 + "__id__": 247 }, "_alignFlags": 18, "_target": null, @@ -5610,7 +5632,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 248 + "__id__": 250 }, "_contentSize": { "__type__": "cc.Size", @@ -5637,7 +5659,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 250 + "__id__": 252 }, "_alignFlags": 45, "_target": null, @@ -5672,7 +5694,7 @@ }, "_enabled": true, "__prefab": { - "__id__": 252 + "__id__": 254 }, "_id": "" }, diff --git a/assets/resources/language/json/en.json b/assets/resources/language/json/en.json index 60e9940..5c3e2a9 100644 --- a/assets/resources/language/json/en.json +++ b/assets/resources/language/json/en.json @@ -12,6 +12,7 @@ "netInstableOpen": "Waiting ", "btn_audio_open1": "Music", "btn_audio_open2": "Effect", + "btn_long": "Long Press", "loading_load_json": "Load Json", "loading_load_game": "Load Content", "loading_load_player": "Get user information", diff --git a/assets/resources/language/json/zh.json b/assets/resources/language/json/zh.json index 2860116..2ffbdb9 100644 --- a/assets/resources/language/json/zh.json +++ b/assets/resources/language/json/zh.json @@ -22,6 +22,7 @@ "netInstableOpen": "等待动画", "btn_audio_open1": "音乐播放", "btn_audio_open2": "音效播放", + "btn_long": "长按按钮", "loading_load_json": "加载游戏本地数据", "loading_load_game": "加载游戏内容", "loading_load_player": "获取用户信息", diff --git a/assets/script/game/demo/Demo.ts b/assets/script/game/demo/Demo.ts index 552b60a..1de2180 100644 --- a/assets/script/game/demo/Demo.ts +++ b/assets/script/game/demo/Demo.ts @@ -2,7 +2,7 @@ * @Author: dgflash * @Date: 2021-07-03 16:13:17 * @LastEditors: dgflash - * @LastEditTime: 2022-11-11 17:25:50 + * @LastEditTime: 2023-07-29 09:57:37 */ import { Component, EventTouch, _decorator } from "cc"; import { oops } from "../../../../extensions/oops-plugin-framework/assets/core/Oops"; @@ -47,7 +47,7 @@ export class Demo extends Component { } private btn_long(event: EventTouch, data: any) { - oops.gui.toast(data); + oops.gui.toast(data, true); } /** 升级 */ @@ -122,7 +122,7 @@ export class Demo extends Component { /** 漂浮提示框 */ private btn_notify_show(event: EventTouch, data: any) { - oops.gui.toast("common_prompt_content"); + oops.gui.toast("common_prompt_content", true); } /** 加载提示 */ diff --git a/extensions/oops-plugin-framework b/extensions/oops-plugin-framework new file mode 160000 index 0000000..ae3a9e9 --- /dev/null +++ b/extensions/oops-plugin-framework @@ -0,0 +1 @@ +Subproject commit ae3a9e985813c9fa3c3e9f5ac8d403fcd92f70b3