MantisBT - Zandronum
View Issue Details
0003204Zandronum[All Projects] Bugpublic2017-07-27 19:562018-04-20 07:09
HexaDoken 
Leonard 
normalminoralways
resolvedfixed 
MicrosoftWindowsXP/Vista/7
3.0-beta 
3.13.1 
0003204: A_SetTranslucent doesn't work online when called from custominventory that is A_RadiusGive-n to a monster
...Or something. I'll confess that I'm not 100% confident what's going on here.

I've got fed up with fighting stealth monsters and created a weapon to combat them. It works like this: primary fire throws a flare that makes all stealth monsters around it blink into visibility every so often; secondary fire throws a super flare that just strips stealth entirely from all monsters that come into range.

From a technical side, the flares use A_RadiusGive to give monsters in range a CustomInventory item that in the pickup state checks for stealth flag and disables it while also using A_SetTranslucent to make the monster opaque.

Offline, it works perfectly.

Online, A_SetTranslucent appears to do nothing.

I've at first thought that A_SetTranslucent just doesn't work entirely, so I slapped together a monster that rapidly calls A_SetTranslucent in it's spawn state, but THAT works perfectly. So overall, I'm not quite sure what is happening. It's only in this specific interaction I've found it to break apart.

I've fixed the issue by replacing A_SetTranslucent with a script that uses SetActorProperty, which works fine both offline and online, but I thought somebody should still know about this.
1) summon a stealth monster
2) throw a flare near it
3) observe the result

Offline: normal flare should make stealth monsters nearby blink into visibility every second or so; super flares should just make them permanently visible.

Online: normal flare does nothing; super flare removes the stealth flag without changing monster's alpha, which makes it permanently stuck at whatever level of visibility it was at before, which is usually "completely invisible"
No tags attached.
? antistealthflare.pk3 (11,596) 2017-07-27 19:56
/tracker/file_download.php?file_id=2157&type=bug
? CustomInventory_SetTranslucent.wad (743) 2017-07-27 23:52
/tracker/file_download.php?file_id=2158&type=bug
Issue History
2017-07-27 19:56HexaDokenNew Issue
2017-07-27 19:56HexaDokenFile Added: antistealthflare.pk3
2017-07-27 23:52KorshunFile Added: CustomInventory_SetTranslucent.wad
2017-07-27 23:54KorshunNote Added: 0018109
2017-07-27 23:54KorshunNote Edited: 0018109bug_revision_view_page.php?bugnote_id=18109#r10830
2017-07-27 23:54KorshunNote Edited: 0018109bug_revision_view_page.php?bugnote_id=18109#r10831
2017-07-28 09:57HexaDokenNote Added: 0018111
2017-07-28 10:04HexaDokenNote Edited: 0018111bug_revision_view_page.php?bugnote_id=18111#r10833
2017-10-04 16:13LeonardNote Added: 0018432
2017-10-04 16:14LeonardStatusnew => needs review
2017-10-04 16:14LeonardTarget Version => 3.1
2017-10-08 13:26Torr SamahoNote Added: 0018482
2017-10-08 13:26Torr SamahoAssigned To => Leonard
2017-10-08 13:26Torr SamahoStatusneeds review => needs testing
2018-04-18 06:29StrikerMan780Note Added: 0019171
2018-04-20 07:09DuskStatusneeds testing => resolved
2018-04-20 07:09DuskFixed in Version => 3.1
2018-04-20 07:09DuskResolutionopen => fixed

Notes
(0018109)
Korshun   
2017-07-27 23:54   
Does this bug have the same mechanism as'https://zandronum.com/tracker/view.php?id=3201 [^]' ? I uploaded a much simpler test wad, which is edited StopSound wad.

(0018111)
HexaDoken   
2017-07-28 09:57   
(edited on: 2017-07-28 10:04)
Probably not. I modified my custominventory item really quickly to just call A_SetTranslucent(0.5) and nothing else, and giving it to myself via console sets alpha properly both offline and online, but throwing it into a monster's face only changes alpha offline, not online.

So unless I misunderstood the nature of your case, it seems unrelated.

EDIT: only now noticed your wad and tested it. As provided, it doesn't work online. However, if I edit your custominventory items to end their Pickup states with Stop instead of Fail, they will work online.

Curious, that.

(0018432)
Leonard   
2017-10-04 16:13   
PR.
(0018482)
Torr Samaho   
2017-10-08 13:26   
Thanks! I added you patch.
(0019171)
StrikerMan780   
2018-04-18 06:29   
Tested this online and off with the latest 3.1 build and antistealthflare.pk3. Works, stealth monsters show up when a flare is put down, and the alt-fire makes them visible permanently like they should.