Перейти к содержанию

Overshot

Очередь
  • Постов

    1
  • Зарегистрирован

  • Посещение

Сообщения, опубликованные Overshot

  1. А ты что-то предпринимаешь для того, чтобы в один прекрасный момент написать что-нибудь?


    prontera,146,166,6 script Premium Account 634,{
    // Settings: -----------------------------
    set .@Cost, 350; // Cash Points required
    set .@Time, 4 * 7 * 24 * 60 * 60; // Time in Seconds = 4 weeks, 7 days per week, 24 hours per day, 60 minutes per day, 60 seconds per minute. = 1 month in this sample. in this sample.
    set .@Time$, "1 month";
    // ---------------------------------------

    mes "[Premium Account]";
    mes "I am the Premium Account seller.";
    if( #PremiumUser > gettimetick(2) )
    mes "Your Premium Account expires in ^FF0000" + callfunc("Time2Str",#PremiumUser) + "^000000.";
    mes "What can I do for you?";
    next;

    // isPremium() returns 1 if the current user account is premium and it have not expired.
    // It works together with #Premium_Tick, which is a account Var set with a Unix Time value, representing when the premium account expires.
    // isPremium() is the same as #Premium_Tick > gettimetick(2)

    switch( select("Pay for Premium Time:About Premium Account") )
    {
    case 1:
    mes "[Premium Account]";
    if( #PremiumUser > gettimetick(2) )
    mes "Do you really want to extend your Premium Time?";
    else
    mes "You do really want to convert your account to premium?";

    mes "Premium Time is ^FF0000" + .@Time$ + "^000000";
    mes "Value is ^FF0000" + .@Cost + "^000000 Cash Points.";
    next;
    if( select("Yes:No") == 2 )
    {
    mes "[Premium Account]";
    mes "Come back if you change your mind.";
    close;
    }

    if( #CASHPOINTS < .@Cost )
    {
    mes "[Premium Account]";
    mes "You don't have enough Cash Points.";
    close;
    }

    if( #PremiumUser > gettimetick(2) )
    set #PremiumUser, #PremiumUser + .@Time; // Time Extension
    else
    set #PremiumUser, gettimetick(2) + .@Time; // New premium Account
    query_sql "UPDATE `login` SET level = '1' WHERE account_id = "+getcharid(3)+"";
    set #CASHPOINTS, #CASHPOINTS - .@Cost;
    mes "[Premium Account]";
    mes "Congratulations!!..";
    mes "Remember your Premium Account expires in ^FF0000" + callfunc("Time2Str",#PremiumUser) + "^000000.";
    next;
    mes "To change the status to take effect, please reenter the game.";
    close;
    case 2:

    // Edit this messages to explain your Users about the premium account in your server.
    // ----------------------------------------------------------------------------------

    mes "[Premium Account]";
    mes "With Premium Account you can:";
    mes "Use the commands: @mobsearch,";
    mes "@cast,@exp,@petrename,@where,";
    mes "@changeleader, @packetfilter,";
    mes "@autorefresh and other...";
    mes " ";
    close;
    }


    OnPCLoginEvent:
    if( #PremiumUser > gettimetick(2)) {
    // sc_start SC_ITEMBOOST,( #PremiumUser - gettimetick(2) ),50;
    // sc_start SC_EXPBOOST,( #PremiumUser - gettimetick(2) ),50;
    dispbottom "Remember your Premium Account expires in " + callfunc("Time2Str",#PremiumUser) + "";
    }
    if( #PremiumUser <= gettimetick(2) ) {
    dispbottom "Time of Premium Account was ended or you don't pay for this.";
    query_sql "UPDATE `login` SET level = '0' WHERE account_id = "+getcharid(3)+"";
    }
    end;
    }

    Добрый день!

    Во-первых спасибо! Мне очень понравился ваш скрипт.

    Немогли бы вы помочь пожалуиста переделать его с кэша на ТЦГ? ID7227. Я учусь скриптить но этот скрипт слишком сложный для меня пока что.

    Благодарю!

×
×
  • Создать...
Яндекс.Метрика