[Request] function TurnTimeActive(bool)

7 replies [Last post]
UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 10 weeks ago. Offline
Joined: 2016-06-26
Posts: 381
Hello! Is there any function that pauses turn time yet? (And unpause!) If there's none, may we get one? Thanks ^^ [quote="TurnTimeActive"][code]function TurnTimeActive(bool) ; --[[chunk]]-- ; end --[[ Where "bool" is a boolean parameter that pauses the turn time if given true (Do nothing if the turn time is already paused), unpause the turn time if given false or nil (Do nothing if the turn time is already unpaused), switch between on or off if bool is not a boolean and not a nil value --]][/code][/quote] Note: Actually, this isn't so important, but nonetheless it still valuable as a good as a new stuff for the "Optional List" =)
[center][color=#FFFFFF]╟───NW──────┼──────N╢[/color][/center] [float=left][color=#FFFFFF]╓──────────────────╖[/color][/float][float=right] [color=#FFFFFF]╓──────────────────╖[/color][/float] [float=left][color=#FFFF00]⠀HP:[/color] [color=#FF0000]██████████[/color] [color=#00FF00]1E9/1E9[/color][/float][float=right][color=#00FF00]1E9/1E9[/color] [color=#0000FF]██████████[/color] [color=#00FFFF]:MP [/color][/float] [float=left][color=#FFFFFF]╙──────────────────╜[/color][/float][float=right] [color=#FFFFFF]╙──────────────────╜[/color][/float]
Wuzzy
Wuzzy's picture
User offline. Last seen 3 days 22 hours ago. Offline
Joined: 2012-06-20
Posts: 1301
Good suggestion. But there should be a way to un-pause the timer as well. Just saying. Wink Smiley
Hi, I am a Hedgewars developer. Smile
UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 10 weeks ago. Offline
Joined: 2016-06-26
Posts: 381
[quote=Wuzzy] Good suggestion. But there should be a way to un-pause the timer as well. Just saying. Wink Smiley [/quote] Welp! You're absolutely right xD Didn't realize it, lol. Yes please, add them both x) Anyway, tbh I thought there's already one since it sounds like a very basic feature that Hedgewars should have in the early stage, or up. Hmmm... =/ PS: OP updated...
[center][color=#FFFFFF]╟───NW──────┼──────N╢[/color][/center] [float=left][color=#FFFFFF]╓──────────────────╖[/color][/float][float=right] [color=#FFFFFF]╓──────────────────╖[/color][/float] [float=left][color=#FFFF00]⠀HP:[/color] [color=#FF0000]██████████[/color] [color=#00FF00]1E9/1E9[/color][/float][float=right][color=#00FF00]1E9/1E9[/color] [color=#0000FF]██████████[/color] [color=#00FFFF]:MP [/color][/float] [float=left][color=#FFFFFF]╙──────────────────╜[/color][/float][float=right] [color=#FFFFFF]╙──────────────────╜[/color][/float]
nemo
nemo's picture
User offline. Last seen 19 hours 25 min ago. Offline
Joined: 2009-01-28
Posts: 1861
I'm guessing although the name was not great he really meant. TurnTimeActive(bool) for true/false
-- Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
UltiMaxKom
UltiMaxKom's picture
User offline. Last seen 4 years 10 weeks ago. Offline
Joined: 2016-06-26
Posts: 381
[quote=nemo] I'm guessing although the name was not great he really meant. TurnTimeActive(bool) for true/false [/quote] True! Haven't thought for a good name tho, I just type it in real fast without any brainstorm or anything. And yeah, I guess "TurnTimeActive" is way better than mine hehehe. Let it be that way then! ^^ PS: OP updated, again...
[center][color=#FFFFFF]╟───NW──────┼──────N╢[/color][/center] [float=left][color=#FFFFFF]╓──────────────────╖[/color][/float][float=right] [color=#FFFFFF]╓──────────────────╖[/color][/float] [float=left][color=#FFFF00]⠀HP:[/color] [color=#FF0000]██████████[/color] [color=#00FF00]1E9/1E9[/color][/float][float=right][color=#00FF00]1E9/1E9[/color] [color=#0000FF]██████████[/color] [color=#00FFFF]:MP [/color][/float] [float=left][color=#FFFFFF]╙──────────────────╜[/color][/float][float=right] [color=#FFFFFF]╙──────────────────╜[/color][/float]
KoBeWi
KoBeWi's picture
User offline. Last seen 2 days 21 hours ago. Offline
Joined: 2010-12-25
Posts: 564
More like [b]Set[/b]TurnTimeActive.
[url=https://www.hedgewars.org/node/6490]My themes[/url] / [url=https://www.hedgewars.org/node/6995]Theme Editor[/url] / [url=https://www.hedgewars.org/node/6603]Code contributions[/url] / [url=https://www.hedgewars.org/node/6996]Dank[/url]
nemo
nemo's picture
User offline. Last seen 19 hours 25 min ago. Offline
Joined: 2009-01-28
Posts: 1861
Guess it depends on whether one thinks of it as a getter/setter or a verb action. But fine with that too, still describes the boolean.
-- Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev
Wuzzy
Wuzzy's picture
User offline. Last seen 3 days 22 hours ago. Offline
Joined: 2012-06-20
Posts: 1301
Implemented in -dev as SetTurnTimePaused(isPaused). http://hg.hedgewars.org/hedgewars/rev/d670e4efe1ed
Hi, I am a Hedgewars developer. Smile
Copyright © 2004-2023 Hedgewars Project. All rights reserved. [ contact ]