Project Perfect Mod Forums
:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Privacy Policy :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::


The time now is Fri Apr 19, 2024 12:00 am
All times are UTC + 0
Light Tower
Moderators: Global Moderators, Tiberian Sun Moderators
Post new topic   Reply to topic Page 1 of 1 [16 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
GeneralAnthrax101
Medic


Joined: 10 Jul 2011

PostPosted: Sun Jul 17, 2011 7:22 pm    Post subject:  Light Tower Reply with quote  Mark this post and the followings unread

Hello, guys. I want to make alittle interesting bases (Campaign/Skirmish) most of the time, such as Prisons/Camps, ya'know. But I need LightTowers to face a certian direction. If that can't be done, then I want the LightTowers to do a circle motion with its spotlight. But I don't know how. If you know how, it would be really appreciated.

Back to top
View user's profile Send private message
Crimsonum
Seth


Joined: 14 Jul 2005
Location: Fineland

PostPosted: Sun Jul 17, 2011 7:33 pm    Post subject: Reply with quote  Mark this post and the followings unread

You mean you want the spotlight face a certain direction? It's possible, though the light will still perform a short, arcing sweep. Just double-click the building on the map and select Spotlight: 1 - Rules.ini setting. You can further adjust the settings in the forementioned ini file if you know what you're doing (you can even make the light stay still if you want).

_________________


Back to top
View user's profile Send private message
GeneralAnthrax101
Medic


Joined: 10 Jul 2011

PostPosted: Sun Jul 17, 2011 7:47 pm    Post subject: Reply with quote  Mark this post and the followings unread

Sounds like your talking about doing this on a Map Editor.
I am mainly talking about changing it to a Circle Motion in the rules.ini

If I have to change the spotlight motion to circular, can you tell me where to do this?

Back to top
View user's profile Send private message
Exley
Commander


Joined: 09 May 2011
Location: Approaching the Great Pyramid

PostPosted: Mon Jul 18, 2011 1:09 am    Post subject: Reply with quote  Mark this post and the followings unread

this are settings for rules.ini to be used

Code:

SpotlightSpeed=.015     ; speed in radians
SpotlightMovementRadius=0 ; offset of center of arc sweep (was 2000)
SpotlightLocationRadius=1000 ; offset from building
SpotlightAcceleration=.0025    ; acceleration in radians
SpotlightAngle=360       ; maximum suggest angle of arc sweep (was .5)


(searching the forum helps alot) #Tongue

Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Mon Jul 18, 2011 5:31 am    Post subject: Reply with quote  Mark this post and the followings unread

SpotlightAngle is in radians not degree. You have to use 6.283 for a 360° circle.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
Exley
Commander


Joined: 09 May 2011
Location: Approaching the Great Pyramid

PostPosted: Mon Jul 18, 2011 12:55 pm    Post subject: Reply with quote  Mark this post and the followings unread

well I only copy pasted what was given in one of threads on forum #Tongue

+ it works for me ok

_________________
Quote:

how did we end up here ?

this place is horrible ...

smells like balls ...


Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Mon Jul 18, 2011 1:26 pm    Post subject: Reply with quote  Mark this post and the followings unread

SpotlightAngle=123456 works ok too, but not correct.

The spotlight is hardcoded to make sweep to + SpotlightAngle and then back to - SpotlightAngle, thus in your case you tell it to turn 20626,48 circles in one direction and then 20626,48 circles in the other direction.

with 6.283 it would turn only one full circle in one direction and then another one in the other direction. A multiple of that value and you can set the exact amount of full 360° rotations it should do, which is ingame a lot more easy to use.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
GeneralAnthrax101
Medic


Joined: 10 Jul 2011

PostPosted: Mon Jul 18, 2011 7:21 pm    Post subject: Reply with quote  Mark this post and the followings unread

Well, I got the Light Tower to build. But it only does the spotlight is at the NorthWest.

Can someone give the full code, as in the entire Light Tower code with the spotlight controls? Thank you.

Back to top
View user's profile Send private message
Exley
Commander


Joined: 09 May 2011
Location: Approaching the Great Pyramid

PostPosted: Thu Jul 21, 2011 6:56 pm    Post subject: Reply with quote  Mark this post and the followings unread

the one I pasted should be full one

@Lin Kuei Ominae
I never wanted it to turn one side once and the other once
and repeating that #Tongue

unless I missunderstood you

_________________
Quote:

how did we end up here ?

this place is horrible ...

smells like balls ...


Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Thu Jul 21, 2011 7:45 pm    Post subject: Reply with quote  Mark this post and the followings unread

I know you didn't want that, but that is how it's coded.
If you give the key such a high value it can cause unexpected results. The game is quite unsafe coded (almost no exception handling) and if it's only accepting a byte value with max 255, then this could cause strange effects like a savegame bug or an IE.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
Exley
Commander


Joined: 09 May 2011
Location: Approaching the Great Pyramid

PostPosted: Thu Jul 21, 2011 8:14 pm    Post subject: Reply with quote  Mark this post and the followings unread

hmm
so there is no way to have it rotate just one way without
cause any instability?

_________________
Quote:

how did we end up here ?

this place is horrible ...

smells like balls ...


Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Thu Jul 21, 2011 8:23 pm    Post subject: Reply with quote  Mark this post and the followings unread

Well, i didn't said it would cause instability, only that it could cause it.
You can of course keep the high value, but know that this is untested terrain and if you should get a strange IE, it might take you a long time to find that one out.

And no, there's no way to make it rotate constantly only in one direction.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
Exley
Commander


Joined: 09 May 2011
Location: Approaching the Great Pyramid

PostPosted: Fri Jul 22, 2011 12:18 am    Post subject: Reply with quote  Mark this post and the followings unread

well It doesn't as bad as I thought it will hehe
in fact brings some "change" to boring one side rotation

thanks Smile

_________________
Quote:

how did we end up here ?

this place is horrible ...

smells like balls ...


Back to top
View user's profile Send private message
GeneralAnthrax101
Medic


Joined: 10 Jul 2011

PostPosted: Fri Jul 22, 2011 7:31 pm    Post subject: Reply with quote  Mark this post and the followings unread

I wanted the entire Light Tower code including the new code to make the spotlight motion go in a full circle motion continuisly. Because I think I placed the new code at the wrong place of the Light Tower...

Back to top
View user's profile Send private message
Navy SEAL
Energy Commando


Joined: 01 Dec 2005
Location: Estland

PostPosted: Wed Aug 24, 2011 11:05 am    Post subject: Reply with quote  Mark this post and the followings unread

but how to make spotlight spot an enemy unit with its light?

_________________
Welcome to the unit, I´ll see you around.
Tiberian Sun 2.05:
https://www.moddb.com/mods/tiberian-sun-205

Last edited by Navy SEAL on Wed Aug 24, 2011 11:47 am; edited 1 time in total

Back to top
View user's profile Send private message Send e-mail ModDB Profile ID
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Wed Aug 24, 2011 11:26 am    Post subject: Reply with quote  Mark this post and the followings unread

That's not possible, except on maps via triggers for already placed spotlight towers.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [16 Posts] Mark the topic unread ::  View previous topic :: View next topic
 
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © phpBB Group

[ Time: 0.1639s ][ Queries: 11 (0.0086s) ][ Debug on ]