Mutator "Gift From Decoration" for MonsterHunt

Search, find and discuss about Mutators!
Buggie
Godlike
Posts: 2148
Joined: Sat Mar 21, 2020 5:32 am

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Buggie »

I know about this "feature". Already investigate that. IIRC, it specific to your server and caused by fact spawn new copy of weapon on pickup or throw (not remember details) instead of direct usage it. For normal usage all goes ok.
But you spawn copy of weapon and destroy old.

It be long time ago, so I not remember details.   
Auto merged new post submitted 1 hour 2 minutes later
Ah. now I remember. It be part of code about death. On death you spawn copy of inventory, instead of drop exists weapons. Obviously this lead to destroy link to InventoryDestroyer. So weapon goes be permanent now.
Unfortunately there nothing what I can do with that.   
Auto merged new post submitted 6 minutes later
Look at bDropWeaponsOnDeath, DiscardInventory and DropWeapon. Last one spawn permanent copy.

I can suggest you few solutions.
1. Drop real weapon, not copy.
2. Drop copy only of real weapon, not for gifted.
3. Drop copy for all weapons, but for gifted search and replace link to it in InventoryDestroyer.
User avatar
Barbie
Godlike
Posts: 2602
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Barbie »

Ah, never touched that part of code. I suppose that function DropWeapon() was introduced because with the stock code only the current holding weapon is dropped. BTW that function can be found in some game controllers of MonsterHunt packages like in KHMBase.uc, MH2Base.uc, KHMBase.uc.

It's now fixed by dropping original weapon in my game controller.
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett
User avatar
Barbie
Godlike
Posts: 2602
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Barbie »

Is it possible to
1) Make the hard coded check time of currently 0.1 sec configurable?
2) Make counter voice and number configurable?
3) Set spawned item's LifeSpan? With that I can easily show remaining time in HUD.
<EDIT>
Not to forget: 4) possibility of dropping any Actor, not only inventory
</EDIT>
Ofc I also could do the changes and send you the result.
"Multiple exclamation marks," he went on, shaking his head, "are a sure sign of a diseased mind." --Terry Pratchett
Buggie
Godlike
Posts: 2148
Joined: Sat Mar 21, 2020 5:32 am

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Buggie »

v0.5
- Add more config options (see ini file)
- Set LifeSpan time (reset on last second, for avoid race condition)
- Now can be spawned any Actor class, not Inventory only. However, items, which not able be owned (pick up), will be eat server resources if LifeSpan for them more then 0.

Update in first post: viewtopic.php?t=14014
User avatar
Dr.Flay
Godlike
Posts: 3345
Joined: Thu Aug 04, 2011 9:26 pm
Personal rank: Chaos Evangelist
Location: Kernow, UK

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Dr.Flay »

Why reinvent the wheel ?
Dropper by MrLoathsome viewtopic.php?t=2885
Buggie
Godlike
Posts: 2148
Joined: Sat Mar 21, 2020 5:32 am

Re: Mutator "Gift From Decoration" for MonsterHunt

Post by Buggie »

First time hear about it. Also look like it not able do, what this mutator do.