Freezing time

Questions about how to create your own dungeons and replacement graphics and sounds.

Moderator: George Gilbert

Forum rules
Please read the Forum rules and policies before posting.
Post Reply
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Freezing time

Post by Chaos Awakes »

I don't know if it's how DM did it, probably not, but I do think the freeze life spell action should freeze everything, not just creatures. If this would break some things in DM, then have another action which freezes everything. I assumed freeze life actually froze time, in which case doors should stay open, etc.
Basically, when freeze life is cast, the game should IMHO simply add the length of time frozen to any time delays in effect for things like triggers which have been set to open a door. I should, for example, be able to have a puzzle, where you have to pull a lever, freeze time and run for the door before it closes again and there isn't enough time to get to the door before it closes without freezing time.
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

No - both DM and RTC have the freeze life as freezing *life* (!).

A general freeze time action though is an interesting idea.
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

It shouldn't be too hard, I wouldn't have thought :)

Presumably there is some sort of internal timer which determines how long it is until something that has been triggered to happen happens - a door closes, a pit opens, etc - and I assume these values must be easily accessible as the code would need to check them regularly to decide when to close a door, etc. So all you would need to do is add the length of time time is frozen to these existing values?
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

*cough do it in dungeon mechanics yourself cough*
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

Um, how?

It's not possible to do that. is it? How do I make a freeze time box that makes a door stay open for longer? I have no access to the timer that makes a door stay open.

I would want my freeze time box to stop all doors, toggling pits, any movement of any kind at all on all levels of the dungeon for a specified period of time. Exactly how can I do that with dungeon mechanics?
User avatar
Sophia
Concise and Honest
Posts: 4240
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

What do you mean "the timer that makes a door stay open"?

You could create a flooritem that looks just like a door button, but isn't cloned from a door button, so it doesn't act like one. Then, SWAP_GLOBAL the real door button for this fake one when freeze time is enacted, and SWAP_GLOBAL them again when the freeze time ends.

Your idea for a puzzle, actually, can already be done using relays rather easily, though it would be far more work to make EVERY door in the dungeon work that way.
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

What's the door button got to do with anything? The door button is just a way for the player to open a door, isn't it?
When a relay or trigger opens a door from a distance, it targets the door itself, nothing to do with the door button. so how would changing the door button do anything? If I step on a pad which says "close that door in 10 seconds" and then during that 10 seconds swap the door button for a fake, how is that going to stop the door closing after 10 seconds?
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

Oh I see what you're saying - you think I just want to stop the player using doors while time is frozen.
No, I want to delay a timer that is already set. The player steps on a pressure pad which will close a door in 10 seconds and then uses a freeze time box which freezes time for 30 seconds, so the door shouldn't close automatically for 40 seconds. 10 seconds+30 seconds that time is frozen.
User avatar
Sophia
Concise and Honest
Posts: 4240
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Chaos Awakes wrote:Oh I see what you're saying - you think I just want to stop the player using doors while time is frozen.
No, I want to delay a timer that is already set. The player steps on a pressure pad which will close a door in 10 seconds and then uses a freeze time box which freezes time for 30 seconds, so the door shouldn't close automatically for 40 seconds. 10 seconds+30 seconds that time is frozen.
Ah, as I mentioned before, that can already be done rather simply using relays and queries.

As part of the freeze time, set a counter somewhere. This counter tells whether time is frozen or not. When the time freeze expires, unset the counter. Have the door closer relay wait 10 seconds and then trigger two relays: One that immediately closes the door if time is frozen, and another that triggers both relays again after a short delay if time is frozen.
So, it will sit there until a loop until the time freeze expires, then close the door.
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

Thats very clever, I'll do that for my puzzle. Thanks (It isn't much of a puzzle, actually, it's just I need something simple to fill a room in the corner of a level before the stairs :)

This doesn't address the actual concept of freezing time though. You would require a really complex set of relays if the freeze time was to affect all doors, pits and everything else that's moving in the dungeon - that could only be done on the engine level. Mind you, the player probably wouldn't realise that a pit had or had not stopped cycling 3 levels below but I'm sure the freeze time principal would be useful for lots more. If time was frozen, for example, I would expect to see fireballs hanging in the air not moving, which would allow players to move through rooms full of shooters that would otherwise kill them.

