Multiple magic schools spells pack

Ask for help about creating mods and scripts for Grimrock 2 or share your tips, scripts, tools and assets with other modders here. Warning: forum contains spoilers!
Post Reply
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

New version available on the download page : http://ge.tt/9HPTdWE2

update notes:
- each willpower point of the caster now grants an additional 2% base damage / heal / duration instead of 1%.
- multiple elemental spells now gain +20% damage / heal / duration for each skill point of each elemental skill. So they are now the most powerful spells at high skill levels.
- rock spells now have an additional smoke visual effect similar to the main campaign elemental projectiles.
- the hit function in objects.lua now sets the world position of the tile damager or cloud spell of a projectile at the last world position of this projectile for a better visual.
- the conjure ice spell now deals cold damage over time on the tile of the ice block instead of physical damage. Also it checks the tile in front of the party before spawning the ice block as does any other melee spell. Its material is now double sided as the party can trap itself inside an ice block.
Azel
Posts: 808
Joined: Thu Nov 06, 2014 10:40 pm

Re: Multiple magic schools spells pack

Post by Azel »

Great! I look forward to implementing these in to my December update to Mystrock. Thanks!
Azel
Posts: 808
Joined: Thu Nov 06, 2014 10:40 pm

Re: Multiple magic schools spells pack

Post by Azel »

Hello!

So I am having some issues integrating the Spell Pack in to my Mod. I can use all your spells just fine with the Dungeon File you provided, but when I bring over all the scripts/assets in to my Grimrock Mod, I get errors. I will upload the exact error message later, but I recall it had something to do with an "xpcall."

Have you been able to successfully integrate only some of the spells in to another Mod? I do not want to install the entire spell pack since it changes how some of the vanilla spells work. I am hoping to integrate only a handful of the spells (which I listed in my Mystrock thread).
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

Hi! Send me your errors and I will help you, no problem!

To select a reduced set of spells for a mod (in mine I use all of them...) the best way to do it is to just remove the ones you don't want from the big table in spells_functions.lua where they are all listed. But I would advice to also consider using the redefined vanilla spells for consistency. You can change their spell gestures and put back the vanilla gestures if you want.

in init.lua I added this to the party definition;

Code: Select all

onCastSpell = function(party, champion, spellName) return spells_functions.script.onCastSpell(champion, spellName) end,
this function in spells_functions.lua is responsible for checking the spell cast and allow it to be learned if a scroll is present or not. It reads the spells definitions in this central table. So if you use this function and some definitions are missing in the table for some spells it could easily raise an error...
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

New version available on the download page : http://ge.tt/9HPTdWE2 (do not download the Spells pack for Azel file unless you are Azel yourself !)
You can now also find on this page a playable integration of the spells pack in the main campaign "Isle of Nex": the file is named "magic grimrock2.dat".

update notes:
- The aquatic trait is now added to items by the water enchantment spell as expected. In the previous version, the power of this effect was set to 0 for some reason and it prevented it from being applied.
- The missing definitions of enchanted item containers are added in mod_assets/scripts/items/containers.lua. So you can now use the enchantment spells on sacks and wooden boxes as originally expected.
- The poison clouds cleaner spells now do their job differently. They don't change the duration of clouds anymore but fade out their effects and set their damage to 0 instead. (It improves the stability of the game engine.)
- The files in mod_assets/scripts were reorganized with an easier structure to handle them and integrate them in a mod. mod_assets/scripts/init.lua is now a minimal script with comments to help to get what you need; all the initialization details are handled in mod_assets/scripts/spells/init_spells.lua. The mod_assets/scripts/items directory contains items definitions needed for the enchantment spells only, and mod_assets/scripts/spells contains all the scripts needed for spells. The files directly in mod_assets/scripts are only useful for the basic dungeon example, not the spell pack itself. The files in mod_assets/sounds, mod_assets/textures, mod_assets/sx_winter_tileset (3 textures only) are still needed for the spells.

Adding the spells to a mod requires these steps:
- copy the files from those directories to your mod:
  • mod_assets/scripts/spells
    mod_assets/scripts/items
    mod_assets/sounds
    mod_assets/sx_winter_tileset
    mod_assets/textures
- add these lines to your init.lua file:

Code: Select all

import "mod_assets/scripts/items/containers.lua"     -- used in the spells pack for enchantment spells
import "mod_assets/scripts/items/swords.lua"         -- used in the spells pack for enchantment spells
import "mod_assets/scripts/spells/init_spells.lua"   -- the spells pack
- create a script entity on the first map of your dungeon, give it the object id "spells_functions", and link its source to the file mod_assets/scripts/spells/spells_functions.lua
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

update to "magic grimrock2.dat" (v1.1)

Changed the gesture of the arcane nova spell to allow the hidden balance spell to be cast to access the shrine of balance.

If you use the 1.0 version of the mod, activate the console command when you are on the balance symbol in front of the castle and enter this command:

party:setPosition(party.x, party.y, party.facing, party.elevation, party.level+1)

To activate the console command:
- go to Documents\Almost Human\Legend of Grimrock 2
- open grimrock.cfg (with notepad)
change lines for:
console = true
consoleKey = 192

Start game
press ~
console will appear
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

update to "magic grimrock2.dat" and "Spell_pack_dungeon_for_2.2.4.zip" (v1.2)

Correction of a bug crashing the game when saving while those 3 spells were active:
- Wind Blow
- Fierce Storm
- All Shall Fall

New feature: the Fire Enchantment spell can make a torch last forever.
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

Version 2.0 of the pack is uploaded!

It comes with its basic dungeon example, the integration to Isle of Nex will come soon after (never trust this word!).

http://www.nexusmods.com/legendofgrimrock2/mods/60?
User avatar
AndakRainor
Posts: 674
Joined: Thu Nov 20, 2014 5:18 pm

Re: Multiple magic schools spells pack

Post by AndakRainor »

It has many many new features, so I will not list every detail, but here are the big changes:

- Delayed effects are now managed with a timer every frame, with a maximum effects per frame that can be modified. No more delayedCall functions used, to improve performance.

- A torch and spells light system with one light component attached to the party only, also for better performance. As opposed to the current version of orrr3, no disabled light component is used to store the active lights.

- Many new spells with new icons, particle effects and animations. Among others: Time Bolt, Alter Time, Drain Life Bolt, Detect Life, Copycat, Vengeance, Misdirection, Immortal (also known as life 3 in other universes!).

- A spell book to easily access this awfully high number of spells :)

- A readme with details about improved installation options in a dungeon project. A path variable to put the pack in any directory you want, a flag to get compatible hooks with the Hook Framework...
User avatar
akroma222
Posts: 1029
Joined: Thu Oct 04, 2012 10:08 am

Re: Multiple magic schools spells pack

Post by akroma222 »

Most excellent!! Been looking forward to the new update :D
Post Reply