This commit is contained in:
PC-20230316NUNE\Administrator
2023-11-28 19:20:11 +08:00
parent 5a9ab02b54
commit 720542eadd
17 changed files with 175 additions and 812 deletions

View File

@@ -26,12 +26,12 @@ import { JAPI, JAPIConfig } from "../../extensions/ngame/assets/ngame/util/JAPI"
import { AppData } from "./AppData";
import AppAction from "./AppAction";
let APIPath = `http://localhost:8080`
let WsPath = `ws://localhost:8080/websocket`
// let APIPath = `http://localhost:8080`
// let WsPath = `ws://localhost:8080/websocket`
// let APIPath = `http://192.168.1.23:8080`
// let WsPath = `ws://192.168.1.23:8080/websocket`
// let APIPath = `http://192.168.0.170:8080`
// let WsPath = `ws://192.168.0.170:8080/websocket`
let APIPath = `http://192.168.0.113:8080`
let WsPath = `ws://192.168.0.113:8080/websocket`
// let APIPath = `https://api.pet.jisol.cn`
// let WsPath = `wss://api.pet.jisol.cn/websocket`
@@ -47,7 +47,7 @@ class JNGSocket extends JNSocket{
this.on(GAction.TOKEN_EXPIRED,this.onTokenExpired.bind(this));
await super.onInit();
}
public url():Promise<string> {
public async url():Promise<string> {
return new Promise<string>(resolve => {
//获取Token
let token = StorageData.get(StorageEnum.Token);