Jump to content
  • 0

NPC Dialogue Box Counting Upwards


Question

Posted

Does anyone know how I can make this NPC chat box show the numbers counting upward instead of down?

//Script by Normynator v1.1
prontera,140,180,5    script    Item    80,{
function EndEvent;
    if(getgmlevel() >= 99){
        .@s = select("Start:Stop:Chancel");
        if(.@s == 1){
            mes "Start";
            set $giveaway, 0;
            announce "Give away has just started!!", 0;
            close;
        }else if(.@s == 2){
            mes "Stop";
            set $giveaway, 50;
            EndEvent;
            close;
        }else{
            close;
        }
    }
    if($giveaway == 50){
        mes "All items are gone!";
        close;
    }else{
        set .@left, 50 - $giveaway;
        mes "Hi";
        mes .@left + " Items left.";
        //mes $giveaway;
        if (#AlreadyGot){
            mes "You already got your item.";
            close;
        }
        set #AlreadyGot, 1;
        mes "An Apple for you";
        getitem 512, 1;
        set $giveaway, $giveaway + 1;
        if($giveaway == 50){
            EndEvent;
        }
        close;
    }
EndEvent:
        announce "Give away has just ended!!", 0;
        query_sql "DELETE FROM `rathena`.`global_reg_value` WHERE `str`='#AlreadyGot'";
    end;
}

 

2 answers to this question

Recommended Posts

  • 0
Posted (edited)
set .@left, 50 - $giveaway;
mes .@left + " Items left.";

change to

mes "Give Away: "+ $giveaway;

 

Edited by Emistry
  • Upvote 1

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.   Paste as plain text instead

  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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...