Come to think of it, this wouldn't work at all if Freeze Time was implemented as a spell. The player could cast the spell anywhere, so there would be no known relay to affect. Doors everywhere in the dungeon should just stop mid-open, fireballs in mid air etc - because the dungeon designer can't know where the player will be when he casts the spell.
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

It would mean you need to filter each dor, pit through a relay, but toherwise one type counld be activated with the freeze life action and affect the whole dungeon

And yes, you see you can target this freeze time effect with your mechanics, anythign george would do would be, by definition, easier but limited
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

I've got it working through a cloned relay that is triggered with the object activate action. Then the freeze life spell basically sets a particular counter in the dungeon which can be tested for 1 or 0 when a door is going to close. Works ok.

I'm all for ease though. There seems to be a mentality around that "oh, you can do that already by doing X, Y and Z followed by referencing Z with X and doing A, B and C". Yeah, sure, but why not just take a minute to add a feature if it's really simple to implement and then let me just do A and save myself a lot of time.
That's like saying "Can I get my wordprocessor to write coloured letters?" "Yes, just cut and paste the text into program Z, colour the text there, and cut and paste it back". You would say, wouldn't you, "why can't I just do it without all that effort?"
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

Yes, but sometimes it doesn't take two seconds ; )
And GG has already said what he willand won't do, and the 'you can do wit with mechanics already' argument was already mentioned by him - so we are jsut tryign top point you in ways you could do it so you aren't just sitting waiting in vain

He has also said he is ameanable to making thigns easier - but really, if you don't try mecnahincs forst you won't know if it's really easy menchaically or not, so won't be able to convcentrate on the ideas you really want done
User avatar
Sophia
Concise and Honest
Posts: 4240
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Chaos Awakes wrote:I'm all for ease though. There seems to be a mentality around that "oh, you can do that already by doing X, Y and Z followed by referencing Z with X and doing A, B and C". Yeah, sure, but why not just take a minute to add a feature if it's really simple to implement and then let me just do A and save myself a lot of time.
That's like saying "Can I get my wordprocessor to write coloured letters?" "Yes, just cut and paste the text into program Z, colour the text there, and cut and paste it back". You would say, wouldn't you, "why can't I just do it without all that effort?"
You really should drop the word processor analogies; they never really work. The kinds of things you're really asking about are questions more like "why isn't there a button to make the text red, underline it, and put it in 15 point font," when no such thing is needed because there are tools that already do the same things with a little more work.

I am all for ease, too, but I am also for generic, re-usable features. Sometimes it's better to have to do a little more work, because there are so many more options with a more generic implementation. Overly specific features only end up having to be put through even more absurd levels of tweaking and such things to try to get them to do something slightly different than their initial narrow design. On the other hand, more generic features require a little more work overall, but can be used for a great many more things.

So, I believe you have misjudged the mentality around here somewhat. It is not so much for complexity, or against new features, but it is about making the most of existing features, and making sure there's a good application, and, preferably, several, for anything new added.
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

I've created a red "freeze life" box, and I've given it a new attack method which I created called "freeze time", which triggers the relay. The only problem I have now is that the freeze life box doesn't dissapear from your hand when you use the "freeze time" attack method as it does with a freeze life box. I can't find anywhere where I can say "destroy object" - there isn't such a thing in the attack method, or anywhere else that I can see. Where should I be looking?

Also, I would ideally like the box to have an attack method which does both "freeze time" and trigger my relay, in other words it would need to execute two attack methods. How do I do this - attack methods only seem to be able to perform one action, not two.
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

Go through wallitem_actions, have the relay triggers those
There should be a destroy item in the item properties when you assign the attack....it not, then use a swap to null
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

Brilliant - do you know, I hadn't even spotted the new wallitem "action". Now that I can trigger an action as well as the relay, I can swap the item in hand for null. The only problem though, it occurs to me, is that if I use SWAP_ITEM_CHARACTER_HANDS (or whatever it is), and the character happens to have a red box in both hands, won't they both vanish?

Perhaps there should be a more specific SWAP_ITEM_CHARACTER_RIGHT_HAND type thing?
User avatar
Lunever
Grand Druid
Posts: 2712
Joined: Thu Feb 14, 2002 4:47 pm

