Jump to content
The Dark Mod Forums

Newbie DarkRadiant Questions


demagogue

Recommended Posts

Is it possible to set a "func_rotating" entity to slowly warm up or slow down when being triggered rather than just abruptly stopping?

 

I have tried "accel_time" and "decel_time" but to no avail.

Or you can bind i.e. 3 nodraw rotators in chain and start them in sequence.

Edited by ERH+
  • Like 1

S2wtMNl.gif

Link to comment
Share on other sites

For more control use a func_mover, as grayman said.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

$<name of func_rotator>.activate($player1); will turn it on if its not, and turn it off if it is running. you need a true/false boolean condition to set at beginning if rotator is on or off.

true for on, false for off

then you can use if ( rotator_on ) do something or if ( !rotator_on ) do something else.

Link to comment
Share on other sites

I've made this but it don't want to work, keep triggering rotator regardless if it moves or not:

 void rotate_stop()
 {
 boolean   question = $rotator.isRotating();

    if (question = true)
    {
     $rotator.activate($player1);
    }
    else
    {
     $light.activate($player1);
    }
}
Edited by ERH+

S2wtMNl.gif

Link to comment
Share on other sites

$rotator.stopRotating(); is not working? I don't want turn it on/off, how can I make it stop regardless if it is moving or not?

I'm most curious whether this is in some way related to your metal & steam monster. The specific script you posted looks to be for something else, but after working that out you'd be armed with the knowledge to really handle that beast. What a sublime way to terrify the playerbase that'd be.

Link to comment
Share on other sites

Scorpion was based on pendulums with can't be stopped/ started even via script in satisfactory way too, but I always can replace pendulum with 4 doors bound together and activated not at once. This one is for gearbox where I need to reset one gear's movers to activate other one, without knowing if previous was using given mover (rotator in this case).

S2wtMNl.gif

Link to comment
Share on other sites

Scorpion was based on pendulums with can't be stopped/ started even via script in satisfactory way too, but I always can replace pendulum with 4 doors bound together and activated not at once. This one is for gearbox where I need to reset one gear's movers to activate other one, without knowing if previous was using given mover (rotator in this case).

 

A Mechanist in action!

  • Like 1

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

So, I'm working on this door that comes out of a basement at an angle and I can't get the door to open properly. I've scoured tutorials and the forums but couldn't find an answer. This is what the door looks like unopened: http://imgur.com/a/yicQf And this is what it looks like opened: http://imgur.com/nbfu8rT. How do I get the door to open properly? Thanks for the help!

Link to comment
Share on other sites

I would avoid making doors like that at all costs. They are a lot of trouble to make, are problematic for the AI and do not give much extra benefit.

 

If I were you, I would simply make an open ramp chute which ends in a normal upright door. Like the cellar access in Protecting the Flock, near the player start.

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

It's not so much the AI i'm worried about in that particular area, but after all the trouble this #$@! door has given me, I might have to do what your suggesting.

Link to comment
Share on other sites

That is probably the easiest: either make a normal door (AI ok) or trap door (AI cannot use).

 

Now that I gave it more thought, here is how it might be really easy to do. You know, if you really really really need a slanted door like that.

 

1) Make your door model in DR. Build it straight like a normal door. Place the door origin into the correct position (ultra-important as the door rotates around the origin.) I think there was a bug in the ase exporter that when exporting, you must choose an option which prevents the ase exporter placing the origin in the middle of the model. IIRC the MAP origin must touch the resired MODEL origin when exporting.

2) export the door as .ase model

3) import the door model. Check that the door model origin ended up in the right position.

4) place your door. Now, when you rotate the MODEL door, the origin will rotate with it. This does not happen wih normal DR built stuff. This is why we exported the door into a model.

5) check which one of the rotation axes the door should rotate around.

6) make the door model func_static into a tdm_mover_door_rotating (or whatever the class name was.)

7) give it rotate spawnarg where you make it rotate around the axis you checked in phase 5. Red is z, blue is y, green is x (IIRC).

8) ready

 

 

Do note that I've not tested this. But it might work. Still, the problem is that the AI probably cannot use it, which is usually poor design. You want the AI to follow the AI as well as they can.

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

