Ask a simple question, get a simple answer

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!
Pompidom
Posts: 497
Joined: Sun May 06, 2018 9:42 pm

Re: Ask a simple question, get a simple answer

Post by Pompidom »

And I can see everyone's pictures just fine by default without doing anything on Firefox 65.0.2, IE and chrome.
So it's not the link.
NolanDaneworth
Posts: 21
Joined: Thu Feb 28, 2019 5:55 pm

Re: Ask a simple question, get a simple answer

Post by NolanDaneworth »

Anyway, thx everyone for involvement. Another mystery of editor solved. Tho kinda suprised it wasn't discovered earlier, could've saved some nerves.
Killcannon
Posts: 73
Joined: Sun Apr 12, 2015 2:57 pm

Re: Ask a simple question, get a simple answer

Post by Killcannon »

Back on topic... I need another smart answer for one of my stupid questions.

How would you have a monster die by having an object be in the square/space that they are occupying? I want to have the players push a movable block onto a boss in order to kill the boss. (I'll worry about figuring out how to get the boss in the needed square later) I was thinking a floor trigger to activate when both the boss and the block were in the same spot, but I'm unsure of the interaction of a movable block and NPC.

So my initial testing has shown this will be harder than I initially thought. The bloody thing floats!

Image

So I think the first order of business is figuring out how to have gravity apply so it falls. Currently the only thing under it is the pushable_block_floor set at height 0. I tried deactivating that and it doesn't fall. Is it even possible to have objects fall?
User avatar
Isaac
Posts: 3185
Joined: Fri Mar 02, 2012 10:02 pm

Re: Ask a simple question, get a simple answer

Post by Isaac »

Using the tiledamager function is one way to kill a monster on a certain square. But if you know exactly when the monster is on the correct tile, then you can just call its die() method. Also: die(true) awards XP to the party.

*It is technically possible to make it fall by adding a gravity component, but the delay ruins the illusion. You might have better results with a custom animation, made using Blender.
Pompidom
Posts: 497
Joined: Sun May 06, 2018 9:42 pm

Re: Ask a simple question, get a simple answer

Post by Pompidom »

Experimenting with these blocks in my mod made me come up with some interesting concepts.

The first thing to bear in mind if you're gonna build a puzzle like that is to come up with a way to prevent people from jumping with the party on the boss monster making this entire endeavour futile. So it's gonna be harder to pull it off creating something like this.
And you will probably have to rebuild your arena.

Now the pushable blue block floors can be placed anywhere under the blocks. You can place them at -7 height and the pushable blocks will still work at height 0 or 1 This way you can push the block everywhere in activated form without having to deal/look at blue floor lights.

Same for the orange trigger spots.

The orange trigger spots have a floortrigger component "TriggeredByMonster"
So basically you push the activated hovering block where you pushed it now hovering still in activated form on height 1

As soon the monster walks under it, the monster itself will trigger the orange floortrigger and the block will deactivate.

Now there is 2 ways to proceed. If anyone can make a custom block with an additional gravity component that's disabled by default.
You call a delayed call that the monster dies at the same time the gravity component of the block is activated. This way the ruined illusion like Isaac mentioned can be mitigated. They're magic blocks anyways :) The block deactivates, the lights go out, the block loses its "magic" and then it falls.
Pushing a deactivated block that probably weighs a few ton isn't realistic at all :)

Or at the moment the downward momentum of the block deactivating animation, just call in monster.die
and then spawn a block on height 0 while making the block on height 1 invisible/destroy

Another alternative is to simply build an arena where you move the blocks around on height 0 trapping the boss while it's standing on some furnace floor grating that occassionally spawns fire or spawns fire with the press of a button when all blocks are at the designated tile. This will make the boss fight slightly more interesting as you have to dance around the arena getting the blocks in the right position and then lure it in before moving the last blocks in place.
NolanDaneworth
Posts: 21
Joined: Thu Feb 28, 2019 5:55 pm

Re: Ask a simple question, get a simple answer

Post by NolanDaneworth »

And i have my own question again.
Is there a way to script floor, that whenever party stays on it - no magic can be used ?
It really hurts to not know lua, because so many ideas, so little capabilities.

As in references, i only see .onCastSpell, but how to write the "fizzle" part ?
User avatar
Zo Kath Ra
Posts: 937
Joined: Sat Apr 21, 2012 9:57 am
Location: Germany

Re: Ask a simple question, get a simple answer

Post by Zo Kath Ra »

NolanDaneworth wrote: Mon Mar 04, 2019 5:07 pm As in references, i only see .onCastSpell, but how to write the "fizzle" part ?
viewtopic.php?p=119265#p119265
NolanDaneworth
Posts: 21
Joined: Thu Feb 28, 2019 5:55 pm

Re: Ask a simple question, get a simple answer

Post by NolanDaneworth »

Zo Kath Ra wrote: Mon Mar 04, 2019 5:55 pm
NolanDaneworth wrote: Mon Mar 04, 2019 5:07 pm As in references, i only see .onCastSpell, but how to write the "fizzle" part ?
viewtopic.php?p=119265#p119265
thank you, gotta experiment now
User avatar
Zo Kath Ra
Posts: 937
Joined: Sat Apr 21, 2012 9:57 am
Location: Germany

Re: Ask a simple question, get a simple answer

Post by Zo Kath Ra »

NolanDaneworth wrote: Mon Mar 04, 2019 5:57 pm thank you, gotta experiment now
Now I wish i'd provided a bad solution, because then Isaac would've posted a perfect one :D
NolanDaneworth
Posts: 21
Joined: Thu Feb 28, 2019 5:55 pm

Re: Ask a simple question, get a simple answer

Post by NolanDaneworth »

Zo Kath Ra wrote: Mon Mar 04, 2019 6:11 pm
NolanDaneworth wrote: Mon Mar 04, 2019 5:57 pm thank you, gotta experiment now
Now I wish i'd provided a bad solution, because then Isaac would've posted a perfect one :D
i wish i knew what im doing wrong, cuz i already managed to crash editor 4 times
Last edited by NolanDaneworth on Tue Mar 05, 2019 12:39 am, edited 1 time in total.
Post Reply