tModLoader  0.12 Alpha
A mod to make and play Terraria mods
Terraria.ModLoader.ModWaterStyle Class Referenceabstract

Represents a style of water that gets drawn, based on factors such as the background. This is used to determine the color of the water, as well as other things as determined by the hooks below. More...

Inherits Terraria.ModLoader.ModTexturedType.

Public Member Functions

virtual Color BiomeHairColor ()
 Allows you to change the hair color resulting from the biome hair dye when this water style is in use. More...
 
abstract int ChooseWaterfallStyle ()
 The ID of the waterfall style the game should use when this water style is in use. More...
 
abstract int GetDropletGore ()
 The ID of the gore that represents droplets of water falling down from a block. More...
 
abstract int GetSplashDust ()
 The ID of the dust that is created when anything splashes in water. More...
 
virtual void LightColorMultiplier (ref float r, ref float g, ref float b)
 Allows you to modify the light levels of the tiles behind the water. The light color components will be multiplied by the parameters. More...
 
sealed override void SetupContent ()
 If you make a new ModType, seal this override, and call SetStaticDefaults in it. More...
 
- Public Member Functions inherited from Terraria.ModLoader.ModType
virtual bool IsLoadingEnabled (Mod mod)
 Allows you to stop Mod.AddContent from actually adding this content. Useful for items that can be disabled by a config. More...
 
virtual void Load ()
 Allows you to perform one-time loading tasks. Beware that mod content has not finished loading here, things like ModContent lookup tables or ID Sets are not fully populated. More...
 
virtual void SetStaticDefaults ()
 Allows you to modify the properties after initial loading has completed. More...
 
virtual void Unload ()
 Allows you to safely unload things you added in Load. More...
 

Protected Member Functions

sealed override void Register ()
 If you make a new ModType, seal this override. More...
 

Properties

virtual string BlockTexture [get]
 
int Slot [get, set]
 The ID of the water style. More...
 
- Properties inherited from Terraria.ModLoader.ModTexturedType
virtual string Texture [get]
 The file name of this type's texture file in the mod loader's file space. More...
 
- Properties inherited from Terraria.ModLoader.ModType
string FullName [get]
 The internal name of this, including the mod it is from. More...
 
Mod Mod [get, set]
 The mod this belongs to. More...
 
virtual string Name [get]
 The internal name of this. More...
 
- Properties inherited from Terraria.ModLoader.IModType
string FullName [get]
 => $"{Mod.Name}/{Name}" More...
 
Mod Mod [get]
 The mod this belongs to. More...
 
string Name [get]
 The internal name of this instance. More...
 

Detailed Description

Represents a style of water that gets drawn, based on factors such as the background. This is used to determine the color of the water, as well as other things as determined by the hooks below.

Member Function Documentation

◆ BiomeHairColor()

virtual Color Terraria.ModLoader.ModWaterStyle.BiomeHairColor ( )
virtual

Allows you to change the hair color resulting from the biome hair dye when this water style is in use.

◆ ChooseWaterfallStyle()

abstract int Terraria.ModLoader.ModWaterStyle.ChooseWaterfallStyle ( )
pure virtual

The ID of the waterfall style the game should use when this water style is in use.

◆ GetDropletGore()

abstract int Terraria.ModLoader.ModWaterStyle.GetDropletGore ( )
pure virtual

The ID of the gore that represents droplets of water falling down from a block.

◆ GetSplashDust()

abstract int Terraria.ModLoader.ModWaterStyle.GetSplashDust ( )
pure virtual

The ID of the dust that is created when anything splashes in water.

◆ LightColorMultiplier()

virtual void Terraria.ModLoader.ModWaterStyle.LightColorMultiplier ( ref float  r,
ref float  g,
ref float  b 
)
virtual

Allows you to modify the light levels of the tiles behind the water. The light color components will be multiplied by the parameters.

◆ Register()

sealed override void Terraria.ModLoader.ModWaterStyle.Register ( )
protectedvirtual

If you make a new ModType, seal this override.

Implements Terraria.ModLoader.ModType.

◆ SetupContent()

sealed override void Terraria.ModLoader.ModWaterStyle.SetupContent ( )
virtual

If you make a new ModType, seal this override, and call SetStaticDefaults in it.

Reimplemented from Terraria.ModLoader.ModType.

Property Documentation

◆ Slot

int Terraria.ModLoader.ModWaterStyle.Slot
getset

The ID of the water style.