counter anomoly?
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
counter anomoly?
I am spawning 4 monsters with an onDie function to decrement a counter an open the door when the counter hits 0 (ie all monsters dead).
What I find is if I use K to kill the monsters quickly the counter decrements, but the door doesn't open.
If I kill them manually then the counter decrements and the doors open.
I know that using K doesn't give XP and such, but if the counter decrements to 0 (verified using hudPrint and counter:getValue) shouldn't it still open the door regardless of how I killed the monsters?
What I find is if I use K to kill the monsters quickly the counter decrements, but the door doesn't open.
If I kill them manually then the counter decrements and the doors open.
I know that using K doesn't give XP and such, but if the counter decrements to 0 (verified using hudPrint and counter:getValue) shouldn't it still open the door regardless of how I killed the monsters?
Re: counter anomoly?
I would think it should work. Have you made sure it does in fact open when killing them normally? Because maybe there is some other small oversight
Finished Dungeons - complete mods to play
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
Re: counter anomoly?
I can't understand it either. It's one room only on the map, so there's no possibility of something from another area affecting it.Komag wrote:I would think it should work. Have you made sure it does in fact open when killing them normally? Because maybe there is some other small oversight
There's only one counter in the room, so theres no way I could accidentally be calling the wrong counter unless Grimrock adds one on it's own, which I doubt.
There's no physical entities (switches, levers plates etc) working the counter with the exception of the shortcut button I use to spawn monsters.
The only thing decrementing the counter is the onDie hook on the modified monsters.
The counter triggers a Lua script to print out the getValue and it shows the value is decrementing whether I use K or physically kill the monster.
I've even taken the counter past 0 and into negative numbers.
I have tried at least a half dozen times using both the shortcut button and physically solving the puzzle to spawn the monsters with the same results, physically killing opens the door and just pressing K doesn't. I even tried a combination of pressing K for some and killin others but if I use K for at least on monster the door doesn't open.
The level works as designed so it's not holding up my room development, but it would be nice to know what is happening.
I have a similiar puzzle in my main dungeon I'm working on. I'm going to load that and test it a bit, I don't recall if I tried using K when I did that one.. I'll post my test results in a bit.
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
Re: counter anomoly?
Ok puzzle works the same in my main dungeon. If I kill using K, no door opens, but phyically killing the mobs opens every time.
Oh well.
Oh well.
Re: counter anomoly?
maybe that's a bug then, dunno. You could always script the door if the counter value == 0, that should be pretty darn foolproof.
Finished Dungeons - complete mods to play
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
Re: counter anomoly?
That's a good suggestion because the counter is triggering the Lua script when I use K, just not the doors. I'll give it a shot.
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
Re: counter anomoly?
So I was incorrect on the one point, the monsters are not activating the Lua script as I stated. I forgot I had added a line to the onDie hook to display the counter getValue.
When I phyically killed the monsters though it did trigger both the hard connection to the door (via the GUI) and opened a second door via a Lua script.
At this point I am going to surmise that when a monster is killed via the K key even though the counter value is decremented some flag is not set or some variable is not passed in the counter function.
Everything works as it should in game, just makes it more time consuming to test is all.
As usual Komag I much appreciate the time you take to answer my noobish queries.
When I phyically killed the monsters though it did trigger both the hard connection to the door (via the GUI) and opened a second door via a Lua script.
At this point I am going to surmise that when a monster is killed via the K key even though the counter value is decremented some flag is not set or some variable is not passed in the counter function.
Everything works as it should in game, just makes it more time consuming to test is all.
As usual Komag I much appreciate the time you take to answer my noobish queries.
-
- Posts: 52
- Joined: Sun Feb 10, 2013 12:46 am
- Location: Dorchester, MA, USA
Re: counter anomoly?
Hi Ryeath_Greystalk. If this increases your time required to test, I have a suggestion. Place one of these:
at your Starting Location, and then use that to kill monsters instead of K.
Code: Select all
cloneObject{
name = "one_hit_wonder",
baseObject = "dagger",
attackPower = 1000000,
accuracy = 1000000,
}
Re: counter anomoly?
I set my champions to have a zillion strength in my dungeon for testing, so every monster dies with one hit bare hands or with torch or whatever, then I can test for realz and not rely on k
Finished Dungeons - complete mods to play
-
- Posts: 366
- Joined: Tue Jan 15, 2013 3:26 am
- Location: Oregon
Re: counter anomoly?
Awesome ideas komag & marble. I added some weapons (sling & rocks, machette, and cudgel), but never thought about a custom thumper. Thanks.