This commit is contained in:
DESKTOP-5RP3AKU\Jisol 2023-12-19 03:08:16 +08:00
parent a97f36aea1
commit d66f08455e
6 changed files with 13 additions and 12 deletions

File diff suppressed because one or more lines are too long

View File

@ -795,7 +795,7 @@
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.077707
"y": 0
},
"_id": ""
},
@ -867,11 +867,11 @@
"_offset": {
"__type__": "cc.Vec2",
"x": 0,
"y": 42.22925458281746
"y": 50
},
"_size": {
"__type__": "cc.Size",
"width": 100,
"width": 50,
"height": 100
},
"_id": ""

View File

@ -28,12 +28,12 @@ import AppAction from "./AppAction";
import { Asset } from "cc";
import { Component } from "cc";
// 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.122:8080`
let WsPath = `ws://192.168.0.122:8080/websocket`
// let APIPath = `http://192.168.0.122:8080`
// let WsPath = `ws://192.168.0.122:8080/websocket`
// let APIPath = `https://api.pet.jisol.cn`
// let WsPath = `wss://api.pet.jisol.cn/websocket`

View File

@ -149,7 +149,7 @@ export default abstract class GRoleBase<T> extends GObject<T>{
return true;
}else{
//移动
this.setWorldPosition(this.node.worldPosition.subtract(v3(normal.x*dt*this.moveSpeed,normal.y*dt*this.moveSpeed,0)));
this.setWorldPosition(this.node.worldPosition.clone().subtract(v3(normal.x*dt*this.moveSpeed,normal.y*dt*this.moveSpeed,0)));
return false;
}
@ -157,9 +157,10 @@ export default abstract class GRoleBase<T> extends GObject<T>{
//设置世界坐标
setWorldPosition(worldPos:Vec3){
if(this.ov.moveTo(worldPos)){
// if(worldPos = this.ov.moveTo(worldPos)){
this.node.setWorldPosition(worldPos);
}
// }
// return worldPos;
}
//朝向目标

@ -1 +1 @@
Subproject commit 272edb60968029a231fb5291d8801f4d0a661273
Subproject commit 3a8c35bc7bc02e22021acfc4671e9d8ffaadd87b