tModLoader

tModLoader

Not enough ratings
ModeGoop (ModLiquid)
   
Award
Favorite
Favorited
Unfavorite
Mod Features: Library, Quality Of Life
Mod Side: Both
tModLoader Version: 1.4.4
Language: English
File Size
Posted
Updated
1.044 MB
13 Feb @ 3:16pm
17 Jul @ 8:55pm
13 Change Notes ( view )

Subscribe to download
ModeGoop (ModLiquid)

Description
A mod that lets you make custom liquids more easily. This does not work with other mods nor does it work in multiplayer. This is used for the mods "Glue" and "More Liquids"

How To Use[forums.terraria.org]
Glue Mod
More Liquids Mod



Mod Content
Items
  • Example Liquid Bucket
  • Bottled Example Liquid
  • Golden Example Liquid Bucket
  • Grav0 Bucket
  • Grav1 Bucket
  • Grav2 Bucket
  • Grav8 Bucket
  • Liquid63 Bucket
  • Test Item
  • BottledExampleLiquid
  • ExampleLiquidBucket
  • GoldenExampleLiquidBucket
  • BottomlessGoldLiquidBucket
  • BottomlessCopperLiquidBucket
  • BottomlessRedGoldLiquidBucket
Liquids
  • Grav0 (ModeGoop_grav0Test)
  • Grav1 (ModeGoop_grav1Test)
  • Grav2 (ModeGoop_grav2Test)
  • Grav8 (ModeGoop_grav8Test)
  • ExampleLiquid
  • GoldLiquid
  • CopperLiquid
  • RedGoldLiquid

Crossed out items are for testing and are unobtainable


Originally posted by tModLoader ModeGoop:
Developed By SPRING MOLE?
24 Comments
Kishin 28 Jul @ 11:10am 
I see. It seems that I should use x y to determine if the updated position is the liquid surface
PumpkiNot  [author] 28 Jul @ 10:19am 
Looks like "isPoolSurface" is only used for retro lighting and is always false in normal lighting
Kishin 28 Jul @ 9:55am 
"public virtual void ParticleEffects(UnifiedRandom rand, int x, int y, bool isPoolSurface)" What is the function of the fourth parameter 'isPoolSurface' in? I thought this parameter was used to determine whether the tile is on a liquid surface, but it seems that regardless of whether the updated tile[x,y] is on a liquid surface, this parameter is false. So, this parameter has other meanings?
Kishin 21 Jul @ 11:23am 
got it, thanks!
PumpkiNot  [author] 21 Jul @ 11:20am 
Liquids that share a bit in their return values of that function will not "merge" into a tile when touching. To use the function, OR together all the SolidityChannelValue() return values for all the liquids you wish for the liquid not to merge with ( including itself! ). Here is an example:

public override ulong SolidifyChannel()
{
return base.SolidifyChannel()
| ModContent.GetInstance<MyOtherLiquid>().SolidifyChannelValue()
| ModeWater_Water.instance.SolidifyChannelValue();
}
Note that, by default, SolidifyChannel() returns the same thing as SolidifyChannelValue(), which is why the base is called here.
Kishin 21 Jul @ 11:05am 
What is SolidifyChannel for?
PumpkiNot  [author] 17 Jul @ 8:57pm 
You can now, but, unfortunately, liquid mixing doesn't work as smoothly as you'd like and gets quite messy if the all the involved liquids don't have the same "density"
Kishin 16 Jul @ 8:58pm 
Is there any way to merge liquids into liquid instead of tiles? I hope to achieve the reaction of generating liquid. Is there any function in lib that allows me to directly implement this function?
Or can I only achieve this function by making the liquid generate a temporary tile that will immediately convert to liquid?
PumpkiNot  [author] 12 Jul @ 12:10pm 
You could also use ModLiquid.OnWetCollied(Player ply) alongside ModPlayer.ResetEffects(), which should have the same effects since OnWetCollied() is called right after the player's current liquid is determined, and right before the splash particles are created.