Jump to content

dantoki

Members
  • Posts

    238
  • Joined

  • Last visited

  • Days Won

    9

Posts posted by dantoki

  1. On 11/20/2021 at 3:42 AM, AinsLord said:

    it automatically sets cash/zeny for vending

    for using only zeny and cash

    put 0 to the item IDs in item_vending.txt <--- this file is not existing you just need to create it on db/item_vending.txt

    +// Specific items for Vending System
    +// Format: ItemID
    +// Max items is equal MAX_INVENTORY ( 100 by default )
    +
    +// TCG Card
    +7227
    +// Mithril Coin
    +674
    +// Silver Coin
    +675
    +// Bronze Coin
    +673

    but for custom currency or points

    it will make some additional scripts/modification on src

     

    how to set up the item_vending.yaml

    i can see the item currency but i cant buy it,

  2. Just now, Slammer said:

    can u give a full script?

    L_monthly_reset_statue:
    OnTimer1200000:
    //OnClock0000: // refresh every 1 second for debug, change this to 30 seconds or 1 minute
    	for (.@i = 0; .@i < 5; ++.@i) {
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADTOP, 0;
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADMIDDLE, 0;
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADBOTTOM, 0;
    	}
    	.@query$  = "SELECT `char`.`char_id`, `char`.`guild_id`, `char`.`name`, `char`.`class`, `char`.`sex`, `char`.`hair`, `char`.`hair_color`, `char`.`clothes_color`, `char`.`body`, `char`.`head_top`, `char`.`head_mid`, `char`.`head_bottom`, `pvpladder_epic`.`kills`, `pvpladder_epic`.`deaths` ";
    	.@query$ += "FROM `char` RIGHT JOIN `pvpladder_epic` ON `char`.`char_id` = `pvpladder_epic`.`char_id` ";
    	.@query$ += "ORDER BY `kills` DESC LIMIT 5";
    	.@nb = query_sql(.@query$, .@cid, .@guild_id, .@name$, .@class, .@sex$, .@hair, .@hair_color, .@clothes_color, .@body, .@head_top, .@head_mid, .@head_bottom, .@kills, .@deaths);
    	for (.@i = 0; .@i < .@nb; ++.@i) {
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_CLASS, .@class[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_SEX, (.@sex$[.@i] == "F")?SEX_FEMALE:SEX_MALE;
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HAIRSTYLE, .@hair[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HAIRCOLOR, .@hair_color[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_CLOTHCOLOR, .@clothes_color[.@i];
    		//setunitdata .pvp_ladder_statues[.@i +1], UNPC_BODY2, .@body[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADTOP, .@head_top[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADMIDDLE, .@head_mid[.@i];
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_HEADBOTTOM, .@head_bottom[.@i];
    		setnpcdisplay "pvp_ladder_statues#"+(.@i +1), .@name$[.@i];
    		.statue_name$[.@i +1] = .@name$[.@i];
    		.statue_guild$[.@i +1] = getguildname(.@guild_id[.@i]);
    		.statue_kills[.@i +1] = .@kills[.@i];
    		.statue_deaths[.@i +1] = .@deaths[.@i];
    	}
    	for (.@i = .@nb; .@i < 5; ++.@i)
    		setunitdata .pvp_ladder_statues[.@i +1], UNPC_CLASS, HIDDEN_WARP_NPC; // HIDDEN_NPC = 111, HIDDEN_WARP_NPC = 139
    	if (.start)
    		initnpctimer;
    	else
    		stopnpctimer;
    	end;
    OnGMCommandStart:
    OnMinute00: // configure time
    //OnMon2000:
    	.start = true;
    	pvpon .map$;
    	deletearray .guild_ownage;
    	initnpctimer;
    	end;
    OnMinute59:
    //OnMon2045:
    	.start = true;
    	pvpon .map$;
    	deletearray .guild_ownage;
    	end;
    L_read:
    	mes "["+ strnpcinfo(1) +"]";
    	mes "Hello! "+strcharinfo(0)+".";
    	mes "Join PVP! To Earn Rewards.";
    	mes "Top 15 of the PVP Rankings will sure get an surprise reward.";
    	next;
    	switch(select(
    		"Enter PvP Room",
    		"Show Top 15 Rank",
    		"My Ranking")) {
    	mes "["+ strnpcinfo(1) +"]";
    	case 1:
    		if (!.start) {
    		if( BaseLevel < 999 || Class == Job_Novice ){
        		mes "Novice or Below level 999 cant enter.";
       		close;
    		}
    			warp .map$, 0, 0; break;
    			close;
    		}
    		if( BaseLevel < 999 || Class == Job_Novice ){
        		mes "Novice or Below level 999 cant enter.";
       		close;
    		}
    		switch(rand(2)) {
    		announce strcharinfo(0) +" entered PVP Room",bc_all,0xe57c00;
    		default: warp .map$, 0, 0; break;
    		case 1: warp .map$, 0, 0; break;
    		}
    		if (@dota_sql_kills == 0 && @dota_sql_deaths == 0)
    			query_sql "SELECT `kills`, `deaths` FROM `pvpladder_epic` WHERE `char_id` = "+ getcharid(0), @dota_sql_kills, @dota_sql_deaths;
    		end;
    	case 2:
    		.@nb = query_sql("SELECT `name`, `kills`, `deaths` FROM `pvpladder_epic` ORDER BY `kills` DESC LIMIT "+ .show_ranking, .@name$, .@kills, .@deaths);
    		if (!.@nb) {
    			mes "The ladder currently is empty.";
    			close;
    		}
    		mes "^996600RANK: ^006699NAME ^00AA00[Kills] ^FF0000<Deaths>^000000";
    		for (.@i = 0; .@i < .@nb; ++.@i) 
    			mes "^996600"+ (.@i+1) +": ^006699"+ .@name$[.@i] +" ^00AA00["+ .@kills[.@i] +"] ^FF0000<"+ .@deaths[.@i] +">^000000";
    		close;
    	case 3:
    		if (!query_sql("SELECT `kills`, `deaths`, 1+(SELECT COUNT(1) FROM `pvpladder_epic` t1 WHERE t1.`kills` > t2.`kills`) FROM `pvpladder_epic` t2 WHERE `char_id` = "+ getcharid(0), .@kills, .@deaths, .@rank)) {
    			mes "You haven't kill anybody in this month.";
    			close;
    		}
    		mes "Your kills -> "+ .@kills;
    		mes "Your deaths -> "+ .@deaths;
    		mes "Your current rank -> "+ F_GetNumSuffix(.@rank);
    		close;
    	}
    	end;
    OnPCKillEvent:
    	if (.gmnokill && getgmlevel() >= .gmnokill) end;
    	if (strcharinfo(3) != .map$) end;
    	.@killername$ = strcharinfo(0);
    	.@killeraid = getcharid(3);
    	.@killercid = getcharid(0);
    	.@killerguildid = getcharid(2);
    	attachrid killedrid;
    	.@victimname$ = strcharinfo(0);
    	.@victimaid = getcharid(3);
    	.@victimcid = getcharid(0);
    	.@victimguildid = getcharid(2);
    	if (@PlayersKilledStreak >= .holyshit)
    		.@streakname$ = "Beyond Godlike";
    	else if (@PlayersKilledStreak >= .godlike)
    		.@streakname$ = "Godlike";
    	else if (@PlayersKilledStreak >= .monsterkill)
    		.@streakname$ = "Monster Kill";
    	else if (@PlayersKilledStreak >= .wickedsick)
    		.@streakname$ = "Wicked Sick";
    	else if (@PlayersKilledStreak >= .unstoppable)
    		.@streakname$ = "Unstoppable";
    	else if (@PlayersKilledStreak >= .megakill)
    		.@streakname$ = "Mega-kill";
    	else if (@PlayersKilledStreak >= .dominating)
    		.@streakname$ = "Dominating";
    	else if (@PlayersKilledStreak >= .killingspree)
    		.@streakname$ = "Killing Spree";
    	if (@PlayersKilledStreak >= .killingspree && .@killeraid == .@victimaid)
    		announce sprintf("%s has ended %s own %s[%d] streak", .@killername$, (Sex)?"him":"her", .@streakname$, @PlayersKilledStreak), bc_all,0xe57c00;
    	else if (@PlayersKilledStreak >= .killingspree)
    		announce sprintf("%s has ended %s's %s[%d] streak", .@killername$, .@victimname$, .@streakname$, @PlayersKilledStreak), bc_all,0xe57c00;
    	else if (.@killeraid != .@victimaid)
    		announce sprintf("%s has pawned %s's head", .@killername$, .@victimname$), bc_all,0xe57c00;
    	@PlayersKilledStreak = 0;
    	++@dota_sql_deaths;
    	@dota_multikills = 0;
    	if (.@victimguildid)
    		.guild_ownage[.@victimguildid] = 0;
    	if (.@killeraid == .@victimaid) {
    		query_sql "REPLACE INTO `pvpladder_epic` VALUES ("+ .@victimcid +", '"+ escape_sql(.@victimname$) +"', "+ @dota_sql_kills +", "+ @dota_sql_deaths +")";
    		end;
    	}
    	.@victim_kills = @dota_sql_kills;
    	.@victim_deaths = @dota_sql_deaths;
    	attachrid killerrid;
    	++@PlayersKilledStreak;
    	++@dota_sql_kills;
    	if (@PlayersKilledStreak == .killingspree)
    		setarray .@streakname$, "killingspree.wav", "is on a KILLING SPREE", "!";
    	else if (@PlayersKilledStreak == .dominating)
    		setarray .@streakname$, "dominating.wav", "is DOMINATING", "!";
    	else if (@PlayersKilledStreak == .megakill)
    		setarray .@streakname$, "megakill.wav", "has a MEGA KILL", "!";
    	else if (@PlayersKilledStreak == .unstoppable)
    		setarray .@streakname$, "unstoppable.wav", "is UNSTOPPABLE", "!!";
    	else if (@PlayersKilledStreak == .wickedsick)
    		setarray .@streakname$, "wickedsick.wav", "is WICKED SICK", "!!";
    	else if (@PlayersKilledStreak == .monsterkill)
    		setarray .@streakname$, "monsterkill.wav", "has a MONSTER KILL", "!!";
    	else if (@PlayersKilledStreak == .godlike)
    		setarray .@streakname$, "godlike.wav", "is GODLIKE", "!!!";
    	else if (@PlayersKilledStreak >= .holyshit && ((@PlayersKilledStreak - .holyshit) % .continue == 0))
    		setarray .@streakname$,"holyshit.wav", "is BEYOND GODLIKE",". Someone KILL "+( (Sex)?"HIM":"HER" ) +"!!!!!!";
    	if (getstrlen(.@streakname$[1])) {
    		announce sprintf("%s %s[%d] %s", .@killername$, .@streakname$[1], @PlayersKilledStreak, .@streakname$[2]), bc_all,0xe57c00;
    		soundeffectall .@streakname$[0], 0, .map$;
    	}
    	++@dota_multikills;
    	deltimer strnpcinfo(0) +"::OnStreakReset";
    	addtimer 18000, strnpcinfo(0) +"::OnStreakReset";
    	query_sql sprintf("REPLACE INTO `pvpladder_epic` VALUES (%d, '%s', %d, %d), (%d, '%s', %d, %d)",
    		.@killercid, escape_sql(.@killername$), @dota_sql_kills, @dota_sql_deaths,
    		.@victimcid, escape_sql(.@victimname$), .@victim_kills, .@victim_deaths);
    	if (.@killerguildid && .@killerguildid != .@victimguildid)
    		++.guild_ownage[.@killerguildid];
    	.@dota_multikills = @dota_multikills;
    	sleep 1500;
    	if (.@killerguildid && .@killerguildid != .@victimguildid && .guild_ownage[.@killerguildid] >= .owned && ((.guild_ownage[.@killerguildid] - .owned) % .owncontinue == 0)) {
    		announce "The guild ["+ getguildname(.@killerguildid) +"] is OWNING["+ .guild_ownage[.@killerguildid] +"] !!!", bc_all;
    		soundeffectall "ownage.wav",0,.@map$;
    	}
    	sleep 1250;
    	if (!attachrid(.@killeraid)) end;
    	if (.@dota_multikills == 2) {
    		announce strcharinfo(0) +" just got a Double Kill !", bc_all,0xe57c00;
    		soundeffectall "doublekill.wav", 0, .map$;
    	}
    	else if (.@dota_multikills == 3) {
    		announce strcharinfo(0) +" just got a Triple Kill !!!", bc_all,0xe57c00;
    		soundeffectall "triplekill.wav", 0, .map$;
    	}
    	else if (.@dota_multikills == 4) {
    		announce strcharinfo(0) +" just got an Ultra Kill !!!", bc_all,0xe57c00;
    		soundeffectall "ultrakill.wav", 0, .map$;
    	}
    	else if (.@dota_multikills >= 5) {
    		announce strcharinfo(0) +" is on a Rampage !!!", bc_all,0xe57c00;
    		soundeffectall "rampage.wav", 0, .map$;
    	}
    	end;
    OnStreakReset:
    	@dota_multikills = 0;
    	end;
    OnClock0000:
    	if (gettime(DT_DAYOFMONTH) != 1) end;
    L_Monthly_Reward_Rank:
    	$pvpevent_last_given = atoi(gettime(7) +""+ gettime(6));
    	.@nb = query_sql("SELECT `char_id` FROM `pvpladder_epic` ORDER BY `kills` DESC LIMIT "+ .reward_monthly, .@cid);
    	if (!.@nb) end;
    	for (.@i = 0; .@i < .@nb; ++.@i) {
    		setarray .@mail_itemid, getd(".reward_monthly_for_rank_"+(.@i +1)+"[1]"), getd(".reward_monthly_for_rank_"+(.@i +1)+"[3]");
    		setarray .@mail_amount, getd(".reward_monthly_for_rank_"+(.@i +1)+"[0]"), getd(".reward_monthly_for_rank_"+(.@i +1)+"[2]");
    		mail .@cid[.@i],
    			"PvP Ladder Event",
    			"Monthly PvP Ladder Event Rewards",
    			"Congratulations for being "+ F_GetNumSuffix(.@i +1) +" Rank on PvP Ladder Event, this is your rewards.",
    			0,
    			.@mail_itemid,
    			.@mail_amount;
    	}
    	query_sql "TRUNCATE `pvpladder_epic`";
    	goto L_monthly_reset_statue;
    }
    function	script	pvp_ladder_statues	{
    	.@id = inarray(getvariableofnpc(.pvp_ladder_statues, "PvP Ladder Event"), getnpcid(0));
    	mes "^996600[TOP "+ .@id +"]";
    	mes "^006699Name : "+ getelementofarray(getvariableofnpc(.statue_name$, "PvP Ladder Event"), .@id);
    	.@guildname$ = getelementofarray(getvariableofnpc(.statue_guild$, "PvP Ladder Event"), .@id);
    	mes "^00AAAAGuild : "+((.@guildname$ == "null")? "^666666None": .@guildname$);
    	mes " ";
    	mes "^00AA00Kills : ["+ getelementofarray(getvariableofnpc(.statue_kills, "PvP Ladder Event"), .@id) +"]";
    	mes "^FF0000Deaths : <"+ getelementofarray(getvariableofnpc(.statue_deaths, "PvP Ladder Event"), .@id) +">";
    	return;
    }
    maintown,253,247,4	script	pvp_ladder_statues#1	HIDDEN_WARP_NPC,{ callfunc "pvp_ladder_statues"; end; OnInit: set getvariableofnpc(.pvp_ladder_statues[1], "PvP Ladder Event"), getnpcid(0); end; }
    maintown,256,247,4	script	pvp_ladder_statues#2	HIDDEN_WARP_NPC,{ callfunc "pvp_ladder_statues"; end; OnInit: set getvariableofnpc(.pvp_ladder_statues[2], "PvP Ladder Event"), getnpcid(0); end; }
    maintown,259,247,4	script	pvp_ladder_statues#3	HIDDEN_WARP_NPC,{ callfunc "pvp_ladder_statues"; end; OnInit: set getvariableofnpc(.pvp_ladder_statues[3], "PvP Ladder Event"), getnpcid(0); end; }
    maintown,262,247,4	script	pvp_ladder_statues#4	HIDDEN_WARP_NPC,{ callfunc "pvp_ladder_statues"; end; OnInit: set getvariableofnpc(.pvp_ladder_statues[4], "PvP Ladder Event"), getnpcid(0); end; }
    maintown,265,247,4	script	pvp_ladder_statues#5	HIDDEN_WARP_NPC,{ callfunc "pvp_ladder_statues"; end; OnInit: set getvariableofnpc(.pvp_ladder_statues[5], "PvP Ladder Event"), getnpcid(0); end; }

    HERE

  3. 2 hours ago, April Summers said:

    Hello, so I ended up managing to run rAthena (I think ? I have 3 terminals running things then stopping on not error looking messages ?)

    On the other side I downloaded files and tried to setup a client, downloading kro files and ended up with a "2020-04-01bRagexe_patched.exe" at the root of my game files.

    Now I'm starting the client, it does go to a login menu, but how is it supposed to find my server ? I tried to enter my username and pwd and it told me after a bit something like "unable to find the server". I probably missed some middle step here...

    Any advice on where to start looking ? Thanks !

    Go to your grf clientinfo.xml
              <address>127.0.0.1</address>
              <port>6900</port>

    put correctly your server ip and port
     

  4. On 11/13/2021 at 12:57 AM, sader1992 said:

    this is a reference for you

    	if(getd("#wqeqwe_" + gettime(DT_YYYYMMDD)) < .day_limit){
    		.@left = .day_limit - getd("#wqeqwe_" + gettime(DT_YYYYMMDD));
    		mes "Input how many";
    		input .@count,0,.@left;
    		delitem .@coin,.@count;
    		getitem .@new_coin,.@count;
    		setd("#wqeqwe_" + gettime(DT_YYYYMMDD),getd("#wqeqwe_" + gettime(DT_YYYYMMDD)) + .@count);
    		end;
    	}
    	mes "You cannot exchange anymore today!";
    	end;

     

    i done it but,

    maintown,193,173,5	script	Coin Trader	117,{
    function int__;
    
    do{
    	callsub exchange_rate;
    	.@menu = select( "Zeny to Coin","Coin to Zeny","Close" );
    	switch( .@menu ){
    		Case 1:
    			mes "Convert Zeny to which Coins ?";
    			.@coin = select( implode( .coin_name$,":" ) ) - 1;
    			if( Zeny <  .value[.@coin] ){
    				mes "^FF0000[ERROR]^000000 You didnt have enough zeny.";
    			}else{
    				.@maximum = Zeny / .value[.@coin];
    				mes "You can get maximum of ^FF0000"+int__( .@maximum )+" x "+getitemname( .coin_id[.@coin] )+"^000000";
    				
    				if(getd("#wqeqwe1_" + gettime(DT_YYYYMMDD)) < .day_limit){
    				.@left = .day_limit - getd("#wqeqwe1_" + gettime(DT_YYYYMMDD));
    				input .@amount,0,.@maximum;
    				if( .@amount )
    					if( checkweight( .coin_id[.@coin],.@amount ) ){
    						.@total = ( .@amount * .value[.@coin] );
    						Zeny -= .@total;
    						getitem .coin_id[.@coin],.@amount;
    						setd("#wqeqwe1_" + gettime(DT_YYYYMMDD),getd("#wqeqwe1_" + gettime(DT_YYYYMMDD)) + .@amount);
    						message strcharinfo(0),"Exchanged "+int__( .@total )+" Zeny to "+int__( .@amount )+" "+getitemname( .coin_id[.@coin] )+"^000000";
    					}
    				}
    						else{
    						mes "^FF0000[ERROR]^000000 You cant take this much.";
    					}
    			}
    			break;
    		Case 2:
    			mes "Convert which Coins to Zeny ?";
    			.@coin = select( implode( .coin_name$,":" ) ) - 1;
    			if( !countitem( .coin_id[.@coin] ) ){
    				mes "^FF0000[ERROR]^000000 You didnt have any "+getitemname( .coin_id[.@coin] )+".";
    			}else if( ( .max_zeny - Zeny ) < .value[.@coin] ){
    				mes "^FF0000[ERROR]^000000 You cant exchange this Coin as it will exceed the Zeny limit.";
    			}else{
    				.@maximum = (( .max_zeny - Zeny ) / .value[.@coin] );
    				if( .@maximum > countitem( .coin_id[.@coin] ) ) .@maximum = countitem( .coin_id[.@coin] );
    				mes "You can exchange maximum of ^FF0000"+int__( .@maximum )+" x "+getitemname( .coin_id[.@coin] )+"^000000 to zeny";
    				input .@amount,0,.@maximum;
    				if( .@amount ){
    					.@total = ( .@amount * .value[.@coin] );
    					Zeny += .@total;
    					delitem .coin_id[.@coin],.@amount;
    					message strcharinfo(0),"Exchanged "+int__( .@amount )+" "+getitemname( .coin_id[.@coin] )+" to "+int__( .@total )+" Zeny^000000";
    				}
    			}
    			break;
    		default: break;
    	}
    	next;
    }while( .@menu != 3 );
    mes "Thank you.";
    close;
    
    exchange_rate:
    	mes "Exchange Rate :";
    	for( .@i = 0; .@i < .coin_size; .@i++ )
    		mes "^777777 > "+.coin_name$[.@i]+" - "+int__( .value[.@i] )+" z^000000";
    	return;
    	
    OnInit:
    // server max zeny
    .max_zeny = 1000000000;
    .day_limit = 50;
    // coin list + name + value
    setarray .coin_name$,"Platinum Coin";
    setarray .coin_id,677;
    setarray .value,10000000;
    
    .coin_size = getarraysize( .coin_name$ );
    end;
    
    
    // credits to annieruru
    function	int__	{
    	set .@num, atoi(""+getarg(0));
    	if ( .@num == 0 || .@num >= 2147483647 ) return getarg(0);
    	set .@l, getstrlen(""+.@num);
    	for ( set .@i,0; .@i < .@l; set .@i, .@i + 1 ) {
    		set .@num$, .@num % pow(10,.@i+1) / pow(10,.@i) + .@num$;
    			if ( (.@i+1) % 3 == 0 && .@i+1 != .@l ) set .@num$, ","+ .@num$;
    	}
    	return .@num$;
    }
    
    }

    yeah it stops when i already exchange more than 50, the problem is if i change 1st time of the day by 49 i records 49 and again if i change again 50 total of 99 it still accepts it.

  5. 14 minutes ago, Start_ said:

    If your item had 'itemskill' that will consume otherwise it will infinite.

    can you give me example?

      - Id: 504
        AegisName: White_Potion
        Name: White Potion
        Type: Healing
        Buy: 1200
        Weight: 150
        Script: |
          percentheal 20,0;

     

  6. please help me make this up to level 999?

    # - Level: 240
        # Points: 6405
      # - Level: 241
        # Points: 6456
      # - Level: 242
        # Points: 6507
      # - Level: 243
        # Points: 6558
      # - Level: 244
        # Points: 6609
      # - Level: 245
        # Points: 6660
      # - Level: 246
        # Points: 6712
      # - Level: 247
        # Points: 6764
      # - Level: 248
        # Points: 6816
      # - Level: 249
        # Points: 6868
      # - Level: 250
        # Points: 6920
      # - Level: 251
        # Points: 6973
      # - Level: 252
        # Points: 7026
      # - Level: 253
        # Points: 7079
      # - Level: 254
        # Points: 7132
      # - Level: 255
        # Points: 7185

     

  7. prontera,155,181,5 script Sample 718,{
    
    setarray .CoinID,
      677;
    setarray .Zeny,
      10000000;
    
    while( 1 ){
    mes "What service you want ?";
    next;
    switch( select("Zeny to Coin:Coin to Zeny") ){
    Case 1:
     mes "What Coin you want ?";
     set .@CoinMenu$,"";
     for( set .@i,0; .@i < getarraysize( .CoinID ); set .@i,.@i + 1 ){
      mes "^0000FF"+getitemname( .CoinID[.@i] )+" : ^FF0000"+.Zeny[.@i]+"^000000 Zeny";
      set .@CoinMenu$,.@CoinMenu$ + getitemname( .CoinID[.@i] )+":";
     }
     set .@Coin,select( .@CoinMenu$ ) - 1;
     next;
     mes "Selected : ^00FF00"+getitemname( .CoinID[.@Coin] )+"^000000";
     if( Zeny < .Zeny[.@Coin] ){
      mes "It seem like you didnt have Enough Zeny for this.";
      next;
      break;
     }
     mes "You can exchange to ^FF0000"+( Zeny / .Zeny[.@Coin] )+" ^0000FF"+getitemname( .CoinID[.@Coin] )+"^000000 .";
     mes "How many ^0000FF"+getitemname( .CoinID[.@Coin] )+"^000000 do you want ?";
     input @Amount,0,( Zeny / .Zeny[.@Coin] );
     if( !@Amount ) close;
     mes "You gained "+@Amount+" ^0000FF"+getitemname( .CoinID[.@Coin] )+"^000000.";
     set Zeny,Zeny - ( @Amount * .Zeny[.@Coin] );
     getitem .CoinID[.@Coin],@Amount;
     next;
     break;
    Case 2:
     mes "Which Coin ?";
     set .@CoinMenu$,"";
     for( set .@i,0; .@i < getarraysize( .CoinID ); set .@i,.@i + 1 ){
      mes "^0000FF"+getitemname( .CoinID[.@i] )+" : ^FF0000"+countitem( .CoinID[.@i] )+"^000000 Available";
      set .@CoinMenu$,.@CoinMenu$ + getitemname( .CoinID[.@i] )+":";
     }
     do{
      set .@Coin,select( .@CoinMenu$ ) - 1;
     }while( !countitem( .CoinID[.@Coin] ) );
     next;
     mes "Selected : ^00FF00"+getitemname( .CoinID[.@Coin] )+"^000000";
     mes "You can exchange ^0000FF"+countitem( .CoinID[.@Coin] )+" "+getitemname( .CoinID[.@Coin] )+"^000000 to ^FF0000"+( countitem( .CoinID[.@Coin] ) * .Zeny[.@Coin] )+"^000000 Zeny.";
     mes "How many ^0000FF"+getitemname( .CoinID[.@Coin] )+"^000000 do you want to change into Zeny ?";
     input @Amount,0,( ( 1000000000 - Zeny ) / .Zeny[.@Coin] );
     if( !@Amount ) close;
     mes "You gained "+( @Amount * .Zeny[.@Coin] )+" Zeny.";
     delitem .CoinID[.@Coin],@Amount;
     set Zeny,Zeny + ( @Amount * .Zeny[.@Coin] );
     next;
     break;
     }
    }
    }

    i want to add limit here maximum 50 coins per day that resets every 12:00am

    and every 1 coin needs 1 of #questpoints and 10,000,000 zeny.

    but for coins to zeny doesn't need the #questpoints.

  8. i get this part

    You can add more title here data\luafiles514\lua files\datainfo\titletable.lub

     

    i want is example:

    npc title giver:

    when you talk to the NPC will give you a reward same as the achievement.

    i want to add a title to a character when he finishes my custom quest.

×
×
  • Create New...