Post by Lunever »

Introducing "Freeze Time" would be funny in a way - On some Amiga versions having the time frozen was part of the copy protection, but sometimes went awry even if there wasn't any reason for the copy protection to be alerted.
Parting is all we know from Heaven, and all we need of hell.
User avatar
Sophia
Concise and Honest
Posts: 4240
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Chaos Awakes wrote:Brilliant - do you know, I hadn't even spotted the new wallitem "action". Now that I can trigger an action as well as the relay, I can swap the item in hand for null. The only problem though, it occurs to me, is that if I use SWAP_ITEM_CHARACTER_HANDS (or whatever it is), and the character happens to have a red box in both hands, won't they both vanish?

Perhaps there should be a more specific SWAP_ITEM_CHARACTER_RIGHT_HAND type thing?
Not needed.

Read the editing guide.
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

What am I looking for? I've read the guide several times - there's nothing about the SWAP_ITEM_CHARACTER actions except a single paragraph saying that they swap items in the specified place which I know.

The only other possibility I can think of for removing an item in the action hand when the object is used is to use it's "convert to" method but you can't convert to NULL.
Actually, I could convert to something that instantly expires couldn't I? I'll try that - is that what you were thinking of?
User avatar
Sophia
Concise and Honest
Posts: 4240
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Post by Sophia »

Ah.. you were asking about something that's really rather simple, and trying to make it way more complicated than it ought to be, so I thought you hadn't read up on it. Obviously, if it's still not clear, I can try to explain some more.

Anyway, you don't need to do any of that. Simply set "charges" in the attak method to 1. That'll tell the attack method to consume a charge. Then, set the object's USE convert method to NULL. It'll disappear once you've used up all the charges!
User avatar
Daecon
Expert
Posts: 329
Joined: Tue May 16, 2006 1:56 pm
Location: Upper Hutt, New Zealand

Post by Daecon »

Would this Freeze Time action also freeze the recovery time of performing an action.

Such as when you perform an attack, your action menu is grayed out for a few seconds until you can perform another action. The freeze time (if there was one) should also freeze any ongoing recovery waiting too.

It would be funny if you tried casting Fireball or Lightning Bolt while time was frozen, and the spell would be stuck in mid air in front of you. Don't take a step forward or you'll be toast!
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

again lots of hackign but doable i reckon - then again all these ideas would also be huge to do in the engine and with the penalti of being not as configureable without more work
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

DesBroDain wrote:Would this Freeze Time action also freeze the recovery time of performing an action.

Such as when you perform an attack, your action menu is grayed out for a few seconds until you can perform another action. The freeze time (if there was one) should also freeze any ongoing recovery waiting too.

It would be funny if you tried casting Fireball or Lightning Bolt while time was frozen, and the spell would be stuck in mid air in front of you. Don't take a step forward or you'll be toast!
That's the key to doing this kind of thing in the engine. The point is that you wouldn't want a generic Freeze Time action that stopped the internal clock. What you'd really want is something that benefits the party (i.e. only freeze some things). That means you'd have to decide what things were good and what were bad - and those might change from dungeon to dungeon. The whole thing is a big mess, and given that it can be done in existing mechanics, I think that's probably the best place for it.
User avatar
mikko
Craftsman
Posts: 102
Joined: Sun Jan 15, 2006 2:42 pm
Location: Helsinki, Finland

Post by mikko »

Is it possible to stop spells in mid-air and freeze a closing door in a partly open state with just dungeon mechanics?
Chaos Awakes
Artisan
Posts: 187
Joined: Sat Jan 22, 2005 2:50 pm
Location: Ipswich, UK

Post by Chaos Awakes »

You'd have to know where all the fireballs were at any particular moment and how far open all the doors were, and then I guess you could swap them for frozen non-functional graphics or something but you don't know where everything is so I'm assuming no. :(
User avatar
beowuuf
Archmastiff
Posts: 20687
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Post by beowuuf »

Stop spells mid-air - ytes, or the hooks are there to tweak this

Partially opening door - yu could constantly trigger open closes, or at worst GG can introduce a 'set door to 1/4' '1/2' etc trigger,which incidentally was something gambit asked for (seeting door opennes state) a while ago

Whatever, it's 99% there if not the full 100
Post Reply