(fixed) Trigger glitch with monster projectiles

This forum is for the Lua scriptable clone of DM/CSB called Dungeon Strikes Back by Sophia. Use DSB to build your own highly customised games.

Moderator: Sophia

Forum rules
Please read the Forum rules and policies before posting.
Post Reply
kaypy
Artisan
Posts: 171
Joined: Sun Jan 19, 2014 7:11 am

(fixed) Trigger glitch with monster projectiles

Post by kaypy »

When a monster launches a projectile, the game triggers mechanisms as if it is an object on the ground at that tile.

The door here is set to opby thing-on-the-ground, but it will toggle when the dragon breathes:

Code: Select all

dsb_text2map(0, 8, 3, 100, 1, {
"11111111",
"00100001",
"00100000"} )
dsb_level_wallset(0, wallset.default)
dsb_text2map(1, 8, 3, 0, 1, {
"00000000",
"00100001",
"00111111"} )
dsb_level_wallset(1, wallset.default)
dsb_add_champion(1, "test", "port_mophus", "TEST", "", 9000, 9000, 1000, 800, 800, 400, 400, 400, 400, 400, {0,0,0,0,0}, {0,0,0,15,0}, {0,0,0,0,0}, {0,0,0,0,0})
ch_exvar = {
}
dsb_spawnburst_begin(21)
dsb_spawn(3, "doorframe", 0, 3, 0, 4)
dsb_spawn(20, "door_metal", 0, 3, 0, 4)
dsb_spawn(2, "pit", 0, 2, 1, 4)
dsb_spawn(1, "stairsdown", 0, 7, 1, 4)
dsb_spawn(4, "pad", 0, 2, 2, 4)
dsb_spawn(21, "dragon", 0, 2, 2, 4)
exvar = {
[4] = { target = 20,
msg = 100002,
opby_thing = true },
}
dsb_spawnburst_end()
EDITOR_FLAGS = 255
dsb_champion_toparty(0, 1)
dsb_party_place(0, 0, 0, 2)
Friends don't let friends eat worm round
User avatar
Sophia
Concise and Honest
Posts: 4239
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Re: (fixed) Trigger glitch with monster projectiles

Post by Sophia »

The problem is that the engine is actually behaving correctly, according to the way the monster attack is coded. :shock:

The fireball is spawned "sitting on the ground" and is then launched, but the trigger gets set off as soon as the fireball is spawned. I'll fix this.
kaypy
Artisan
Posts: 171
Joined: Sun Jan 19, 2014 7:11 am

Re: (fixed) Trigger glitch with monster projectiles

Post by kaypy »

Thanks

I have this mental image of a dragon spitting a fireball onto the ground, picking it up, maybe rubbing some dust off, and then throwing it at the party 8-)
Friends don't let friends eat worm round
Post Reply