petri wrote:Are you sure the function gets triggered?
I've figured it out ~somewhat. The function I made had the Alcove trigger a script that spawned the dagger in the Alcove.
This caused a 'Stack Overflow'. It all works fine if I use a pressure plate instead of the alcove to call the script.
Edit: Or maybe not quite. I'll look at this some more; something is odd or being missed. I tried spawning a dagger [on a new map, in an alcove] via a script called by the alcove, and it worked; but this same code snippet causes a stack overflow in the other map.
Is there any way to make a looping/really long sound like torch_burning stop on command? There only seems to be a thing for playing sounds and not stopping them.
Is there a way to find out if the Light spell has been cast and is active?
And does the darkness spell negate the light spell? Or just overwrite it so that the light spell stays active on the background?
As in Grimrock when you obtain the Weapon of Power, you need to have all lights out to get it. I figured how to check for torches in hands, but how to check for the light spell?
Whalefish wrote:Is there a way to find out if the Light spell has been cast and is active?
As in Grimrock when you obtain the Weapon of Power, you need to have all lights out to get it. I figured how to check for torches in hands, but how to check for the light spell?
That's a good question, I'd like to be able to recreate that effect as well!
damageTile(level, x, y, direction, flags, damageType, power)
Damages all creatures including the party in a given tile. direction specifies the direction of the attack for projectiles or melee attacks (0=north, 1=east, 2=south, 3=west). damageType must be one of the following: “physical”, “fire”, “poison”, “cold”, “poison”. Damage is rolled individually for all creatures using the power as base value. flags is a numeric bit field:
bit 0: monsters recoil from the impact
bit 1: ongoing damage such as poison cloud
bit 2: damage originated from champion with ordinal index 1
bit 3: damage originated from champion with ordinal index 2
bit 4: damage originated from champion with ordinal index 3
bit 5: damage originated from champion with ordinal index 4
bit 6: ignore immunities
bit 7: halve damage of back row party members
Bits 2-5 are used when dealing experience point awards. See also Champion:getOrdinal().
I'm not really sure how what I'm supposed to put for flags for any given situation.
for i in entitiesAt(level, x, y) do
dummy(i)
end
function dummy (i)
if i.setAIState then -- monster
-- do something
return
end
if i.setScrollText then -- scroll
-- do something
return
end
end
This is my first post and i hope i am in the right place ...
I'm a total script newbie and my whole script-part of my own Dungeon is just copy+pasted - so I would like to know if anybody could help me with a script for a leverpuzzle ... The player/party has to pull the levers in the right order. Please, help! For once a already made script would help me a lot, but if anyone has the patience to explain it ... would be great.
And I'm very sorry if i have missed the post/article in which it is explained. :-/
Where and what do you use to edit the scripts? Do you go to the games files, under the lets say *textures* and open the file using Notepad or something? Or is there more to it then that, the explanations here seem fairly simple, but how do you open up the script itself to be modified. Sorry I am very new to scripting, I took maybe a week of schooling for it one time years ago, but I couldn't tell you how I went about it at the time.
I'm here to kick goblins and chew herbs, and I'm all out of herbs.