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!
AndakRainor wrote:Hi! there is a missing object definition for your demon: charge_damage_hack
I looked at the code of this charge, what is the point of it? Did you have a problem with the normal MonsterChargeComponent behavior?
No that's just a remnant from when I haphazardly tried merging assets from my WIP dungeon with the asset pack.
It had a custom damage/death filter for the heroes, and I had to do some hacky stuff to get it to read damage from the charge component.
1 - when the game is saved, a message always appears
"warning! game object property not saved: scape_camera.camera.camera"
2 - monster Demon - when making a dash towards the group, the game always crashes with an error
3 - monster tentacles - always the game crashes with an error
[string "Animation.lua"]:0: File not found: assets/animations/monsters/drainage_tentacles/drainage_tentacles_attack_from_back.animation
stack traceback:
[C]: in function 'load'
[string "Animation.lua"]: in function 'loadProperties'
[string "GameObject.lua"]: in function 'initComponents'
[string "Arch.lua"]: in function 'spawn'
[string "DungeonEditor.lua"]: in function 'addObjectTool'
[string "DungeonEditor.lua"]: in function 'mapView'
[string "DungeonEditor.lua"]: in function 'update'
[string "Grimrock.lua"]: in main chunk
1 - when the game is saved, a message always appears
"warning! game object property not saved: scape_camera.camera.camera"
minmay wrote:That warning will always appear when you save the game while the current camera is not the default one. It's harmless and can be safely ignored.
2 - monster Demon - when making a dash towards the group, the game always crashes with an error
Until I release a fix, you can just remove this code snippet from demon.lua
3 - monster tentacles - always the game crashes with an error
1. The camera issue when saving the game is something that looks ugly and is annoying to see each time your saved mod loads, but I was told there's no workaround by Zimber and Minmay.
I feel there is one, but no one has come up with a viable solution.
2. I have the same issue with the Demon, too. I assume this is an asset or monster brain issue when using it in a custom mod, because it works on Zimber's test dungeon.
3. I haven't tried the tentacle monster, but I think it has something to do with adding the legend of Grimrock 1 assets and adding them to your dungeon in full.
Perhaps you should message ZImber to see if they can offer a solution to the above issues.
Good afternoon!
I want to make sure that my magicians can use spells only if they have a scroll of this spell.
I use this script:
defineObject{
name = "party",
baseObject = "party",
components = {
{
class = "Party",
onCastSpell =
function(party,champion,spellName)
local itemName = "scroll_"..spellName
for i = 1, 32, 1 do
if champion:getItem(i) ~= nil and champion:getItem(i).go.name == itemName then
return true
end
end
hudPrint(champion:getName().." needs to have the spell scroll on him to be able to cast it")
return false
end
}
}
}
I place it in the file objects.lua
Everything works as planned.
But as soon as I connect zim_assets v1.10-75-v1-10 the script stops working and the magicians begin to read spells without scrolls.
Tell me, what am I doing wrong?
Or, how can this situation be remedied?
If you've gotten as far as adding a hook to onCastSpell, no reason you shouldn't understand adding your snippet to the defined party in my scripts...
My definition is located a \mod_assets\zim_assets\zim_party.lua, find onCastSpell function in the definition, and add your code there.