Skip to content

[(BGEE, BG2) bug] Invis 10' duration

CamDawgCamDawg Member, Developer Posts: 3,438
edited September 2012 in Fixed
Per its description, Invisibility 10' Radius is supposed to last for 24 hours (unless broken earlier) but was only lasting for one hour. This also fixes a small bug where the sound effects were only playing on the caster instead of all the creatures affected.
// incorrect duration, targeting for invis 10'
COPY_EXISTING ~spwi307.spl~ ~override~
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
READ_LONG 0x6a "fx_off"
FOR (index = 0 ; index < abil_num ; index = index + 1 ) BEGIN // cycle thru abilities
READ_SHORT ("%abil_off%" + 0x1e + (0x28 * "%index%")) "abil_fx_num"
READ_SHORT ("%abil_off%" + 0x20 + (0x28 * "%index%")) "abil_fx_idx"
FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN
READ_SHORT ("%fx_off%" + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "opcode"
READ_LONG ("%fx_off%" + 0x0e + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "duration"
PATCH_IF ("%duration%" = 300) BEGIN
WRITE_LONG ("%fx_off%" + 0x0e + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 7200
END
PATCH_IF ("%opcode%" = 174) BEGIN
WRITE_BYTE ("%fx_off%" + 0x02 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 2 // target: preset target
END
END
END
BUT_ONLY_IF_IT_CHANGES
Post edited by Bhryaen on

Comments

  • Avenger_teambgAvenger_teambg Member, Developer Posts: 5,862
    Confirmed fixed.
  • BhryaenBhryaen Member Posts: 2,874
    Confirmed fixed... ?

    Duration of the Invisibility and related Play sound effects (Effects #2, #4) now set to 7200... which is 2hrs? Perhaps 2hrs real time = 24hrs game time? Or does this use the duration as rounds- i.e., 6sec/rnd X 7200 rnds = 12 hrs.

    The old duration was 300, so at least 7200 is 24 X an hour-long duration.

    The Target for Effect #4 also now set to target "Preset target" rather than "Self."

    I'm also presuming that Effect #4's Timing mode being set (as in vBG2) to Delay/Permanent - 4 is correct, though it looks wrong...
  • Avenger_teambgAvenger_teambg Member, Developer Posts: 5,862
    7200 is supposed to be one in-game day, see GTIMES.IDS
    1 in-game hour is 300 (see the armor spell with 9 hours)
    1 turn is 60 (10 rounds)
    1 round is 6 (see spook with 3 rounds)

    This may be appropriate: http://answers.yahoo.com/question/index?qid=20100722105309AAjuCPL
  • solar_onesolar_one Member Posts: 12
    One more thing with this spell I noticed is that its 'Secondary Type' should be labeled as Illusionary Protections and not Non-Combat as it is now. All the other similar types of spells are such.
Sign In or Register to comment.