EtG Modding Guide
  • ETG Modding Guide
  • Getting started
    • Modding EtG: Installing Mods
    • Modding EtG: Creating a Mod
    • Uploading a Mod
    • Useful Tools
      • Using IlSpy
  • Making An Item
    • Creating A Passive
    • Creating An Active
    • Creating An Ammolet
    • Creating A Guon
    • Synergies
  • Making a Gun
    • Creating A Gun
      • Setting Up Gun Sprite Folders
      • Creating Gun Jsons/Jtk2ds
        • Pixel Measurement Conversions
    • Setting Up Projectiles
      • Adding Components To A Projectile
      • Projectile HitEffects (Visual Effects)
      • Adding status effects to a projectile
    • Continuous Fire Animations
    • Gun Ammo Types
  • Custom Characters
    • Creating A Standalone Custom Character
  • Making a Floor
    • Introduction
    • Setup
    • Making The Dungeon
    • Tileset
    • Rooms
    • Making the flow
    • Making the Entrance
    • All Files
  • Text, Text Boxes, Etc
    • Textboxes
    • Text Formatting
  • Sounds
    • Using Custom Sounds
    • Customising Gun Sounds
    • Basegame Sound List
    • wwise Sound Dump
  • Misc
    • Making Asset bundles
    • Assetbundles: How-To
    • How to create a hook
    • Creating A Command
    • Subscribing Methods to Actions
    • Reversing Player Controls
    • Undodgeable Projectiles
    • Creating An Enemy
  • Shaders
    • Creating Shaders
  • All things Spriting
    • Important Sprite Creation Information.
    • Importing a Sprite To Visual Studios
  • Monobehaviour Documentation
    • BounceProjModifier
    • PierceProjModifier
    • KeyProjModifier
    • CompanionFollowPlayerBehaviour
  • Various Lists of IDs, Sounds, Etc.
    • List of Item and Gun IDs
    • Enemy Guids
    • List of Base Game Synergies
    • dfSpriteList
    • All Custom Ammo Types
    • Gun .Json Dump
  • OFF TOPIC MEMES
    • Modders Anthem
Powered by GitBook
On this page

Was this helpful?

  1. Making a Gun
  2. Setting Up Projectiles

Adding status effects to a projectile

PreviousProjectile HitEffects (Visual Effects)NextContinuous Fire Animations

Last updated 9 months ago

Was this helpful?

Difficulty: 1/10

adding status effects to a projectile is extremely easy and all follow the same method, with the small exception of stun. First, you get your projectile, then you set whether it applies an effect with a bool to true. Finally, you specify what chance there should be for it to apply the effect. The chance should be a value less than or equal to one. 1 = 100%, 0.45 = 45%, 0.73 = 73%, etc.

Below is a list of all the possible effects:

//bleed
projectile.AppliesBleed = true;
projectile.BleedApplyChance = 0.5f;

//Charm
projectile.AppliesCharm = true;
projectile.CharmApplyChance = 0.5f;

//cheese
projectile.AppliesCheese = true;
projectile.CheeseApplyChance = 0.5f;
      
//fire
projectile.AppliesFire = true;
projectile.FireApplyChance = 0.5f; 
     
//freeze
projectile.AppliesFreeze = true;
projectile.FreezeApplyChance = 0.5f;

//poison
projectile.AppliesPoison = true;
projectile.PoisonApplyChance = 0.5f;

//stun
projectile.AppliesStun = true;
projectile.StunApplyChance = 0.5f;
projectile.AppliedStunDuration = 2f;

as you can clearly see they all function the same way, with the only exception being stun, which needs a value for how long the enemy should