Timer running slow when placed in other levels

Talk about creating Grimrock 1 levels and mods here. Warning: forum contains spoilers!
guigr
Posts: 16
Joined: Wed Apr 11, 2012 10:58 pm

Timer running slow when placed in other levels

Post by guigr »

I have some moving teleporters in my 4th level which require a lot of timers to activate/desactivate. So i wanted to move them to another floor to clear the view a bit.

Sadly I found out that everything was working a lot slower. The timer was set at 0.8sec between each teleporter and suddenly it took 3-4 seconds.
Is this a known bug or is there is a workaround?
User avatar
Trollmann
Posts: 24
Joined: Sun Apr 15, 2012 6:31 pm

Re: Timer running slow when placed in other levels

Post by Trollmann »

I think that's how the game works. Everything moves slower on the levels you're not in at the moment. Same as when you sleep, everything moves 2x faster, timers included.

Have you tried scripting the timers? That way they won't take any room from your editor view, or just move them all in one spot when you've set them out and tested that they're working like intended, possibly into some corner of the map, nearest to the spot the teleporters are located.

The editor still has a room for improvements when talking about UI, possibly filters to hide items / logistics / monsters etc.

Yesterday I was actually thinking about making a topic or something about basics how to start editing your levels, how several things work, things to try to avoid etc.
User avatar
Isaac
Posts: 3185
Joined: Fri Mar 02, 2012 10:02 pm

Re: Timer running slow when placed in other levels

Post by Isaac »

I notice this effect with my pitImmunity mod. If you place one or more pits below a pit and the party falls through (multiple floors); the timer handling the immunity gets waaay off.
It can leave the party immune to damage for many seconds after they land; or revoke their immunity before they land.
guigr
Posts: 16
Joined: Wed Apr 11, 2012 10:58 pm

Re: Timer running slow when placed in other levels

Post by guigr »

Thanks, scripting seems a good idea even if I suck at that. There's some examples that might help me around here :)
User avatar
Trollmann
Posts: 24
Joined: Sun Apr 15, 2012 6:31 pm

Re: Timer running slow when placed in other levels

Post by Trollmann »

guigr wrote:Thanks, scripting seems a good idea even if I suck at that. There's some examples that might help me around here :)
I'm a newbie myself, when it comes to Lua :) Still I've started to use the script entity in increasing manner, and they tend to do the same things as counters etc. but even more flexibly, and cleaner of course!
User avatar
Komag
Posts: 3658
Joined: Sat Jul 28, 2012 4:55 pm
Location: Boston, USA

Re: Timer running slow when placed in other levels

Post by Komag »

This is an interesting "bug". I suppose it's for optimization and performance reasons, which makes a lot of sense. In the original game there wasn't a lot of multi-level interaction going on.
Finished Dungeons - complete mods to play
User avatar
Montis
Posts: 340
Joined: Sun Apr 15, 2012 1:25 am
Location: Grimrock II 2nd playthrough (hard/oldschool)

Re: Timer running slow when placed in other levels

Post by Montis »

It would be really interesting to have a dev comment on this and the multipliers involved. I mean this could make for some interesting things like an "ethereal realm where time moves slower" kind of thing :D
When destiny calls, the chosen have no choice.

My completed dungeon (LoG1): Hypercube
SpacialKatana
Posts: 163
Joined: Fri Sep 14, 2012 6:20 pm

Re: Timer running slow when placed in other levels

Post by SpacialKatana »

I noticed this at the beginning of the beta when testing lower levels, my timer intro subtitles on the first floor take ages to play even though they only had 7 sec delays.

It's definitely a performance issue (ie to help/aid performance) , scripts, timers etc on your CURRENT level/floor will be prioritised, as that's the stuff that directly effects your game experience. A lot of games do this, and without added code from the devs I don't expect it to change ;)

AH obviously wanted this software to work/run well on older systems (good business practice) as we don't all own top spec rigs ...*cough* you should hehe :)
User avatar
petri
Posts: 1917
Joined: Thu Mar 01, 2012 4:58 pm
Location: Finland

Re: Timer running slow when placed in other levels

Post by petri »

The current level is updated every frame, the level above every even frame and the level below every odd frame. The remaining levels are updated in round robin fashion, one level per frame. Hope this helps!
User avatar
Komag
Posts: 3658
Joined: Sat Jul 28, 2012 4:55 pm
Location: Boston, USA

Re: Timer running slow when placed in other levels

Post by Komag »

hmm, that's a good clue, but I'm not quite clear...

what about a 4 level dungeon, and you're on level 3. So level 2 is updated even frames, level 4 on odd frames, but how often does level 1 get updated in that situation? Every frame?

What about a 6 level dungeon and you're on level 1? Level 2 updated every odd frame, and levels 3-6 take turns 3,4,5,6,3,4,5,6,etc, right?
Finished Dungeons - complete mods to play
Post Reply