[FilterScript] [FS] Countup & Countdown Timers v3 [UPDATED]
#1

[FS] Countup & Countdown Timers v3


Description: simple countup and countdown timers

Commands: /count - brings up the main menu

Instructions: copy from pastebin, save and compile, add to filterscripts line

Код:
if you would like something to happen when the countdown timer has finished, edit line 219

219	// do somthing here if you want
220	// eg
221	// SetGravity(0.008)
222	SendClientMessageToAll(COLOR_GREY, "Times up!");
Screenshots:


Position 1

Position 2

Download:
http://pastebin.com/f35b98bfe v3
http://pastebin.com/f54e5eea2 v2
http://pastebin.com/f1c03995e v1

please leave comments
Reply
#2

Quote:
Originally Posted by mascii
Код:
edit your desired countdown time in three places
I'm not quite sure that's a selling point. Only having to change 1 set of variables would surely be easier than having to hunt down and change 3?
Reply
#3

Quote:
Originally Posted by Weirdosport
Quote:
Originally Posted by mascii
Код:
edit your desired countdown time in three places
I'm not quite sure that's a selling point. Only having to change 1 set of variables would surely be easier than having to hunt down and change 3?
Yeahs ill try release an update, im new to scripting, maybe ill make it an ingame command to set the countdown time
Reply
#4

Quote:
Originally Posted by mascii
Quote:
Originally Posted by Weirdosport
Quote:
Originally Posted by mascii
Код:
edit your desired countdown time in three places
I'm not quite sure that's a selling point. Only having to change 1 set of variables would surely be easier than having to hunt down and change 3?
Yeahs ill try release an update, im new to scripting, maybe ill make it an ingame command to set the countdown time
Well you'll need to use either strtok of sscanf. It is preferable to use sscanf, as it's faster and uses less processing power (and I feel it's alot easier to use aswell!)
Reply
#5

thanks for the tip, i have some idea of how to use strtok, but sscanf i have never heard before, ill look into it
Reply
#6

Pointing you in the right direction:

Usage of sscanf
"Latest copy" of sscanf
Reply
#7

Quote:
Originally Posted by Weirdosport
Pointing you in the right direction:

Usage of sscanf
"Latest copy" of sscanf
thanks, ill use in my next project

v2 updated, see first post
Reply
#8

looks great
Reply
#9

Looks good, the main thing I have to comment on is the list of times for the count down. It looks weird having each time listed twice, maybe a sub menu is needed to choose between pos 1 and 2, and then in each one there are times.. like:



CountDown
  • Pos 1
  • Pos 2

Pos 1
  • 5 Minutes
  • 60 Minutes

Pos 2
  • 5 Minutes
  • 60 Minutes
Reply
#10

yeah, does look a bit messy

i may update

thanks for feedback

edit:

updated to v3

see first post
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)