Home   Help Search Login Register  

Author Topic: How do you turn the lights out?  (Read 1192 times)

0 Members and 1 Guest are viewing this topic.

abomb1508

  • Guest
How do you turn the lights out?
« on: 06 Sep 2002, 12:31:26 »
i thought it a bit unusual to have the lights going in wartime at 4:30 am in a town taken over by the army, so i was wondering if there was a command line to turn them out? hopefully another to turn them back on again when the alarm was raised would be nice too.

Cheers,

A-Bomb

Developer for CoC www.thechainofcommand.com

mikeb

  • Guest
Re:How do you turn the lights out?
« Reply #1 on: 06 Sep 2002, 15:59:26 »
If you've got Res then do the following:

Turn on object ids and find the lampost

Then in a trigger you can put :

(object IDNUMBER) switchlight "OFF"

You can use ON, OFF or AUTO in the last part.

M

Offline Wolfrug

  • Addons Depot
  • Former Staff
  • ****
  • Official OFPEC Old Timer
Re:How do you turn the lights out?
« Reply #2 on: 07 Sep 2002, 09:38:40 »
Or if you're not using that fancy RES malarky, you can do it with some good ol' fashioned nearestObject'ing.

place gamelogic close to where the lamppost is, name gamelogic (GL1, in example).

Make trigger, and place following into activation field:

lamp= nearestObject [GL1, "StreetLamp"]; lamp switchLight "OFF"

should do the same as mikeb's suggestion. Although if you do it his way you're a wuss. Godarnit. (*needs OFP:R*)

Just repeat for all streetlamps. Good luck!

Wolfrug out.
"When 900 years YOU reach, look as good you will not!"

abomb1508

  • Guest
Re:How do you turn the lights out?
« Reply #3 on: 08 Sep 2002, 13:03:53 »
well, i do have res (harhar) and although i do not like to be called a wuss, they always say the simplest solution is often the best, because there are then less places that things can go wrong.

so i'll take option 1. but how do i find which id is the lamppost?