[1.1.5] Technique Talents Bug Fix

A place to post your add ons and ideas for them

Moderator: Moderator

Post Reply
Message
Author
Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

[1.1.5] Technique Talents Bug Fix

#1 Post by Marson »

Hand armor can slow down unarmed attack speed, but it is also having an impact on talents in the "Technique" category as well, slowing them by about 20%. This addon will use shield speed for shield skills, main weapon speed for all others, and if unarmed, it will use the default single-turn energy expenditure of other talents not already in the Spell, Mind, or Summon categories.

Talents not in the Technique category, but also modified:
• Block: Use shield speed.
• Dirty Fighting: Energy refunded after a failed stun matches energy spent.
• Gesture of Pain: Uses energy cost of one turn.

This will also affect the speeds of NPCs who use the above talents.

+ Fixed an error introduced when moving a couple functions from overload to superload.

http://te4.org/games/addons/tome/marson-speedfix
Last edited by Marson on Fri Feb 28, 2014 5:02 am, edited 2 times in total.

Noel
Thalore
Posts: 121
Joined: Fri Dec 15, 2006 1:49 am

Re: [1.1.5] Gauntlet Speed Fix

#2 Post by Noel »

I just started a new dwarf berserker using this addon, in addition to Zomnibus, and Zizzo's item notes.

It got into an endless loop while generating Norgos' Lair (I had successfully finished Reknor and visited Last Hope and Derth).

Found this lua error in the log -- not sure if it's this addon or Zomnibus:

Code: Select all

Added unique	mod.class.NPC/Velulrarin the white worm mass	::	1
stack traceback:
	/mod/class/interface/Combat.lua: in function 'getObjectCombat'
	/mod/class/Actor.lua:4144: in function 'postUseTalent'
	/engine/interface/ActorTalents.lua:194: in function </engine/interface/ActorTalents.lua:180>
Lua Error: /engine/interface/ActorTalents.lua:232: /mod/class/interface/Combat.lua:238: attempt to index local 'o' (a nil value)
	At [C]:-1 
	At [C]:-1 error
	At /engine/interface/ActorTalents.lua:232 useTalent
	At /mod/resolvers.lua:513 check
	At /engine/Zone.lua:630 addEntity
	At /mod/class/generator/actor/Random.lua:53 generateOne
	At /engine/generator/actor/Random.lua:118 regenFrom
	At /engine/generator/actor/Random.lua:47 generate
	At /engine/Zone.lua:889 newLevel
	At /engine/Zone.lua:801 getLevel
	At /mod/class/Game.lua:822 changeLevelReal
	At /mod/class/Game.lua:702 base_changeLevel
	At /mod/addons/zomnibus/superload/mod/class/Game.lua:45 changeLevel
	At /mod/class/Game.lua:1662 
	At /engine/KeyBind.lua:241 

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Gauntlet Speed Fix

#3 Post by Marson »

Looks like it's probably mine. I forgot to put in a couple sanity checks. Thanks for posting it. I'll do an update.

--

All set. This one should be more robust.

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Gauntlet Speed Fix

#4 Post by Marson »

Shuffling lines around, I removed the speed adjustment for Brawlers (both their inherent boost and the gauntlet degrade) from talent activation . That should be restored now.

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Gauntlet Speed Fix

#5 Post by Marson »

I improved the logic for when to use the default 1-turn energy cost, now check for an offhand weapon with no mainhand, and updated the character sheet to show a more proper speed. I've also added in log output so you can monitor the speed being used for each talent activation. You can pull out a few comment bars if you want to see them in-game as well.

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: [1.1.5] Technique Talents Bug Fix

#6 Post by jenx »

should this addon be used if running a regular berserker?
MADNESS rocks

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Technique Talents Bug Fix

#7 Post by Marson »

Every talent tree they have except Dirty Fighting and Survival is a Technique tree, so definitely.

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: [1.1.5] Technique Talents Bug Fix

#8 Post by jenx »

Code: Select all

error = "Lua Error: /engine/interface/ActorTalents.lua:174: /mod/addons/marson-speedfix/superload/mod/class/Actor.lua:117: attempt to index global 'Map' (a nil value)\
  At [C]:-1 \
  At [C]:-1 error\
  At /engine/interface/ActorTalents.lua:174 useTalent\
  At /mod/ai//tactical.lua:382 runAI\
  At /mod/ai//tactical.lua:408 doAI\
  At /mod/class/NPC.lua:61 act\
  At /engine/GameEnergyBased.lua:126 tickLevel\
  At /engine/GameEnergyBased.lua:62 tick\
  At /engine/GameTurnBased.lua:46 tick\
  At /mod/class/Game.lua:1141 "
seen = true
reported = true
yeek brawler encountering rare, rare casting Drain
MADNESS rocks

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Technique Talents Bug Fix

#9 Post by Marson »

Thanks for the bug report. I forgot to transfer a line of code when making it compatible with my other addons.

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: [1.1.5] Technique Talents Bug Fix

#10 Post by Doctornull »

1.2 beta interaction bug while firing an arrow from a bow:

Adding entity 13706 after 2199
stack traceback:
/mod/addons/marson-speedfix/superload/mod/class/Actor.lua: in function 'postUseTalent'
/engine/interface/ActorTalents.lua:155: in function </engine/interface/ActorTalents.lua:135>
Lua Error: /engine/interface/GameTargeting.lua:118: /mod/addons/marson-speedfix/superload/mod/class/Actor.lua:224: attempt to perform arithmetic on a nil value
At [C]:-1
At [C]:-1 error
At /engine/interface/GameTargeting.lua:118 fct
At /engine/interface/GameTargeting.lua:124 targetMode
At /engine/interface/GameTargeting.lua:185
At /engine/KeyBind.lua:229
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: [1.1.5] Technique Talents Bug Fix

#11 Post by Doctornull »

Another 1.2 issue:

[LOG] Adera the cold drake hatchling shoots!
[ARCHERY ACQUIRE TARGETS WITH] rough leather sling of power deadly pouch of iron shots
[PROJECTILE SPEED] :: 10
[SHOOT] speed 0.8 => 800
[SHOOT WITH] rough leather sling of power deadly pouch of iron shots
Adding entity 43137 after 41163
stack traceback:
/mod/addons/marson-speedfix/superload/mod/class/Actor.lua: in function 'postUseTalent'
/engine/interface/ActorTalents.lua:155: in function </engine/interface/ActorTalents.lua:135>
Lua Error: /engine/interface/ActorTalents.lua:175: /mod/addons/marson-speedfix/superload/mod/class/Actor.lua:224: attempt to perform arithmetic on a nil value
At [C]:-1
At [C]:-1 error
At /engine/interface/ActorTalents.lua:175 useTalent
At /mod/ai//tactical.lua:382 runAI
At /mod/ai//tactical.lua:408 doAI
At /mod/class/NPC.lua:61 act
At /engine/GameEnergyBased.lua:126 tickLevel
At /engine/GameEnergyBased.lua:62 tick
At /engine/GameTurnBased.lua:46 tick
At /mod/class/Game.lua:1141
---------------- Stack Dump ----------------
--------------- Stack Dump Finished ---------------
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

Marson
Uruivellas
Posts: 645
Joined: Thu Jan 16, 2014 4:56 am

Re: [1.1.5] Technique Talents Bug Fix

#12 Post by Marson »

I believe the fix has been integrated into 1.2 already, though a little different than the way I did it. I'll double-check in a bit.

Post Reply