I want blood drops to disappear on the water

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked
User avatar
Jekyll Grim Payne
Global Moderator
Posts: 1120
Joined: Mon Jul 21, 2008 4:08 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)
Contact:

I want blood drops to disappear on the water

Post by Jekyll Grim Payne »

Recently I released Beautiful Doom 4.7. And still I can't find a way to make blooddrops disappear on liquid surfaces. The code of the blooddrops looks like this:

Code: Select all

actor BloodDrop
{
+MISSILE
+NOBLOCKMAP
+DROPOFF
+NOTELEPORT
+FORCEXYBILLBOARD
+NOTDMATCH
-NOGRAVITY
radius 1
height 1
mass 1
damage 0
scale 0.7
gravity .7
speed 3
deathsound "gibs/blooddrop"
renderstyle TRANSLUCENT
alpha 1.0
decal BloodSplat
states
	{
	spawn:
		BLOD ABCDEF 1 A_FadeOut(0.01) // this way it disappears if it's falling down a long pit, to save memory
		wait
	death:
		TNT1 A 0
		TNT1 A 0 A_Scream
		TNT1 A 1 A_ChangeFlag("CORPSE",1) // this way it disappears if it hits a wall, without showing splash sequence
		wait
	crash: // the splash sequence is shown here when hitting the floor
		TNT1 A 0
		TNT1 A 0 A_JumpIf(WaterLevel > 0, 7) // tried to use this, but seems like it only works on deep water, not on terrain water
		TNT1 A 0 A_ChangeFlag("NOBLOCKMAP",0)
		TNT1 A 0 A_Jump(128,2,3,4)
		BSPT A -1
		stop
		BSPT B -1
		stop
		BSPT C -1
		stop
		BSPT D -1
		stop
		TNT1 A 1
		stop
	}
}

How do I make it disappear on liquid surfaces without making it a bouncing projectile?
Last edited by Jekyll Grim Payne on Sat Dec 12, 2009 7:28 am, edited 2 times in total.
User avatar
Dark-Assassin
Posts: 743
Joined: Thu Mar 19, 2009 3:40 am
Location: South Australia

Re: I want blood drops to disappear on the water

Post by Dark-Assassin »

try the flag

Code: Select all

+EXPLODEONWATER
User avatar
Jekyll Grim Payne
Global Moderator
Posts: 1120
Joined: Mon Jul 21, 2008 4:08 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)
Contact:

Re: I want blood drops to disappear on the water

Post by Jekyll Grim Payne »

Tried before that. It's not something that could help. +EXPLODEONWATER used on usual projectiles calls the same state which is called when hitting floor, i.e. either Death or Crash. It actually only works on bouncing projectiles which usually disappear on the water, but with this flag they enter their Death state instead. So no, it's not that.
Gez
 
 
Posts: 17946
Joined: Fri Jul 06, 2007 3:22 pm

Re: I want blood drops to disappear on the water

Post by Gez »

For terrain-based water, just give it a floorclip at least at tall as the graphics. That will hide it completely.

For swimmable water (Boom or 3D floor), you can use an [wiki]A_JumpIf[/wiki]([wiki=DECORATE expressions]waterlevel > 0[/wiki], "Disappear") instruction in its Death state, with a Disappear state that's something like TNT1 A 0 followed by Stop so it removes the actor.
User avatar
Jekyll Grim Payne
Global Moderator
Posts: 1120
Joined: Mon Jul 21, 2008 4:08 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)
Contact:

Re: I want blood drops to disappear on the water

Post by Jekyll Grim Payne »

Man, could you PLEASE read the question before giving an answer? I already have jump with waterlevel check and I know what it does work for and what it doesn't. As for floorclip, I have a projectile, not a decorative object and not a monsters, +FLOORCLIP doesn't work on them, because projectiles don't stand on the floor.
User avatar
NeuralStunner
 
 
Posts: 12328
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Windows 11
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: I want blood drops to disappear on the water

Post by NeuralStunner »

So don't make it a projectile. Use [wiki]A_CheckFloor[/wiki] instead.
User avatar
Jekyll Grim Payne
Global Moderator
Posts: 1120
Joined: Mon Jul 21, 2008 4:08 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)
Contact:

Re: I want blood drops to disappear on the water

Post by Jekyll Grim Payne »

Are you implying that A_CheckFloor doesn't consider water floor as floor? Anyway, though, to recommend me to make it not a projectile is not a very good advice. For many, many reasons. But in short, it'd result in losing a lot of other important features of this blood.

Hey, developers! Do you still think that +VANISHONWATER flag is a bad idea?
User avatar
NeuralStunner
 
 
Posts: 12328
Joined: Tue Jul 21, 2009 12:04 pm
Preferred Pronouns: No Preference
Operating System Version (Optional): Windows 11
Graphics Processor: nVidia with Vulkan support
Location: capital N, capital S, no space
Contact:

Re: I want blood drops to disappear on the water

Post by NeuralStunner »

Jekyll Grim Payne wrote:Are you implying that A_CheckFloor doesn't consider water floor as floor?
No. All flats are "floors". This is only meant as a way to check floor collision without being a missile.

If you'd rather have noisy splashes, try increasing the Mass of the blood actors to about 100 or so.
User avatar
Jekyll Grim Payne
Global Moderator
Posts: 1120
Joined: Mon Jul 21, 2008 4:08 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)
Contact:

Re: I want blood drops to disappear on the water

Post by Jekyll Grim Payne »

Ah, you see, the splashes are not the issue. Their calling is not connected to what I want. I want the blood drops to VANISH whey they hit water. Objects call splashes when they hit water, but that doesn't mean they vanish in this case. So for now bloodrops do call splashes, but they stay on the water. The only kind of projectiles that vanish when hitting the water in present (G)ZDoom are bouncing projectiles.
User avatar
XutaWoo
Posts: 4005
Joined: Sat Dec 30, 2006 4:25 pm
Location: beautiful hills of those who are friends
Contact:

Re: I want blood drops to disappear on the water

Post by XutaWoo »

You could make them bounce, and then give them a bounce count of 0.
User avatar
SFJake
Posts: 531
Joined: Sat Nov 03, 2007 11:28 am

Re: I want blood drops to disappear on the water

Post by SFJake »

This is the nashgore blood..

Touching any liquid it splashes and disappears.

Code: Select all

actor NashGore_FlyingBlood
{
 game Doom
 scale 0.75
 health 1
 radius 8
 height 1
 mass 1
 +CORPSE
 +NOTELEPORT
 +NOBLOCKMAP
 states
 {
 Spawn:
  TNT1 A 0 A_CheckSight("Cheap")
  FBLD A 1 A_SpawnItem("NashGore_FlyingBloodTrail",0,0,0,1)
  FBLD A 1 A_JumpIf(waterlevel > 1, "Remove")
  loop
 Cheap:
  FBLD A 8 A_SpawnItem("NashGore_FlyingBloodTrail",0,0,0,1)
  FBLD A 1 A_JumpIf(waterlevel > 1, "Remove")
  loop
 Crash:
  TNT1 A 1 A_SpawnItem("NashGore_BloodSpot",0,0,0,1)
  stop
   Remove: // Anti-Lag - Removes blood in water.
      NULL A 0 
        stop
 }
}
User avatar
Dark-Assassin
Posts: 743
Joined: Thu Mar 19, 2009 3:40 am
Location: South Australia

Re: I want blood drops to disappear on the water

Post by Dark-Assassin »

actually, it doesnt with me.
all the splash gibs, don't but all the rest are bouncing.
Locked

Return to “Editing (Archive)”