Jump to content

Utility : New Player Generate gift cards


ioid44

Recommended Posts


  • Group:  Members
  • Topic Count:  1
  • Topics Per Day:  0.00
  • Content Count:  1
  • Reputation:   0
  • Joined:  04/15/22
  • Last Seen:  

prontera,155,155,3    script    New Player Code    JP_AIRI,{
    disable_items;
    mes "[ New Player Code ]";
    mes " Hahaha... I know you are strong enough.";
    mes "Which type of gift card do you want to redeem?";
    next;
        switch(select((getgroupid() == 99)?"Generate gift cards":"","Redeem gift card")){
            case 1:
                    mes "Generate that type of gift card.";
                    next;
                    switch(select("Generate gift cards one","Generate gift cards two")){
                        case 1:
                            @cardtype = 1;
                            break;
                        case 2:
                            @cardtype = 2;
                            break;
                    }
                    input .@count,0,200;
                    if(.@count==0)end;
                    for    (.@i = 0; .@i < .@count; .@i++){
                        .@card$ = "PlumRo_"+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))]+$@base62$[rand(getarraysize($@base62$))];
                        query_sql("SELECT EXISTS(SELECT * FROM newplayercard WHERE `cardid` = '"+.@card$+"');",.@p);
                        if(.@p==0)query_sql("INSERT INTO newplayercard VALUES ('"+.@card$+"',"+@cardtype+");");
                    }
                    end;
            case 2:
                    mes "[ New Player Code ]";
                    mes "Please enter or paste your gift card code ID";
                    next;
                    input .@count$,0,200;
                    query_sql("SELECT EXISTS(SELECT * FROM newplayercard WHERE `cardid` = '"+.@count$+"');",.@p);
                    if(.@p==1){
                        query_sql "DELETE FROM `newplayercard` WHERE `cardid` = '"+.@count$+"';";
                        getitem 30150,1;
                        end;
                    }
                    mes "[New Player Code]";
                    mes "Sorry, your serial number is invalid. Please check the serial number or contact GMQQ494887.";
                    end;
        }
    end;
OnInit:
    setarray $@base62$,"0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z";
    end;
}

新手卡+自动生成.rar

Edited by Mael
Use a codebox
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  2
  • Topics Per Day:  0.00
  • Content Count:  102
  • Reputation:   6
  • Joined:  03/02/18
  • Last Seen:  

Its Works! Thanks ?

Link to comment
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
Reply to this topic...

×   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.

×
×
  • Create New...