when exporting, you must choose an option which prevents the ase exporter placing the origin in the middle of the model. IIRC the MAP origin must touch the resired MODEL origin when exporting.

Yes, you need to uncheck the option box named 'center around 0,0,0', then move the door so that the map origin is where you want the door's origin. (Though I believe brush&patch entities get converted into models at map load anyway so that the distinction in rotation behaviour only applies inside the editor).

 

 

Some additional viewpoints:

- I had a slanted basement door + ladder in Down by the Riverside. The door rotated upwards so that it only moved on one axis - it's very problematic to use multiple axes. Still, I'm fairly sure AIs wouldn't use this door even if it had stairs.

- You can get nonstandard doors that will be used by AIs if you make them sliding doors without rotation. You need to place a vertical door-like nodraw brush intersecting the door in the middle in order to get AI door handling. This can all be one entity, as I found out since last posting here. You also need to place door handling position entities, see the Doors wiki page for that.

- The option I'd go for in this case here as already suggested would be to make a normal door at the bottom of the staircase and leave the top open.

Edited by Dragofer
Link to comment
Share on other sites

So, I'm working on this door that comes out of a basement at an angle and I can't get the door to open properly. I've scoured tutorials and the forums but couldn't find an answer. This is what the door looks like unopened: http://imgur.com/a/yicQf And this is what it looks like opened: http://imgur.com/nbfu8rT. How do I get the door to open properly? Thanks for the help!

You have to set the rotate spawnarg accordingly. What did you set it to?

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

Thanks for the help Sotha and Dragofer, I will try this later on today and hopefully come back with good news! And Obsttorte: I set the rotate spawnarg to many things trying to get it to work, like 90 0 0, -90 0 0, -45 0 0, etc but none of those seemed to work.

Link to comment
Share on other sites

This issue has come up many times & it's always failed because the origin doesn't rotate. Somebody even got clever and tried to make a script to rotate it directly by computed rotations in terms of xyz axis rotations (which is how the script function works), but it turns out the math involved it that is kind of insane, quarternions and the like, and never looked right. It's best to drop any attemp that involves a standard door. Sotha's approach sounds more promising.

What do you see when you turn out the light? I can't tell you but I know that it's mine.

Link to comment
Share on other sites

A func_splinemover stores a NURBS curve you can make in DR, and you can have a script tell a func_mover or func_mover_amodel to follow the curve. These escalators are spline movers; as you can see from that post I've been having trouble with their physics, so in fact they might not be suited for doors anyway.

Some things I'm repeatedly thinking about...

 

- louder scream when you're dying

Link to comment
Share on other sites

On slanted doors:

I played around with it last night but could not get it to work. It tried the method I mentioned in my last post. Here is what I found:

1) DR built objects rotate around world axis (already known )

2) lwo model door rotates also around world axis, even though the rotation spawnarg description claims that models rotate around origin.

3) I was able to get the slanted door to open with combination rotation so that opens to the correct position, but the door momentarily flies off the hinges.

4) the door handles, when on slanted doors, were working correctly, so it hints it may be possible to get it working. It is not clear at present why slanted door handle rotates around it's origin when tilted, but tilted model door rotates around world. Perhaps lwo/ase models are treated differently, or it has something to do with binding.

 

I'll look further into this at my next fragment of free time.

 

If this path turns out as a failure, the next thing which might work would be to make a slanted door in modeling software and animate it to open, just like Arcturus did thst shattering statue some years ago...

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

Thanks for the help Sotha and Dragofer, I will try this later on today and hopefully come back with good news! And Obsttorte: I set the rotate spawnarg to many things trying to get it to work, like 90 0 0, -90 0 0, -45 0 0, etc but none of those seemed to work.

multiply the rotate spawnarg with the rotation spawnarg to get the new rotation. This should work imho.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • Petike the Taffer  »  DeTeEff

      I've updated the articles for your FMs and your author category at the wiki. Your newer nickname (DeTeEff) now comes first, and the one in parentheses is your older nickname (Fieldmedic). Just to avoid confusing people who played your FMs years ago and remember your older nickname. I've added a wiki article for your latest FM, Who Watches the Watcher?, as part of my current updating efforts. Unless I overlooked something, you have five different FMs so far.
      · 0 replies
    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 4 replies
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
×
×
  • Create New...