Jump to content
  • 0
greenieken

Modified Hourly Points

Question

May I request for a modification.

Instead of every hour, make it every 10 minutes.

Instead of points, change to item.

Stop when vending and pub, but allows AFK.

Share this post


Link to post
Share on other sites

9 answers to this question

Recommended Posts

  • 0
On 6/28/2017 at 10:34 AM, greenieken said:

May I request for a modification.

Instead of every hour, make it every 10 minutes.

Instead of points, change to item.

Stop when vending and pub, but allows AFK.

Hi! Do you still need it?

Share this post


Link to post
Share on other sites
  • 0

I saw this script that annie used coz i've heard that the strcharinfo(0)+ may cause lag. I haven't tried this yet in my server, can you check if this is compatible with the latest herc? thanks! @Happy

 

Spoiler

-    script    ksdfskjfhs    -1,{
OnPCLoginEvent:
    dispbottom "Your timer starts now. You will receive 10 minute tickets after being online for 10 minutes";
    while (1) {
        if ( checkvending() != 2 ) {
            .@hourpointtick++;
            if ( .@hourpointtick > .tick ) {
                dispbottom "You have received 10 minute tickets";
                getitem 7227, 10;
                .@hourpointtick = 0;
            }
        }
        sleep2 .sleeploop;
    }
    end; // doesn't read
OnInit:
    .sleeploop = 10000; // every 30 seconds
    .tick = 1; // loop 60 times of 30 seconds == 30 minutes
    end;
}

 

Share this post


Link to post
Share on other sites
  • 0

Instead of every hour, make it every 10 minutes.

Instead of points, change to item.

Stop when vending and pub, but allows AFK.

 

/*
Instead of every hour, make it every 10 minutes.

Instead of points, change to item.

Stop when vending and pub, but allows AFK.
*/

-    script    ksdfskjfhs    -1,{
OnPCLoginEvent:
    dispbottom "Your timer starts now. You will receive 10 minute tickets after being online for 10 minutes";
    while (1) {
        if ( checkvending() != 2 && !checkchatting() ) {
            .@hourpointtick++;
            if ( .@hourpointtick > .tick ) {
                dispbottom "You have received 10 minute tickets";
                getitem 7227, 10;
                .@hourpointtick = 0;
            }
        }
        sleep2 .sleeploop;
    }
    end; // doesn't read
OnInit:
    .sleeploop = 30000; // every 30 seconds
    .tick = 20; // loop 60 times of 30 seconds == 30 minutes
    end;
}

There you go, I'll leave the testing to you though just post here again if there are errors :)

Might be better to use timers, i think there is already an hourly point reward somewhere with timers. Just try to search around.

Edited by Happy

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.