Jump to content

Recommended Posts

Hello, i am trying to port the DST mod Shields to DS for my own personal use and while i have been able to get all items, animations, custom action and inventory slot all working within DS, for some reason the shields do not actually stop damage, furthermore the game doesnt seem to fire my print() within the action, have i missed something when porting the action?
Line 681 and onwards
 

modmain.lua

Line 686 looks strange to me...

    local shield = act.invobjectlocal shield = act.doer.components.inventory:GetEquippedItem(GLOBAL.EQUIPSLOTS.SHIELD)

not sure what this line is trying to accomplish, but usually you are not setting local shield equal to one variable which is equal to another?  the way this looks now its like writing local shield = A = B or something...

And then on line 690 you set local invobj = act.invobject, which makes me think you wanted to use either

1) local shield = act.invobject

-OR-

2) local shield = act.doer.components.inventory:GetEquippedItem(GLOBAL.EQUIPSLOTS.SHIELD)

 

Oh yes, i am switching to the first one, the original mod only let you use shields from the shield slot, i am going to let you use them from the inventory in general(to be able to disable the shield slot for when using RPG Hud)
But my issue is the invobj.components.shield.armor:SetAbsorption(TUNING.FULL_ABSORPTION), as it doesnt seem to trigger any absorption at all

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...