Skip to content

[(BG2, BGEE) Bug] Spell casting speed

CamDawgCamDawg Member, Developer Posts: 3,438
edited August 2012 in Fixed
Various spells have casting speeds different than the speed listed in their descriptions. To fix them:
// casting speed fixes
COPY_EXISTING ~sppr310.spl~ ~override~ // miscast magic
~sppr311.spl~ ~override~ // rigid thinking
~sppr403.spl~ ~override~ // free action
~sppr717.spl~ ~override~ // creeping doom
~spwi504.spl~ ~override~ // mon summoning iii
~spwi522.spl~ ~override~ // minor spell turning
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
FOR (index = 0 ; index < abil_num ; index = index + 1) BEGIN
WRITE_SHORT ("%abil_off%" + 0x12 + (0x28 * "%index%")) 5
END
BUT_ONLY_IF_IT_CHANGES

// casting speed fixes
COPY_EXISTING ~sppr104.spl~ ~override~ // detect evil
~sppr214.spl~ ~override~ // duhm divine
~spwi211.spl~ ~override~ // melf's acid arrow
~spwi505.spl~ ~override~ // shadow door
~spwi511.spl~ ~override~ // protection from normal weapons
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
FOR (index = 0 ; index < abil_num ; index = index + 1) BEGIN
WRITE_SHORT ("%abil_off%" + 0x12 + (0x28 * "%index%")) 2
END
BUT_ONLY_IF_IT_CHANGES

// casting speed fixes
COPY_EXISTING ~spin104.spl~ ~override~ // innate lmd
~spwi402.spl~ ~override~ // dimension door
~spwi408.spl~ ~override~ // stoneskin
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
FOR (index = 0 ; index < abil_num ; index = index + 1) BEGIN
WRITE_SHORT ("%abil_off%" + 0x12 + (0x28 * "%index%")) 1
END
BUT_ONLY_IF_IT_CHANGES

// casting speed fixes
COPY_EXISTING ~spwi214.spl~ ~override~ // strength
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
FOR (index = 0 ; index < abil_num ; index = index + 1) BEGIN
WRITE_SHORT ("%abil_off%" + 0x12 + (0x28 * "%index%")) 9
END
BUT_ONLY_IF_IT_CHANGES
Post edited by Bhryaen on

Comments

  • CorianderCoriander Member Posts: 1,667
    K, I'll drop this in.
  • NathanNathan Member Posts: 1,007
    Verified, this is in and should be present in the next build.
  • Avenger_teambgAvenger_teambg Member, Developer Posts: 5,862
    confirmed fixed
    Casting times checked in editor - 1 round for casting time is weird, though
  • BhryaenBhryaen Member Posts: 2,874
    Confirmed Fixed:

    Confirmed from desc & set to spell casting speed 5:
    SPPR311
    SPPR403 (set for all Spell Abilities)
    SPPR717
    SPWI504 (set for all Spell abilities)
    SPWI522 (set for all Spell abilities)

    Confirmed from desc & set to spell casting speed 2:
    SPPR214 (set for all Spell abilities)
    SPWI211 (set for all Spell abilities)
    SPWI505 (set for all Spell abilities)
    SPWI511 (set for all Spell abilities)

    Confirmed from desc & set to spell casting speed 1:
    SPIN104
    SPWI402
    SPWI408 (set for all Spell abilities)

    Confirmed from desc & set to spell casting speed 9:*
    SPWI214 (set for all Spell abilities)

    * (Desc states "Casting Time: 1 round." 1 round = Casting Time 9?)
  • Avenger_teambgAvenger_teambg Member, Developer Posts: 5,862
    edited August 2012
    It feels like a typo, that's not a demon summoning spell to take so long.
    On the other hand, in HoW/iwd2, (bull's) strength casting time: 10 (that is 1 round)
    and cat's grace: 2.
  • CamDawgCamDawg Member, Developer Posts: 3,438
    As I recall, we had the occasional AI script wonk with actual casting times of 10 so we went with 9 for full round times.
  • BhryaenBhryaen Member Posts: 2,874
    Well, I can't see most players being upset about a casting time 1 notch faster... Confirmed Fixed. :-)
  • AlonsoAlonso Member Posts: 806
    CamDawg wrote: »
    As I recall, we had the occasional AI script wonk with actual casting times of 10 so we went with 9 for full round times.
    Sorry for the necromancy, but this is a short question that probably doesn't deserve a full new thread: What's the meaning of this? Do spells with casting time 9 last a full round or do they actually last 9 tenths of a round?
  • kjeronkjeron Member Posts: 2,367
    Alonso wrote: »
    What's the meaning of this? Do spells with casting time 9 last a full round or do they actually last 9 tenths of a round?
    Probably depends on your perception of a round. For internal mechanics it's 100 ticks, but timers that run on seconds use 90 ticks (6 seconds), which includes most spell durations and script timers.
  • AlonsoAlonso Member Posts: 806
    Sorry, I can't understand. Can you ellaborate?
  • CamDawgCamDawg Member, Developer Posts: 3,438
    Creatures scripted to cast a spell with a full casting time of 10 would sometimes interrupt their own casting at the last moment to perform the next round's action, wasting the round and the spell.
Sign In or Register to comment.