woso_javan hace 2 meses
padre
commit
e79d11d2a2

+ 4 - 10
assets/module_storm_sunder/Materials/cartoon_build.mtl

@@ -10,7 +10,9 @@
   },
   "_techIdx": 0,
   "_defines": [
-    {},
+    {
+      "USE_OUTLINE_PASS": true
+    },
     {
       "USE_BASE_COLOR_MAP": true,
       "BASE_COLOR_MAP_AS_SHADE_MAP_1": true,
@@ -88,15 +90,7 @@
     }
   ],
   "_props": [
-    {
-      "baseColor": {
-        "__type__": "cc.Color",
-        "r": 255,
-        "g": 255,
-        "b": 255,
-        "a": 255
-      }
-    },
+    {},
     {
       "mainTexture": {
         "__uuid__": "d10a1525-1eef-48e0-89d8-1d5bbef2f5bd@6c48a",

+ 3 - 1
assets/module_storm_sunder/Materials/cartoon_ground.mtl

@@ -10,7 +10,9 @@
   },
   "_techIdx": 0,
   "_defines": [
-    {},
+    {
+      "USE_OUTLINE_PASS": true
+    },
     {
       "USE_BASE_COLOR_MAP": true,
       "BASE_COLOR_MAP_AS_SHADE_MAP_1": true,

+ 2 - 2
assets/module_storm_sunder/Prefabs/Storm.prefab

@@ -1715,7 +1715,7 @@
     "__type__": "cc.CurveRange",
     "mode": 3,
     "constantMin": 0.6,
-    "constantMax": 2,
+    "constantMax": 1,
     "multiplier": 1
   },
   {
@@ -1765,7 +1765,7 @@
     "__type__": "cc.CurveRange",
     "mode": 3,
     "constantMin": 0.2,
-    "constantMax": 0.5,
+    "constantMax": 0.6,
     "multiplier": 1
   },
   {

+ 9 - 3
assets/module_storm_sunder/Script/Component/TornadoComponent.ts

@@ -68,6 +68,7 @@ export class TornadoComponent extends Component {
         this.tigger.on('onTriggerEnter', this.onTriggerEnter, this);
         this.tigger.on('onTriggerStay', this.onTriggerStay, this);
         this.tigger.on('onTriggerExit', this.onTriggerExit, this);
+        EventDispatcher.instance.on(GameEvent.EVENT_STORM_RESET, this.onStormReset, this);
     }
 
     private initializeRigidBody(): void {
@@ -96,7 +97,7 @@ export class TornadoComponent extends Component {
         this.nickName = userModel.nickName;
         this.height = userModel.game_tornado_base_height;
         this.speed = Math.round((this.speed / 2) * 100) / 100;
-        this.speed = this.speed * 1.5;//测试
+        this.speed = this.speed * 1.8;//测试
 
         // console.log(`玩家的速度:${this.speed}`);
         this.playerInfo = {
@@ -104,7 +105,7 @@ export class TornadoComponent extends Component {
             level: this.currentLv,
         }
 
-        this.node.setScale(1, 1, 1);
+        // this.node.setScale(1, 1, 1);
         this.updateCameraView();
     }
 
@@ -335,6 +336,11 @@ export class TornadoComponent extends Component {
         Effect2DUIMgr.inst.addLevelUp(this.node);
     }
 
+    private onStormReset() {
+        if (!this.particleSystem) return;
+        this.particleSystem.startSizeX.constantMax = 1;
+        this.particleSystem.startLifetime.constantMax = 0.6;
+    }
     //变大体积
     private grow() {
         //体积=基础体积×(1+等级×百分比)
@@ -362,7 +368,7 @@ export class TornadoComponent extends Component {
 
     private updateCameraView() {
         const sence = director.getScene();
-        const view = 30 + this.currentLv * 1.5;
+        const view = 30 + this.currentLv * 2;
         sence.emit(EasyControllerEvent.CAMERA_ZOOM, view);
     }
 

+ 2 - 0
assets/module_storm_sunder/Script/Enum/GameEvent.ts

@@ -3,6 +3,8 @@ export class GameEvent {
     static readonly EVENT_UI_INITILIZE = 'EVENT_UI_INITILIZE';
     /** 游戏开始*/
     static readonly EVENT_GAME_START = 'EVENT_GAME_START';
+    /**龙卷风重置*/
+    static readonly EVENT_STORM_RESET = 'EVENT_STORM_RESET';
 
     /** 开局特效*/
     static readonly EVENT_GAME_START_EFFECT = 'EVENT_GAME_START_EFFECT';

+ 4 - 1
assets/module_storm_sunder/Script/Manager/PlayerMgr.ts

@@ -7,6 +7,8 @@ import { AttributeBonusMgr } from "./AttributeBonusMgr";
 import { Tableai_config } from "db://assets/module_basic/table/Tableai_config";
 import { MapMgr } from "./MapMgr";
 import { EasyControllerEvent } from "db://assets/core_tgx/easy_controller/EasyController";
+import { EventDispatcher } from "db://assets/core_tgx/easy_ui_framework/EventDispatcher";
+import { GameEvent } from "../Enum/GameEvent";
 
 const res = [
     "Prefabs/Storm",
@@ -256,9 +258,10 @@ export class PlayerMgr {
     async reset() {
         this.destroyOtherAI();
         let tornado = await this.getTornadoNode();
-        tornado.scale = new Vec3(1, 1, 1);
+        // tornado.scale = new Vec3(1, 1, 1);
         const sence = director.getScene();
         sence.emit(EasyControllerEvent.CAMERA_ZOOM, 30);
+        EventDispatcher.instance.emit(GameEvent.EVENT_STORM_RESET);
         this.aiIndex = 0;
     }