[TC] Gaming Forums
Siren System - Work In Progress - Printable Version

+- [TC] Gaming Forums (https://forum.city-driving.co.uk)
+-- Forum: Community Area (/forumdisplay.php?fid=14)
+--- Forum: Live for Speed Area (/forumdisplay.php?fid=17)
+--- Thread: Siren System - Work In Progress (/showthread.php?tid=5255)

Pages: 1 2


Siren System - Work In Progress - Tommer - 2012-12-05 13:09

Hi all. Thought I would share with you a quick preview of my latest creation. It's a siren script inspired by Elmo's [TC] Lights, just works abit differently and a couple different features.

This one in particular, the siren and strobe is controlled like in TC Lights with Page Up/Down, However it's configured also on your G27 to turn your bottom right red button on your wheel to do different functions.

When the siren is on, pressing and holding on the button will switch to horn 1 and beep for as long as you hold it until you release the button.

If you release the button and then within 800ms press it again, it goes to horn 4, which stays on until you press the button again.

If your siren is not on, it simply turns the button into a regular horn Smile

Program pauses when LFS is not in focus or you hit "t" to chat.

Does have its bugs but i'm still working on it Smile

Demo video - Sorry for the quality Tongue





It's not stable so I won't release an executable version yet. However if you want to test it you'll need Autohotkey, and to save the following source code into a text file with a .ahk extension then run it. Yes. Opensource Smile

Source Code/Script whatever (Click to View)
Planned (optional features)
- Flappys operate !x Left <<< !x Right >>> when siren is on, and also turn off strobe and indicate temporarily using the indicator sound
- GUI of some sort
- More as I think of more things


RE: Siren System - Work In Progress - Chill . - 2012-12-05 15:55

0:45 ice cream van Smile ?


RE: Siren System - Work In Progress - BP - 2012-12-05 16:13

(2012-12-05 15:55)Rainis . Wrote:  0:45 ice cream van Smile ?

Dunno what ice cream vans you have in your country.. Tongue


RE: Siren System - Work In Progress - Chill . - 2012-12-05 16:44

BiggrinBiggrin just kidding Tongue


RE: Siren System - Work In Progress - Dan - 2012-12-05 22:05

Great system.. I am hopefully getting a G27 soon so would be perfect!

Off topic: Where did you get them FZ5 Sounds from? Tongue


RE: Siren System - Work In Progress - Blade3562 - 2012-12-05 23:08

Are you using ENB or something?


RE: Siren System - Work In Progress - Mr. NB - 2012-12-05 23:28

My only problem with changing the horn while being in chase, is that sometimes, due to lag or whatever else, horn does not change for everyone. I can hear it being on #5, while for example other players still hear it as #4.

This is why i myself, have stopped using piercers. It might work fine, if you stop the strobe program, then change horns and then start the program again, but this is way too much hassle, for when i am in the chase.

At least this is my experience, with using scripts or Logitech Profiler.


RE: Siren System - Work In Progress - Josh - 2012-12-05 23:41

You could easily write a script (or Profiler Script) that Stops the horn, changes it, restarts the horn in one button click - This would prevent sound lag and of course wouldn't be any hassle whilst chasing.


RE: Siren System - Work In Progress - Rasmus - 2012-12-06 00:26

I dont get how this script works


RE: Siren System - Work In Progress - Tommer - 2012-12-06 08:51

With the lag issue - The script does already combat this

Quote:WinWaitActive, Live for Speed
Send {SHIFTDOWN}{H}{SHIFTUP}
Send {SHIFTDOWN}
Sleep, 50
Send {SHIFTUP}
Keywait, Joy22
Send {SHIFTDOWN}{H}{SHIFTUP}
Send {SHIFTDOWN}{H}{SHIFTUP}
Send {SHIFTDOWN}{H}{SHIFTUP}
Send {SHIFTDOWN}{H}{SHIFTUP}
Send {SHIFTDOWN}
Sleep, 50
Send {SHIFTUP}

Shift stops the horn, Holding shift for 50 ms between horn change means that peope do hear the change. Smile


RE: Siren System - Work In Progress - Orangeā„¢ - 2012-12-06 16:55

I'm liking the sound of this Tommer! Good work so far!


RE: Siren System - Work In Progress - Tommer - 2012-12-09 12:46

A GUI is in progress. You'll be able to map which buttons you want to use and other program behaviour.

[Image: capturevgj.jpg]

Plans so far;

Behaviour
You'll be able to set it to open another program when it opens such as LFS or mediaplayer etc.
You can choose if Indicators will also send extra keys when the strobe is on EG Press Ctrl+f1 for !x Suspect turned left
Possibly more..
Choose if chasing somebody automatically turns on sirens by setting your !chase hotkey

Buttons
Set your toggle siren/strobe buttons, horn button, indicator buttons, wheel axis (I'm working to give this program indicator functionality with auto-off so that you don't need to launch the other indicator program)

Status
Shows what's on and what's not, just eye candy for 2 monitor users who want to see stuff light up when they press buttons. Tongue


RE: Siren System - Work In Progress - KaraK - 2012-12-09 12:50

Looks good Tommer Smile
One question though: Will players without a wheel be able to use it too? Tongue


RE: Siren System - Work In Progress - Nipper - 2012-12-09 14:11

(2012-12-09 12:50)KaraK Wrote:  Looks good Tommer Smile
One question though: Will players without a wheel be able to use it too? Tongue

I would guess yes.

Should work with any control input, including gamepads and joysticks.

Of course I haven't tried it, but based on past experiences with getting gamepads to work where they shouldn't, it will work.

Maybe not out of the box, but yes, it will work without a steering wheel.

Looking good Tommer, it could very well be the best "cop program" out there that I have seen.


RE: Siren System - Work In Progress - Tommer - 2012-12-12 16:19

Updates

I have encountered an unexpected limitation in my program.

I am able to have variable hotkeys except for joystick(wheel) buttons which cannot be defined as a variable.

In other words, you will not be able to assign in my program Wheel buttons to functions unless you using your profiler set your wheel to press certain non-joystick buttons itself, then in my software set the key that in your profiler you set.

(Sorry for the confusing explanation there)

I can and plan to support using atleast a wheel button for a horn out of the box. But this will require your help if you wish that your wheel is supported. The reason being is that I do not know the button numbers of all your various wheels.

If you want your wheel to be supported with a horn button. You need to do the following to help me help you;

1 - Download the below file
2 - Run the Joystick Detection EXE file below.
3 - Next to your mouse will appear an info box - Press Buttons on your Wheel. Next to "Buttons Down" Will appear a number or a button label. Note all of those numbers/labels.
4 - Reply to this thread, write the following;
Your Wheel Model (EG. G25)
Each Button Number, and What Button that is. EG. Number 3 = Square button on the right, 4=Circle Button.

The application can be closed in your system tray in the bottom right (Right click the green H symbol and click exit)

Thank you for helping. You need not do this if you have a G27 Since I already have one to test with myself Smile


RE: Siren System - Work In Progress - Lewis - 2012-12-12 19:57

(2012-12-09 12:46)Tommer Wrote:  Status
Shows what's on and what's not, just eye candy for 2 monitor users who want to see stuff light up when they press buttons. Tongue

So sort of like this... ?

[Image: legend6.jpg]

Obviously not as many but this sort of idea with then turning orange or something when on?


RE: Siren System - Work In Progress - Tommer - 2012-12-12 20:10

(2012-12-12 19:57)Lewis Wrote:  
(2012-12-09 12:46)Tommer Wrote:  Status
Shows what's on and what's not, just eye candy for 2 monitor users who want to see stuff light up when they press buttons. Tongue

So sort of like this... ?

[Image: legend6.jpg]

Obviously not as many but this sort of idea with then turning orange or something when on?

If achievable, yes that's the plan.


As stated before if you can contribute wheel buttons for your wheels idk G25 Driving force etc I would greatly appreciate it


RE: Siren System - Work In Progress - Lewis - 2012-12-12 20:20

iv got a g27 too but i can do some research to find out wheel buttons if you like.

On a little side note. Do you think it would be possible to config it so instead of changing to horn 1 between 5 and 4. To make it go to 3 in a different version or being able to change that when you open the program?


RE: Siren System - Work In Progress - Tommer - 2012-12-12 20:56

(2012-12-12 20:20)Lewis Wrote:  iv got a g27 too but i can do some research to find out wheel buttons if you like.

On a little side note. Do you think it would be possible to config it so instead of changing to horn 1 between 5 and 4. To make it go to 3 in a different version or being able to change that when you open the program?

Nah don't do research, often its wrong, for example LFS Reports different button numbers for the G25 than what the program hooks onto. Using the program I posted above I know for sure that the button numbers are correct

On your side note I think that's very possible to do, albeit it would probably need alot of coding o.o


RE: Siren System - Work In Progress - Towcat - 2012-12-15 13:01

modell: Thrustmaster T500RS

this picture shows all you need i think... i just added the pov numbers.
the normal buttons have the same number when running your script

http://www.file-upload.net/download-6930382/T500RS_Buttons.jpg.html

do you plan to include buttons for indicators?
i am using 2 programs now, tc lights and one for indicators, so would be useful to have it both in one