Roving Spotlight?

Discussion in 'Mapping Questions & Discussion' started by FlavorRage, Mar 16, 2010.

  1. FlavorRage

    FlavorRage L4: Comfortable Member

    Messages:
    197
    Positive Ratings:
    57
    Hi! I'm working on a nighttime urban KOTH map and I have a skybox with lots of skyscrapers. I would like to have some roving spotlights in the background moving around the towers. How would I got about doing this? A particle effect? How would I make it move? Thanks for any and all help. :)
     
  2. Cynick

    Cynick L4: Comfortable Member

    Messages:
    153
    Positive Ratings:
    144
    Assuming you mean for the light to rotate in a circle, theatre/L4D style:

    You can probably make a point_spotlight and parent it to a momentary_rot_button (func_rotating is broken in tf2).
     
  3. FlavorRage

    FlavorRage L4: Comfortable Member

    Messages:
    197
    Positive Ratings:
    57
    Seems simple enough. Any idea how I might get it to go back and forth from two points, pausing at each end? I'll do rotating if I can't manage the other.
     
  4. Cynick

    Cynick L4: Comfortable Member

    Messages:
    153
    Positive Ratings:
    144
    Do you mean the entire light moving? Or just the beam changing it's direction?

    For the first one you could use a func_movelinear, and set up it's outputs like this: (assuming you want it to pause for 2 seconds):

    OnFullyClosed | !self | Open | <nothing> | (Delay)2
    OnFullyOpen | !self | Close | <nothing> | (Delay)2
     
    Last edited: Mar 16, 2010
  5. Tapp

    Tapp L10: Glamorous Member

    Messages:
    776
    Positive Ratings:
    211
    The func_rotating is fixed in the FGD pack, isn't it?
     
  6. Tehrasha

    Tehrasha L3: Member

    Messages:
    115
    Positive Ratings:
    26
    func_rotating will rotate the brush only.
    When you attempt to parent something to it it stops rotating.

    Thus, the momentary_rot_button hack. (which works very)
     
  7. A Boojum Snark

    aa A Boojum Snark Toraipoddodezain Mazahabado

    Messages:
    4,769
    Positive Ratings:
    5,527
    Come on man, I keep saying it every month it seems. :( I can't actually change anything about how entities work. That's all in the code, the FGD merely tells Hammer what to display.
     
  8. Tehrasha

    Tehrasha L3: Member

    Messages:
    115
    Positive Ratings:
    26
    Still, its major bonus points that your resource pak makes things so much easier to do, that it can be mistaken for increased functionality. :)
     
  9. Cynick

    Cynick L4: Comfortable Member

    Messages:
    153
    Positive Ratings:
    144
    Ironically, Valve has a func_rotating in the skybox of 2fort intended to make the clouds rotate (but of course they don't because func_rotating doesn't work right). However, when the map is booted in Garry's mod, the clouds suddenly start rotating because func_rotating works in Gmod :O
     
  10. Terr

    aa Terr Cranky Coder

    Messages:
    1,591
    Positive Ratings:
    405
    I got a little laugh out of that too. (Before replacing it with a physics motor.)

    I also had some promising results at replacing the rotating clouds with a special particle system which would quickly emit and spin-randomize the clouds before settling into a steady state.
     
  11. Tehrasha

    Tehrasha L3: Member

    Messages:
    115
    Positive Ratings:
    26
    Yup. Radar dish on top of Point B in cp_gravelpit is supposed to rotate too.
     
  12. Tapp

    Tapp L10: Glamorous Member

    Messages:
    776
    Positive Ratings:
    211
    Could this be a sign that valve plans on fixing func_rotating? Or maybe its just a reminder that most of the mappers prefer goldsrc (like the func_illusionaries used in l4d, which the entity description says should be a func_brush).