nosoop / SM-TFCustomWeaponsX

SourceMod plugin that allows players to use custom TF2 items.
GNU General Public License v3.0
22 stars 11 forks source link

Attributes on non-native wearables stack #30

Closed nosoop closed 3 years ago

nosoop commented 3 years ago

Separated out individual issue from #28, CC @SnowySnowtime

I'm almost certain this stems from wearables still being on the player. cwx/item_entity.sp::TF2_RemoveItemByLoadoutSlot() only checks against the loadout entity, which means off-class loadouts aren't recognized or unequiped.

I thought I had an issue tracking this quirk somewhere in tf2utils. There's a change there I've been meaning to push, so I'll test / deploy it if it works out.

nosoop commented 3 years ago

Ended up deciding not to do any changes to tf2utils for the time being.

SnowySnowtime commented 3 years ago

tf_speakeasyinspired_weapons.txt

Example Config, for the issue mentioned above. It makes use of a tf_wearable, which I wanted to have as a stand-in to the Mantreads for visibility sake.

nosoop commented 3 years ago

Ah, that's an invalid combination — the item it's inheriting is strictly a wearable and not a wearable weapon like the Gunboats / Mantreads are (see the item slot column).

That's something I'll have to error out on, and to figure out in what way to do that.

There might be a way to implement that correctly in the future, though I can't really guarantee it.

nosoop commented 3 years ago

Thanks for the config though; it provides an insight into the sort of creative ways that can break the plugin.

nosoop commented 2 years ago

Persistence improvements were made for off-class items, and a side effect of that appears to allow for wearables in non-native slots. I tested your config again and it appears to work.

If you're still using the plugin, do try it and let me know!

SnowySnowtime commented 2 years ago

I'll try it out!

SnowySnowtime commented 2 years ago

It works, thank you!