The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Vote system tag account?
Author Message
Lazarus
Master
**

Posts: 352
Likes Given: 11
Likes Received: 7 in 6 posts
Joined: Jun 2012
Reputation: 1

Hybris Ultima Online

Post: #6
RE: Vote system tag account?
(10-24-2012 09:56 PM)Mordaunt Wrote:  Equipped timers don't tick while a player is logged off....
Also the timer would be only on the player who performed the action, and not any Alts...

86400 = seconds in a day.
Serv.time /10 gives you a time in seconds.

By placing the code I gave you under a @login trigger it will check if the difference between current serv.time and the time-stamped tag is > 86400 (24 hrs) and if so remove it.

In your voting script, have it check for that tag and run the same piece of code to see if the difference is over 24 hours, if it is, remove the tag and allow voting to occur, (and add the tag again with the new serv.time) if not prevent it. You could also have it output the remaining time so player know how ling until they can vote. Just remember it's in seconds so you'll have to do a little math with it (/60) to get a number players can more easily understand.


Thanks!
I will try it!
and the /60 to see the exact number yes Tongue I have take it that from another script ^_^

Thanks again Smile


I had errors. I had trying this:

Code:
[this in the dialog] serv.account.tag0.blah=<serv.time>

[FUNCTION vote]
IF (!<SRC.account.tag0.blah>)
    IF <eval <src.findid.account.tag0.blah.timer>/3600>>
    SRC.SYSMESSAGE @,3,1 You have had voted. You left <eval <src.findid.i_mem_vote.timer>/3600> hours to try again.
    ENDIF

and this in the player event:
IF (<eval <SERV.TIME>-<serv.account.tag0.blah>/10> > 86400)
    serv.account.tag.blah=
endif

[Image: 2hy9q0y.png]
(This post was last modified: 10-25-2012 02:12 AM by Lazarus.)
10-25-2012 02:03 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
Vote system tag account? - Lazarus - 10-24-2012, 12:48 PM
RE: Vote system tag account? - Mordaunt - 10-24-2012, 01:12 PM
RE: Vote system tag account? - Lazarus - 10-24-2012, 01:30 PM
RE: Vote system tag account? - Shamino - 10-24-2012, 05:18 PM
RE: Vote system tag account? - Mordaunt - 10-24-2012, 09:56 PM
RE: Vote system tag account? - Lazarus - 10-25-2012 02:03 AM
RE: Vote system tag account? - Mordaunt - 10-25-2012, 03:13 AM
RE: Vote system tag account? - Lazarus - 10-25-2012, 11:07 AM
RE: Vote system tag account? - RanXerox - 10-25-2012, 11:52 AM
RE: Vote system tag account? - Lazarus - 10-25-2012, 01:06 PM
RE: Vote system tag account? - RanXerox - 10-25-2012, 02:33 PM
RE: Vote system tag account? - Lazarus - 10-25-2012, 02:49 PM
RE: Vote system tag account? - Hayur - 04-14-2015, 03:53 PM
RE: Vote system tag account? - XuN - 04-14-2015, 04:44 PM
RE: Vote system tag account? - Hayur - 04-14-2015, 09:51 PM
RE: Vote system tag account? - XuN - 04-14-2015, 11:23 PM
RE: Vote system tag account? - Hayur - 04-14-2015, 11:55 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)