Page 1 of 1

Kills by my black hole doesn't count as frags?

Posted: Thu Oct 06, 2016 10:42 am
by AtomicLugia
It's a classic A_SpawnItemEx frustration.

This time I want to make a black hole bomb, that explodes after a time and creates a black hole that sucks all monsters and other players in (including yourself). This works but if any player gets killed by it, it doesn't count as a frag by me. It counts that they're dying for no reason. WTF?

Here's the bomb:
https://dl.dropboxusercontent.com/u/312 ... leBomb.zip

Use it in Zandronum (3.0 alpha) and spawn it by typing "Summon FusedSingularityBomb". It creates a black hole and it's not a bad idea to take cover. Try this in a deathmatch (map 32) with bots and watch as they're 'dying for no reason'. If you directly spawn the black hole by typing "Summon BlackHole", it does work, however.

Here is how it works:
After the bomb is placed it explodes in 5 seconds, creating a new actor (which is a black hole) via A_SpawnItemEx. This black hole is constantly sucking nerby enemies in and damaging them.

Did I miss something?

Re: Kills by my black hole doesn't count as frags?

Posted: Thu Oct 06, 2016 10:55 am
by ZZYZX
If BlackHole is a projectile, it's AAPTR_TARGET should be set to the source of projectile (i.e. the player). Otherwise, AAPTR_MASTER should be set to the player. If neither of these is set, the projectile is counted as created by the world and the player won't get frags. Check your A_SpawnItemEx flags in the code that spawns BlackHole from FusedSingularityBomb.

cba opening the archive, one of the above suggestions should help.

Re: Kills by my black hole doesn't count as frags?

Posted: Thu Oct 06, 2016 11:48 am
by AtomicLugia
I tried this:

Code: Select all

Spawn:
SBOM BCDEF 6
SBOM G 3 Bright A_PlayWeaponSound("BHBomb/Activate")
SBOM HIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHI 3 Bright
SBOM GHIGHIGHIGHIGHIGHIGHIGHIGHIGHIGHI 1 Bright
SBOM JK 2 Bright
SBOM K 0 Bright A_SpawnItemEx("BlackHole",32,0,0,0,0,0,0,SXF_TRANSFERPOINTERS)
Stop
I tried SXF_TRANSFERPOINTERS and it didn't help. Same crap. Sorry.

Should the A_SpawnItemEx be placed in the Death state? Does the black hole needs certain actor flags?

Re: Kills by my black hole doesn't count as frags?

Posted: Thu Oct 06, 2016 11:59 am
by Ivan
Try adding +MISSILE flag.

Re: Kills by my black hole doesn't count as frags?

Posted: Thu Oct 06, 2016 12:17 pm
by AtomicLugia
Okay, I made it work. I just used A_CustomMissile as a workaround.