Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Praise player message for good shooting - Timer based - Similar to Quake 3/Live.

Author
Message
TZap
19
Years of Service
User Offline
Joined: 29th Aug 2005
Location:
Posted: 1st Oct 2010 16:21 Edited at: 1st Oct 2010 16:22
In Quake 3/Live, if you shoot more than one entity in quick succession, an announcment praises the player for his skill.

This process does just that. Uses global variable 2.

I've attached a zip file containing a txt and fpi files.

In the txt file, put the code into the setuplevel.fpi script.

Set the timeddestroyscript.fpi as the destroy script in two character entities.

When you shoot the first entity, the timer starts. I've used the etimer command so you will need the latest version of fpsc. If you shoot the second entity within about 3.5 seconds, a sound will play.

If you do not, the timer resets and the process starts again with the next entity shot. I've used a stock sound but replace this with a message to praise the player for his skill!

One thing I cannot be sure of is if the etimer command takes into account different processor speeds.

Attachments

Login to view attachments
Seth Black
FPSC Reloaded TGC Backer
19
Years of Service
User Offline
Joined: 22nd Feb 2005
Location: Pittsburgh, PA
Posted: 1st Oct 2010 19:08
...this looks like a very cool feature.

Thanks for sharing it.

TZap
19
Years of Service
User Offline
Joined: 29th Aug 2005
Location:
Posted: 1st Oct 2010 23:31
Thanks mate. I do find it's a good way to learn scripting. Try and encorporate features in your favourite games into fpsc.

Login to post a reply

Server time is: 2024-11-24 19:36:05
Your offset time is: 2024-11-24 19:36:05