dd
This commit is contained in:
@@ -53,6 +53,13 @@ export class SingletonModuleComp extends ecs.Comp {
|
||||
5011:{uuid:5011,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5012:{uuid:5012,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5013:{uuid:5013,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5014:{uuid:5014,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5015:{uuid:5015,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5016:{uuid:5016,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5017:{uuid:5017,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5018:{uuid:5018,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5019:{uuid:5019,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
5020:{uuid:5020,lv:3,exp:0,slv:1,num:90,x1:0},
|
||||
};
|
||||
goods:any=[
|
||||
{uuid:9001,num:100000,type:0,cost:0,inventory:5},
|
||||
|
||||
@@ -141,7 +141,56 @@ export const HeroInfo = {
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5014: {
|
||||
uuid:5014,name: "召唤师",path:"zh1",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5015: {
|
||||
uuid:5015,name: "死灵法师",path:"zh2",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5016: {
|
||||
uuid:5016,name: "下忍",path:"n1",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
|
||||
5017: {
|
||||
uuid:5017,name: "德鲁伊",path:"d1",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5018: {
|
||||
uuid:5018,name: "猎人",path:"d2",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5019: {
|
||||
uuid:5019,name: "狙击手",path:"a4",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
5020: {
|
||||
uuid:5020,name: "亚瑟王",path:"k5",quality:3,kind:2,type:1,hp:200,hp_up:10, shp_up:20,def:10,def_up:1,sdef_up:20,ap:20,ap_up:2,sap_up:20,atp:1,vun:0,crit:20,crit_add:0,ucr:0,dodge:0,dis:300,a_cd:1.5,
|
||||
lvexp:100,slvexp:10,slv:0, speed: 50,aexp:5,uaexp:1,cexp:10,doexp:10,dexp:20,sk1:[6006,6006,6006,6006,6006,6006],sk2:[6102,6102,6102,6102,6102,6102],sk3:[6102,6102,6102,6102,6102,6102],pw:0,pwm:150,pws:10,apw:0,uapw:0,cpw:0,dpw:0,dopw:0,
|
||||
akr:[10,20,30,40,50,60],akc:[1,1,1,1,1,1],uar:[10,20,30,40,50,60],uac:[1,1,1,1,1,1],dgr:[10,20,30,40,50,60],dgc:[1,1,1,1,1,1],crr:[10,20,30,40,50,60],crc:[1,1,1,1,1,1],
|
||||
abh:0,abc:0,uabh:0,uabc:0,cbh:0,cbc:0,aua:0,auc:0,uaua:0,uauc:0,cua:0,cuc:0,wp:1001,arm:2001,ring:3001,shoes:4001,
|
||||
tals:["这是一级说明","这是二级说明","这是三级说明","这是四级说明","这是五级说明"]
|
||||
},
|
||||
|
||||
|
||||
|
||||
@@ -200,7 +249,7 @@ export const HeroInfo = {
|
||||
},
|
||||
|
||||
}
|
||||
export const HeroList = [5001,5002,5003,5004,5005,5006,5007,5008,5009,5010,5011,5012,5013]
|
||||
export const HeroList = [5001,5002,5003,5004,5005,5006,5007,5008,5009,5010,5011,5012,5013,5014,5015,5016,5017,5018,5019,5020]
|
||||
export const MonList = [5201]
|
||||
export const HeroSet = {
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ export class SkillCom extends CCComp {
|
||||
run_type:number = 0; // 0有目标 带方向,1贝塞尔曲线 2 不动 ,3 直线
|
||||
in_time:number = 0.3; // 不动技能持续时间
|
||||
start() {
|
||||
// console.log("skill start run_type",this.run_type)
|
||||
console.log("skill start run_type:",this.run_type)
|
||||
if(this.node.parent.scale.x < 0){
|
||||
this.t_pos.x=this.t_pos.x*-1
|
||||
}
|
||||
|
||||
@@ -1,41 +1,47 @@
|
||||
import { _decorator, Component, Node, tween ,Vec3,v3,Collider2D,Contact2DType} from 'cc';
|
||||
import { BoxSet } from '../common/config/BoxSet';
|
||||
import { Timer } from 'db://oops-framework/core/common/timer/Timer';
|
||||
const { ccclass, property } = _decorator;
|
||||
|
||||
@ccclass('baseCom')
|
||||
export class baseCom extends Component {
|
||||
speed:number = 600;
|
||||
range:number = 80;
|
||||
s_uuid:number = 0;
|
||||
speed:number = 200;
|
||||
y_speed:number = 0;
|
||||
x_speed:number = 0;
|
||||
dis:number = 80;
|
||||
scale:number = 1;
|
||||
ap:number = 10;
|
||||
atk_count:number = 0;
|
||||
is_crit:boolean = false;
|
||||
crit_add: number = 0;//暴击伤害加成
|
||||
angle:number = 0;
|
||||
t_pos:Vec3 = v3(0,0,0); // 目标增量
|
||||
is_destroy:boolean = false;
|
||||
box_group:number = 0;
|
||||
box_tag:number=0;
|
||||
type:number = 1;
|
||||
time:Timer = new Timer(0.01);
|
||||
run_type:number = 0; // 0有目标 带方向,1贝塞尔曲线 2 不动 ,3 直线
|
||||
in_time:number = 0.3; // 不动技能持续时间
|
||||
start() {
|
||||
let collider = this.getComponent(Collider2D);
|
||||
|
||||
if (collider) {
|
||||
collider.on(Contact2DType.BEGIN_CONTACT, this.onBeginContact, this);
|
||||
}
|
||||
console.log("baseCom start")
|
||||
// let collider = this.getComponent(Collider2D);
|
||||
// collider.group = this.box_group;
|
||||
|
||||
// collider.tag = this.box_tag;
|
||||
// collider.sensor = true;
|
||||
// if (collider) {
|
||||
// collider.on(Contact2DType.BEGIN_CONTACT, this.onBeginContact, this);
|
||||
// // collider.on(Contact2DType.END_CONTACT, this.onEndContact, this);
|
||||
// collider.on(Contact2DType.POST_SOLVE, this.onPostSolve, this);
|
||||
// }
|
||||
}
|
||||
onBeginContact (selfCollider: Collider2D, otherCollider: Collider2D) {
|
||||
|
||||
switch (selfCollider.group) {
|
||||
case BoxSet.HERO_SKILL:
|
||||
switch (otherCollider.group){
|
||||
case BoxSet.MONSTER:
|
||||
// this.reset()
|
||||
console.log('hero skill',selfCollider,otherCollider);
|
||||
// this.speed = 0;
|
||||
// this.timer = 1;
|
||||
// console.log("speed:"+this.speed+" | timer:"+this.timer);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case BoxSet.MONSTER_SKILL:
|
||||
switch (otherCollider.group){
|
||||
case BoxSet.HERO:
|
||||
// console.log('monster skill',selfCollider,otherCollider);
|
||||
// this.reset()
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
onPostSolve(selfCollider: Collider2D, otherCollider: Collider2D){
|
||||
|
||||
}
|
||||
reset() {
|
||||
@@ -43,12 +49,7 @@ export class baseCom extends Component {
|
||||
}
|
||||
|
||||
update(deltaTime: number) {
|
||||
this.node.setScale(v3(this.scale,this.node.scale.y,this.node.scale.z))
|
||||
this.node.setPosition(v3(this.node.position.x+deltaTime*this.speed*this.scale,this.node.position.y,this.node.position.z))
|
||||
if(Math.abs(this.node.position.x) > this.range)
|
||||
{
|
||||
this.node.destroy()
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user