Support | News | Classic | F.A.Q. | Discord | Discussions | Wiki | Roadmap

so i wus playing around with some ones made that i downloaded (vins custom parts mod)and i found a gun called a sniper cannon but i noticed it had a fire chance thing and i wus wundering if its possibal if some one could help me cut that part of the code and splice it into what ever modded gun i need it for i wus just wundering this cuz i like playing with the fire Mackinac of the game and its just a pain to shoot the ship untill it sets on fire so i wus wundering if some one could give me the part of the code that makes stuff set on fire so i can make a gun that dose like no damge but sets every thing it touches on fire i would also LOVE to know where to put this potion of code that makes the thing set stuff on fire :3

    lucifer2020 wundering if some one could give me the part of the code that makes stuff set on fire

    It is associated with bullets and shots. Refer to vanilla examples like Canon large bullet at Cosmoteer installed folder
    Data\shots\bullet_large\bullet_large.txt
    Look for something like this

    Hit
    {
    	...
    	PenetratingOperational
    	{
    		HitEffects
    		[
    			...
    			{
    				Type = Fire
    				FireChance = .4
    			}
    		]
    		...
    	}
    }

    In this case, chance of causing fire is one of the HitEffects associated with PenetratingOperational of a large canon bullet.

    Creating own mod to realize your fiery vision is part of the fun. Happy investigating~

    FireChance is the chance the weapon has of setting fire when a certain hit type is executed

      clojelo thanks mate

        i have one last request when i tryed to put that part of code into a wepon from a mod it coused errors so if you dont mind could you help me out

        ID = Changerboy.laser_mini_gun_shot
        Range = 450
        IdealRange = [60, 150]
        IdealRadius = [5, 50]
        Speed = 130

        Components
        {
        Physics
        {
        Type = CirclePhysics
        Radius = 0.01
        Density = 0.1
        }

        Death
        {
        	Type = DeathByLifetime
        }
        
        Sprite
        {
        	Type = AnimatedSprite
        	Animation
        	{
        		AtlasSprite
        		{
        			Texture
        			{
        				File = "laser.png"
        				SampleMode = Linear
        				MipLevels = max
        			}
        			Size = [1.75, 1.75]
        		}
        		FrameCount = 8
        		FrameSize = [128, 128]
        		FramesPerRow = 2
        		FramesPerSecond = 60
        	}
        }
        
        MediaEffects
        {
        	Type = MediaEffects
        	InheritVelocityFrom = Physics
        	MediaEffects
        	[
        		&<../../../commen_effects/particles/laser_glow_green.txt>
        	]
        }
        
        Hit
        {
        	Type = PenetratingHit
        	PhysicsComponent = Physics
        	PenetratesShields = false
        	Penetration = 25000
        	PenetrationSpeed = 150
        
        	HitShield
        	{
        		HitEffects
        		[
        			{
        				Type = Damage
        				Damage = 150
        				Filter
        				{
        					Ships = false
        					Shields = true
        					Bullets = false
        				}
        			}
        			{
        				Type = Impulse
        				Impulse = 2.5
        			}
        		]
        
        		MediaEffects = &../HitOperational/MediaEffects
        	}
        	HitOperational
        	{
        		HitEffects
        		[
        			{
        				Type = Damage
        				Damage = 150
        				TreatShieldAsPart = true
        				Filter
        				{
        					Ships = true
        					Shields = false
        					Bullets = false
        				}
        			}
        			{
        				Type = Impulse
        				Impulse = 2.5
        			}
        		]
        
        		MediaEffects
        		[
        			&<../../../commen_effects/particles/laser_hit_green.txt>
        			&<../../../commen_effects/particles/laser_flash_green.txt>
        			&<../../../commen_effects/particles/laser_sparks_green.txt>
        
        			: /BASE_SOUNDS/AudioExterior
        			{
        				Sound = "hit.wav"
        				Volume = .4
        				SpeedVariation = .4
        			}
        
        			: /BASE_SHAKE
        			{
        				ShakeAmount = .03
        				Duration = .3
        			}
        		]
        	}
        	HitStructural
        	{
        		HitEffects
        		[
        			{
        				Type = Damage
        				Damage = 150
        				TreatShieldAsPart = true
        				Filter
        				{
        					Ships = true
        					Shields = false
        					Bullets = false
        				}
        			}
        			{
        				Type = Impulse
        				Impulse = 2
        			}
        		]
        
        		MediaEffects
        		[
        			&<../../../commen_effects/particles/laser_hit_struct_green.txt>
        
        			: /BASE_SOUNDS/AudioExterior
        			{
        				Sound = "hit.wav"
        				Volume = .3
        				SpeedVariation = .4
        			}
        		]
        	}
        	PenetratingOperational
        	{
        		HitEffects
        		[
        			{
        				Type = Damage
        				Damage = 75
        				TreatShieldAsPart = true
        				Filter
        				{
        					Ships = true
        					Shields = false
        					Bullets = false
        				}
        			}
        		]
        		
        		MediaEffects
        		[
        		
        		]
        	}
        	PenetratingStructural = &PenetratingOperational
        	FinishedPenetratingOperational = &PenetratingOperational
        	FinishedPenetratingStructural = &PenetratingOperational
        }

        }
        thats the shot for the wepon could you please add the fire thing into it please im not to good at this stuff just small things

          Write a Reply...