Jump to content

How to copy a new installed spell


deratiseur

Recommended Posts

question: if I use ADD_SPELL to add a spell to the game with this instruction :

Quote

ADD_SPELL ~Derats_Magasin_2/Sorts/pxl2so2u.spl~ 2 8 WIZARD_PX_BREATH_OF_PORPHATYS    SPRINT current_spell_res "%DEST_RES%"    SAY NAME1 @6087    SAY UNIDENTIFIED_DESC @6088

How can I copy THIS installed spell for a variation? like :

Quote

COPY_EXISTING %DEST_RES% spell"    ~override/pxl2shi3.spl~     WRITE_BYTE 0x34 3

Edited by deratiseur
Link to comment

Something like this:

ADD_SPELL ~mymod/nuspl.spl~ 2 1 WIZARD_SPELL_NEW
    SAY NAME1 ~name~
    SAY UNIDENTIFIED_DESC ~desc~
LAF RES_NUM_OF_SPELL_NAME
    STR_VAR spell_name = ~WIZARD_SPELL_NEW~
    RET spell_res
END
COPY_EXISTING ~%spell_res%.spl~ ~override~
 …etc
Edited by subtledoctor
Link to comment

Thanks :) But that's don't work.

I've tried this :

ADD_SPELL ~Derats_Magasin_2/Objets/Coffre/Dilp/pxl2prag.spl~ 2 4 WIZARD_PX_DEADLY_RAGE SAY NAME1 @130911    SAY UNIDENTIFIED_DESC @130912
LAF RES_NUM_OF_SPELL_NAME
STR_VAR spell_name = ~WIZARD_SPELL_NEW~
RET spell_res
END
COPY_EXISTING ~%spell_res%.spl~ ~override/pxl2test.spl~    WRITE_BYTE 0x34 1

That don't work. The debug file say :

Copied [Derats_Magasin_2/Objets/Coffre/Dilp/pxl2prag.spl] to [override/spwi439.spl]
[*.IDS] forgotten
Appending to files ...
[./override/SPELL.IDS] loaded, 26871 bytes
override/spell.ids copied to Derats_Magasin_2/backup/0/override.spell.ids, 26871 bytes
Appended text to [spell.ids]
Copying and patching 1 file ...
[./override/add_spell.ids] loaded, 2981 bytes
Copied [add_spell.ids] to [override/add_spell.ids] (NO BACKUP MADE!)
Clearing the IDS map.
[*.IDS] forgotten
Added spell WIZARD_PX_DEADLY_RAGE
[./override/SPELL.IDS] loaded, 26899 bytes
FAILURE:
Invalid spell number: -1
Stopping installation because of error.
Stopping installation because of error.
Stopping installation because of error.
Stopping installation because of error.
Stopping installation because of error.
Stopping installation because of error.
Stopping installation because of error.

ERROR Installing [Patch de multiplication d'effets], rolling back to previous state
Unable to Unlink [Derats_Magasin_2/backup/0/OTHER.0]: Unix.Unix_error(1, "unlink", "Derats_Magasin_2/backup/0/OTHER.0")
[Derats_Magasin_2/backup/0/UNSETSTR.0] SET_STRING uninstall info not found
Will uninstall   3 files for [SETUP_PATCHING.TP2] component 0.

Edited by deratiseur
Link to comment

Ok, that's work, thanks a lot :)

I use this for non-simple spell installations such as :

	ADD_SPELL ~Override/pxl2achi.spl~ 2 7 WIZARD_PX_HACHITOZAS_TROOP_IMPROVEMENT    SPRINT current_spell_res "%DEST_RES%"    SAY NAME1 @60729    SAY UNIDENTIFIED_DESC @607309    WRITE_ASCIIE 0x34e   "%DEST_RES%" #8    WRITE_SHORT 0x98 ~%pxl2achi%~    SET ZF_inc_duree = 6    LPF MULTI_LEVELS END (custom macro) 

 

Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...