Jump to content

Deleted User

Members
  • Posts

    235
  • Joined

  • Days Won

    6

Posts posted by Deleted User

  1. Hello, first of all if you respond to my topic, i appreciate it and thank you.

    So now, i would like to ask for a script request on how can i make rentitem with a specific class.

     

    Example:

    This script must be a function because i'll be using a custom box for this called: (Trial Rent Item)
    So, now a player must be max level and also a transcended class or else the box won't be open.

     

    example of the script:

     

    function    script    F_RentItemClass    {

    if (baselevel && transcded class)
        mes "You must be Max Level and Transcded Class";
    else if mes "would you like to open now the box you will receieve a rent item to your specific job class?"
    if (menu)

    open the box

    for ( .@i = 0; .@i < getarraysize(.classIds); .@i++ ) { bla bla bla
    then proceed --->
    mes "You have received bla blabla"
    rentitem OnInit:,( 1 * 604800 ); --> if a player is sniper(id: 4012) so the given item will be 1735.

     

    PS: Sorry if my script sketch is weird hope you understand.

    For the OnInit: part this is what would i like (a specific class and a specific item):

     

        setarray .classIds, 4008, 4014, 4015, 4022, 4013, 4009, 4016, 4010, 4017, 4011, 4018, 4012, 4019, 4020, 4021;
        setarray .itemIds,  1423, 1423, 1177, 1177, 1272, 1566, 1817, 1628, 1627, 1378,13029, 1735, 1536, 1921, 1975;


    If you have any questions please feel free to ask me.

     

    Thank you so much and i appreciate it

  2. original by Napster ( https://rathena.org/board/topic/97889- )

    equivalent ExtendedVendingSystem_1.9.4_r15149.diff

     

    very recommend use clean server for this patch.

    back up your server first before patch and use as your own risk.

     

    Step 1: download patch.diff and place to rAthena working directory.

    Step 2: in Git Bash, browse to rathena directory (cd command) and execute this command.

    patch -p1 -l < patch.diff
    

    or

    git apply patch.diff
    

    result should be.

     

    eP6TnLR.jpg

     

    Step 3: migrate database by command.

    mysql --user=dbuser -p dbname < sql-files/upgrade_extended_vending_item.sql
    

    Step 4: re-compile.

    Step 5: start the server.

     

    test result with rAthena server commit "5fcb3bff058cf2268328aee8b74874acb896216b" (10 August 2016)

     

    jxkJVCE.jpg

     

    TcC9fdC.jpg

     

    Edit: Updated 10 August 2016

    Thank you for this updating this patch.

    We appreciate it.

  3.  

     

     

    Hello my friend, thanks for the respond and i know that. however i'm looking for the "EXACT" date of that client. when you hexed it with NEMO it appears in the date with "2015-11-02" so i'm looking for the exact date.

     

    Because it's compiled on 2nd of November 2015 but released on 4th. That one is EXACTLY the one you want. There's no 2015-11-02.

    xfcjKzl.png

     

     

    Do you know where can i  find this link?

     

    Thank you!

  4. //Script by Normynator v1.1
    //Modified by Panda 
    prontera,146,163,4	script	Event Representative	113,{
    
    function EndEvent;
    
        if(getgmlevel() >= 99){
            .@s = select("Start:Stop:Set Reward:Cancel");
            if(.@s == 1){
    			mes "[ ^83cfe9Representative^000000 ]";
    				if(.config_done < 1){ mes "Please set your rewards and number of winners first."; close; }
    			mes "Event has been started.";
    			close2;
    			set $giveaway, 0;
    			set .start, 1;
    			announce "[Event Representative]: [GM] "+strcharinfo(0)+" has started a Give Away Event!",0;
    			sleep2 10000;
    			announce "[Event Representative]: Number of Winners - "+.winner+" - ",0;
    			end;
            }
    		else if(.@s == 2){
    			if(.start < 1){ mes "No event to stop."; close; }
    			mes "[ ^83cfe9Representative^000000 ]";
                mes "You have cancelled the event.";
                set $giveaway, 1000;
                EndEvent;
                close;
            }
    		else if(.@s == 3){
                mes "[ ^83cfe9Representative^000000 ]";
    			mes "What reward do you want to give to the players?";
    			input .Rew_Item;
    			set .item,.Rew_Item;
    			if ( getiteminfo( .item, 0 ) == -1 ) {
    					next;
    					mes "[ ^83cfe9Representative^000000 ]";
    					mes "Invalid Item ID";
    					close;
    			}
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "Do you want to reward them "+getitemname(.Rew_Item)+"?";
    			menu "Yes",-;
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "How many items will the player get?";
    			input .Rew_Amt;
    			set .amount,.Rew_Amt;
    				if(.amount < 1){
    					next;
    					mes "[ ^83cfe9Representative^000000 ]";
    					mes "Quantity can not be lesser than 1.";
    					close;
    				}
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "Are you sure with "+.Rew_Amt+" items?";
    			menu "Yes",-;
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "Quantity has been set.";
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "How many players do you want to win?";
    			input .Rew_Win;
    			set .winner,.Rew_Win;
    				if(.winner < 1){
    					next;
    					mes "[ ^83cfe9Representative^000000 ]";
    					mes "Winners can not be lesser than 1.";
    					close;
    				}
    			next;
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes .winner+" winners will be able to win.";
    			set .config_done,1;
    			close;
            }else{
    			end;
    		}
    		
        }
    	if(.start < 1){ mes "[Representative]"; mes "No events are running."; close; }
    	if (#AlreadyGot){
    			mes "[ ^83cfe9Representative^000000 ]";
    			mes "I have ^FF0000"+.@left + "^000000 items left.";
                mes "You already got your item.";
                close;
            }
        if($giveaway >= .winner){
    	mes "[ ^83cfe9Representative^000000 ]";
            mes "I'm sorry, all items have been claimed.";
            close;
        }
    	else{
    		mes "[ ^83cfe9Representative^000000 ]";
    		set .@left, .winner - $giveaway;
            mes "Hi";
            mes "I have ^FF0000"+.@left + "^000000 items left.";
    		next;
            set #AlreadyGot, 1;
    		mes "[ ^83cfe9Representative^000000 ]";
            mes "Congratulations for making it.";
    
    		getitem .Rew_Item, .Rew_Amt;
    		announce strcharinfo(0)+" redeemed one of the "+.@left+" Event Items!",0;
    
            set $giveaway, $giveaway + 1;
            if($giveaway == .winner){
                EndEvent;
            }
            close;
        }
    OnInit:
    	waitingroom "Event Representative",0;
    	set .start, 0;
    	end;
    
    EndEvent:
            announce "All Event Items have been redeemed.",0;
            query_sql "DELETE FROM `main`.`acc_reg_num` WHERE `key`='#AlreadyGot'"; //update this line
    	set .start,0;
        end;
    }
    

    Just change the query line if you have a different database structure. Let me know if something doesn't work.

     

     

     

    This script is quite very useful, any chances to make it detect IP?

    And also can you add also in save log?

    e.g account id,login id,character,level,job,claim item,quantity,last ip

    something like that :D

  5. Sometimes setting up max level on /db sides makes me confuse, why ALL rAthena Dev, changes this? although the old method works perfectly? confuse lol.

     

    PlayTester: How do you managed to solved this mathematics lol? >,> i'm planning to do example for Base: 255 and Job: 99

    How do you calculate it? with a Perfect Pre Formula?

×
×
  • Create New...