Garry's Mod

Garry's Mod

Dragon Breath
7개 중 1~7개 표시 중
업데이트: 2024년 9월 5일 오전 9시 28분
작성자: Zelda Fanatic

1. Optimized Particle Emitter
Original: Created a new ParticleEmitter inside the Render function on every frame.
Improved: Moved the particle emitter creation to the Init function and reused it throughout the effect. This reduces performance overhead since creating a new emitter each frame is unnecessary.
Clean-up: The emitter is now cleaned up in the Think function when the effect is done, preventing memory leaks.
2. Simplified Code in Render Function
Original: The pos variable (fireball starting position) was assigned twice, unnecessarily.
Improved: Removed redundant assignment. Now, pos = self.wep:GetShootPosition() is assigned just once, making the code cleaner.
3. Enhanced Particle Effects
Original: Particles had minimal variation and didn’t look as dynamic.
Improved:
Changed the particle material to "effects/fire_cloud1" for a more fire-like texture.
Increased particle size (SetStartSize and SetEndSize) to make the fire breath more visible.
Adjusted the gravity (SetGravity) to -900 for a more realistic falling fire effect.
Lowered air resistance to 800 for faster particle movement, making the fire feel more intense.
4. Improved Dynamic Lighting
Original: Lighting was static, with fixed color and brightness.
Improved:
Made the lighting flicker slightly by randomizing the red and green values (dLight.r and dLight.g).
Added random flicker to the brightness (dLight.Brightness) to simulate firelight more realistically.
Shortened the light's lifetime (dLight.DieTime) to 0.15 seconds for a quicker flicker effect.

업데이트: 2020년 10월 1일 오후 3시 53분

Added fly to right click, not you can fly and kill people from above

업데이트: 2019년 5월 19일 오후 12시 42분

Fixed Stuff: added dragon type sounds on deploy and undeploy so people know you're about to get serious. REQUIRES VFIRE! without Vfire the swep will not function as intended.

업데이트: 2019년 4월 18일 오후 7시 44분

None Provided

업데이트: 2018년 9월 11일 오후 4시 36분

None Provided

업데이트: 2018년 9월 11일 오후 4시 26분

None Provided

업데이트: 2018년 8월 30일 오후 1시 58분