TeamREPENTOGON / REPENTOGON

Script extender for The Binding of Isaac: Repentance
https://repentogon.com/
GNU General Public License v2.0
140 stars 16 forks source link

EntityPlayer:CollectPickup(player, pickup) #75

Open guwahavel opened 1 year ago

guwahavel commented 1 year ago

Ability for player to attempt to collect any pickup at range like how Forgotten Bone Club/Spirit Sword can

If the Collision callback is not used, should have its own callback so modded pickups can be hooked into it

namishere commented 1 year ago

I believe this is solved by Entity:ForceCollide, but let's get some feedback first

BrakeDude commented 2 weeks ago

I think it should have own callback/function because Entity:ForceCollide triggers collision callbacks. EntityPlayer::CollectPickup(player, pickup) should force collect by playing apropriate animation depending if it pickup is shop item or not and maybe even ignore collision callbacks all together. That also by idea should eliminate problem with restock since there's no function i know that restocks pickups with apropriate cost. Although CustomHealthAPI's TriggerRestock exists it's still a hacky workaround. And also EntityPlayer::CollectPickup(player, pickup) should return boolean value as a check if collecting was succesfull. But then again there are things like if it was collected by player or bag of crafting. Small things like that but i hope there a few of them