|
@@ -28,7 +28,7 @@ const { ccclass, property } = _decorator;
|
|
|
export class game extends Component {
|
|
|
@property(SpriteFrame) sfList:SpriteFrame[] = [];
|
|
|
@property(SpriteFrame) sfBuffList:SpriteFrame[] = [];
|
|
|
- @property(BoxCollider2D) collider:BoxCollider2D = null;
|
|
|
+ @property(Node) collider:Node = null;
|
|
|
@property(Node) car:Node = null;
|
|
|
@property(Node) content:Node = null;
|
|
|
@property(Prefab) prefab_item:Prefab = null;
|
|
@@ -90,16 +90,23 @@ export class game extends Component {
|
|
|
}
|
|
|
}
|
|
|
},0.25)
|
|
|
- this.collider.off(Contact2DType.END_CONTACT)
|
|
|
- this.collider.on(Contact2DType.END_CONTACT,(selfCollider: Collider2D, otherCollider: Collider2D, contact: IPhysics2DContact | null)=>{
|
|
|
- if(otherCollider.node.name.endsWith("run_level_item")){
|
|
|
- this.deleteItem(otherCollider.node)
|
|
|
- }
|
|
|
- },this)
|
|
|
+ // this.collider.off(Contact2DType.END_CONTACT)
|
|
|
+ // this.collider.on(Contact2DType.END_CONTACT,(selfCollider: Collider2D, otherCollider: Collider2D, contact: IPhysics2DContact | null)=>{
|
|
|
+ // if(otherCollider.node.name.endsWith("run_level_item")){
|
|
|
+ // this.deleteItem(otherCollider.node)
|
|
|
+ // }
|
|
|
+ // },this)
|
|
|
|
|
|
this.onTTStartRecordVideo()
|
|
|
}
|
|
|
|
|
|
+ public isOut(pos:Vec3){
|
|
|
+ if(pos.y<this.collider.position.y){
|
|
|
+ return true
|
|
|
+ }
|
|
|
+ return false
|
|
|
+ }
|
|
|
+
|
|
|
public showBoom(box_p:Vec3){
|
|
|
this.mBoomManager.showBoom(box_p)
|
|
|
}
|