ToME: the Tales of Maj'Eyal

Everything about ToME
It is currently Mon May 20, 2019 3:14 am

All times are UTC




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Sun Feb 03, 2019 2:38 am 
Offline
Sher'Tul Godslayer

Joined: Tue Jun 18, 2013 10:46 pm
Posts: 2384
Location: Ambush!
Code:
   class:bindHook("Combat:getDammod:subs",
        function(self, combat, dammod, subs)
                       .....
        end
   )


In the above hook, dammod used to be populated, and modifications to dammod were honored (so I could do stuff with weapon stat mods in my addon).

Now I'm getting nil for dammod and subs, and modifications to dammod aren't being honored by the engine.

What changed?

Is there a replacement callback or hook? I don't see anything near getDammod in Combat.lua

_________________
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.


Top
 Profile  
 
PostPosted: Tue Feb 05, 2019 8:55 am 
Offline
Master of Eyal

Joined: Wed Jul 24, 2002 9:26 pm
Posts: 10241
Location: Angolwen
?? bindHook function always have the same parameters list: (self, data) tah'ts all and that never has changed :)
What you want is data.dammod, data.subs and so on

_________________
[tome] joylove: You can't just release an expansion like one would release a Kraken XD
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning ;)


Top
 Profile  
 
PostPosted: Tue Feb 05, 2019 5:16 pm 
Offline
Sher'Tul Godslayer

Joined: Tue Jun 18, 2013 10:46 pm
Posts: 2384
Location: Ambush!
darkgod wrote:
?? bindHook function always have the same parameters list: (self, data) tah'ts all and that never has changed :)
What you want is data.dammod, data.subs and so on

Thanks, I'll do that instead!

I wonder why the code appeared to work in previous versions.

_________________
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.


Top
 Profile  
 
PostPosted: Tue Feb 05, 2019 10:40 pm 
Offline
Perspiring Physicist

Joined: Sun Sep 09, 2012 7:43 am
Posts: 5875
Variable still had values assigned to it outside the scope of its definition maybe?

_________________
My feedback meter decays into coding. Give me feedback and I make mods.


Top
 Profile  
 
PostPosted: Thu Feb 07, 2019 4:53 pm 
Offline
Sher'Tul Godslayer

Joined: Tue Jun 18, 2013 10:46 pm
Posts: 2384
Location: Ambush!
HousePet wrote:
Variable still had values assigned to it outside the scope of its definition maybe?


Ah, something that used to be global turned into better code between then and 1.5.10? Possible, I guess.

_________________
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group