Jump to content

hadiesyafiq

Members
  • Content Count

    156
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by hadiesyafiq


  1. On 10/22/2020 at 6:44 PM, AnnieRuru said:

    - script kjhfkshdf FAKE_NPC,{ OnNPCKillEvent: if (killedrid == PORING && strcharinfo(PC_MAP) == "prt_fild08") { if (++.poringkill == 100) { monster "prt_fild08", 0,0, "--ja--", MASTERING, 1, strnpcinfo(NPC_NAME_UNIQUE)+"::OnMobKill"; // mapannounce "prt_fild08", "Mastering has been spawn", bc_map; } } end; OnMobKill: // mapannounce "prt_fild08", "Mastering has been killed", bc_map; initnpctimer; end; //OnTimer5000: OnTimer86400000: .poringkill = 0; end; } prt_fild08,0,0,0,0 monster Poring 1002,1000,0,0

    
    -	script	kjhfkshdf	FAKE_NPC,{
    OnNPCKillEvent:
    	if (killedrid == PORING && strcharinfo(PC_MAP) == "prt_fild08") {
    		if (++.poringkill == 100) {
    			monster "prt_fild08", 0,0, "--ja--", MASTERING, 1, strnpcinfo(NPC_NAME_UNIQUE)+"::OnMobKill";
    //			mapannounce "prt_fild08", "Mastering has been spawn", bc_map;
    		}
    	}
    	end;
    OnMobKill:
    //	mapannounce "prt_fild08", "Mastering has been killed", bc_map;
    	initnpctimer;
    	end;
    //OnTimer5000:
    OnTimer86400000:
    	.poringkill = 0;
    	end;
    }
    prt_fild08,0,0,0,0	monster	Poring	1002,1000,0,0

    tested with

    https://annieruru.blogspot.com/2019/01/mapmoblist-script-version.html

    Thank you very much @AnnieRuru


  2. Hi all how to create script that will spawn boss monster if total kill on that map reach 100 normal mob?

    example

    map prt_fild08

    kill poring 100 will auto spawn mastering...

    player 1 kill 50poring after that another player kill another 50 so total 100 and auto spawn mastering...after mastering dead...system will have cooldown time for 24hours..

    not kill 100 poring on whole map just prt_fild08


  3. 2 minutes ago, pos4da said:

    Hi hadiesyafiq,

     

    it looks firewall issues. Can you check if your iptables if running or allowed the port?

    Also you can check your PACKETVER in vi src/common/mmo.h

    mmo.h already i compile with 20151029 exe...how to check firewall because if i use my current hercules..if i use latest one is no problem...my current hercules is my current server...


  4. Hi all actually i just rent new vps...and i import all my files to new vps...all setup are done and no problem at all...but why i cannot connect with my client?

    i never change the client all i have setup new IP and server compile...here some photo of my problem...

    when i try to login cannot but after i close the client..they have message on putty like "closed connection from 'my client IP' " that's mean it connect but i don't know why it Failed connect to server?

    can someone help me to figure what is the problem?

    errorip.png

    errorip2.png


  5. Hi all can someone teach me how to make this script?

    script is like this

    when we login system auto force we to make number password...after that when login system will always ask the number...if wrong we will disconnected from server...when we not put the number we will freeze,mute and stun...we cannot use any skill or telewing here the picture

    12B2F07C-71A5-416E-843F-7C286A998FB8.jpeg


  6. long time i search for this idea...i want like this too...around 2004-2007 some official server botter set the acolyte as the warper...when we deal some price of zeny the acolyte will use memo skill to selected destination...bot will create chat room and say 150z pay_dun/100z orc_dun/120z hidden_temple..when we paid the amount they automatically open the portal...


  7. hi all 

    my server use serveral custom point for reward

    here some

    #TIMEPOINT

    #VOTEPOINT

    #SHAREPOINT

    #PVPPOINT

    #MISSONPOINT

    #EVENTPOINT

    #MVPPOINT

    #CASHPOINT

     

    How to make 1 NPC to check how many point we have on that character...

    example

    [POINT CHECKER]

    You have 

    10 timepoint

    5 votepoint

    3 sharepoint

    0 pvppoint.......

     

    thanks for helping


  8. Need help from master @AnnieRuru or someone can help to make adjustment for me..

    here the really good script 

    Quote
    
    function	script	F_MesItemInfo	{
    	.@item = getarg(0);
    	.@itemname$ = getitemname(.@item);
    	if (.@itemname$ != "null") {
    		.@itemslot = getitemslots(.@item);
    		if (.@itemslot)
    			.@itemname$ = sprintf("%s [%d]", .@itemname$, .@itemslot);
    	}
    	else
    		.@itemname$ = "Unknown Item";
    	if (PACKETVER >= 20150729)
    		return sprintf("<ITEM>%s<INFO>%d</INFO></ITEM>", .@itemname$, .@item);
    	else if (PACKETVER >= 20130130)
    		return sprintf("<ITEMLINK>%s<INFO>%d</INFO></ITEMLINK>", .@itemname$, .@item);
    	else
    		return .@itemname$;
    }
    
    function	script	timeleft__	{
    	.@left = getarg(0);
    	if ( .@left <= 0 )
    		return getarg(0);
    	.@day = .@left / 86400;
    	.@hour = .@left % 86400 / 3600;
    	.@min = .@left % 3600 / 60;
    	.@sec = .@left % 60;
    	if ( .@day )
    		return sprintf( _$( "%d day %d hour" ), .@day, .@hour );
    	else if ( .@hour )
    		return sprintf( _$( "%d hour %d min" ), .@hour, .@min );
    	else if ( .@min )
    		return sprintf( _$( "%d min %d sec" ), .@min, .@sec );
    	else
    		return sprintf( _$( "%d sec" ), .@sec );
    }
    
    //===== Hercules Script ======================================
    //= Daily Supply
    //===== By: ==================================================
    //= AnnieRuru
    //===== Current Version: =====================================
    //= 0.3
    //===== Compatible With: ===================================== 
    //= Hercules 2019-03-19
    //===== Description: ========================================= 
    //= get daily supply, but also with every 6 hours and every 12 hours
    //===== Topic ================================================
    //= http://herc.ws/board/topic/16634-daily-random-supplies/?do=findComment&comment=90931
    //===== Additional Comments: =================================
    //= 
    //============================================================
    
    /*
    prontera,153,185,5	script	Debug only	1_F_MARIA,{
    	deletearray #daily_supply;
    	end;
    }
    */
    
    prontera,155,185,5	script	Daily Supply	1_F_MARIA,{
    	mes .npcname$;
    	mes "Supply set no.1 can claim at every 12am, 6am, 12pm, 6pm";
    	mes "Supply set no.2 can claim at every 12am and 12pm";
    	mes "Supply set no.3 can claim at every 12am";
    	next;
    //	for ( .@i = 1; .@i <= 3; ++.@i )
    //		dispbottom #daily_supply[.@i] +" "+ gettimestr("%Y-%m/%d %H:%M:%S", 21, #daily_supply[.@i] );
    	for ( .@i = 0; .@i < 3; ++.@i ) {
    		if ( #daily_supply[.@i +1] < gettimetick(2) )
    			.@menu$[.@i] = sprintf( _$( "%sTake Supply Set#%d%s" ), F_MesColor(C_GREEN), .@i +1, F_MesColor(C_BLACK) );
    		else
    			.@menu$[.@i] = sprintf( _$( "%sWait %s%s" ), F_MesColor(C_RED), timeleft__( #daily_supply[.@i +1] - gettimetick(2) ), F_MesColor(C_BLACK) );
    	}
    	.@s = select ( implode(.@menu$, ":"), "Display Chances" );
    	mes .npcname$;
    	if ( .@s == 4 ) {
    		mes "The Chances are:-";
    		for ( .@i = 1; .@i <= 3; ++.@i ) {
    			mes " ";
    			mesf "Set %d :", .@i;
    			mesf "Randomly get any one type of these item, the amount between %d~%d", getd(".item"+ .@i +"[0]"), getd(".item"+ .@i +"[1]");
    			for ( .@j = 3; .@j < getd(".item"+ .@i +"size"); .@j += 2 )
    				mesf "%s : %s", F_MesItemInfo( getd(".item"+ .@i +"["+( .@j -1 )+"]") ), getd(".chance_display_item"+ .@i +"$["+ .@j +"]");
    		}
    		close;
    	}
    	if ( #daily_supply[.@s] < gettimetick(2) ) {
    		mes "Retrieving today's supply...";
    		.@r = rand(.totalchance[.@s]);
    		for ( .@i = 3; ( .@r -= getd(".item"+ .@s +"["+ .@i +"]") ) >= 0; .@i += 2 );
    		getitem getd(".item"+ .@s +"["+( .@i -1 )+"]"), rand( getd(".item"+ .@s +"[0]"), getd(".item"+ .@s +"[1]") );
    		switch ( .@s ) {
    		case 1: #daily_supply[1] = min( getcalendartime(0,0), getcalendartime(6,0), getcalendartime(12,0), getcalendartime(18,0) ); break;
    		case 2: #daily_supply[2] = min( getcalendartime(0,0), getcalendartime(12,0) ); break;
    		case 3: #daily_supply[3] = getcalendartime(0,0); break;
    		}
    	}
    	else {
    		mes "You have already taken this supply";
    		mesf "You have to wait %s", timeleft__( #daily_supply[.@s] - gettimetick(2) );
    	}
    	close;
    OnInit:
    	.npcname$ = "["+ strnpcinfo(NPC_NAME_VISIBLE) +"]";
    	setarray .item1,
    		1, 10, // amount : rand(1,10)
    	//	chance of getting the items Set#1
    	//	<Item ID>,<chance>
    		Red_Potion,    5,
    		Orange_Potion, 4,
    		Yellow_Potion, 3,
    		White_Potion,  2,
    		Blue_Potion,   1,
    		Green_Potion,  6;
    
    	setarray .item2,
    		5, 15, // amount : rand(5,15)
    	//	chance of getting the items Set#2
    	//	<Item ID>,<chance>
    		Red_Herb,    5,
    		Yellow_Herb, 4,
    		White_Herb,  3,
    		Blue_Herb,   2,
    		Green_Herb,  1;
    
    	setarray .item3,
    		10, 20, // amount : rand(10,20)
    	//	chance of getting the items Set#3
    	//	<Item ID>,<chance>
    		Apple,        5,
    		Banana,       4,
    		Grape,        3,
    		Carrot,       2,
    		Sweet_Potato, 1,
    		Meat,         99, 
    		Honey,        50,
    		Milk,         100;
    
    	for ( .@i = 1; .@i <= 3; ++.@i ) {
    		setd ".item"+ .@i +"size", getarraysize( getd(".item"+ .@i) );
    		for ( .@j = 3; .@j < getd(".item"+ .@i +"size"); .@j += 2 )
    			.totalchance[.@i] += getd(".item"+ .@i +"["+ .@j +"]");
    		for ( .@j = 3; .@j < getd(".item"+ .@i +"size"); .@j += 2 ) {
    			.@chance = getd(".item"+ .@i +"["+ .@j +"]") *10000 / .totalchance[.@i];
    			.@division = .@chance / 100;
    			.@remainder$ = .@chance % 100;
    			while ( getstrlen(.@remainder$) < 2 )
    				.@remainder$ = insertchar(.@remainder$, "0", 0);
    			setd ".chance_display_item"+ .@i +"$["+ .@j +"]", .@division +"."+ .@remainder$ +"%";
    		}
    	}
    	end;
    }

     

    this script have three set of daily supply..

    how to make it just 1 set..

    just set 3(for every 12am only)

    thanks in advance...

    because when i change it to 1 only 'mes' after that 'display chance' will be take supply set2..


  9. 7 hours ago, Kenpachi said:

    Hi.

     

    Quick'n'dirty:
     

      Hide contents

    prontera,150,170,0 script Coin Exchange 4_F_KAFRA5,{ mes(.npc_name$); mes("What do you want to exchange for 1 Gold Coin?"); .@selection1 = select(.menu_option1$, .menu_option2$, .menu_option3$); mesclear(); mes(.npc_name$); if (countitem(Silver_Coin) < 1) { mes("You need at least 1 Silver Coin."); close(); } switch (.@selection1) { case 1: if (Zeny < 500) { mes("You need at least 500z."); close(); } break; case 2: if (#CASHPOINTS < 10) { mes("You need at least 10 Cash Points."); close(); } break; case 3: if (countitem(Poring_Coin) < 1) { mes("You need at least 1 Poring Coin."); close(); } break; } mes("Are you sure?"); .@selection2 = select("Yes", "No"); mesclear(); mes(.npc_name$); if (.@selection2 == 2) { mes("Okay, see you."); close(); } delitem(Silver_Coin, 1); switch (.@selection1) { case 1: // 20% success chance. .@failed = (rand(10000) < 8000) ? 1 : 0; Zeny -= 500; break; case 2: // 50% success chance. .@failed = (rand(10000) < 5000) ? 1 : 0; #CASHPOINTS -= 10; break; case 3: // 90% success chance. .@failed = (rand(10000) < 1000) ? 1 : 0; delitem(Poring_Coin, 1); break; } if (.@failed == 1) { mes("Sorry, you had no luck."); } else { mes("You're a lucky person and obtain 1 Gold Coin."); getitem(Gold_Coin, 1); } close(); OnInit: .npc_name$ = "[" + strnpcinfo(NPC_NAME_VISIBLE) + "]"; .menu_option1$ = "1 Silver Coin + 500z (20% chance)"; .menu_option2$ = "1 Silver Coin + 10 Cash Points (50% chance)"; .menu_option3$ = "1 Silver Coin + 1 Poring Coin (90% chance)"; end; }

    
    
    prontera,150,170,0	script	Coin Exchange	4_F_KAFRA5,{
    	mes(.npc_name$);
    	mes("What do you want to exchange for 1 Gold Coin?");
    
    	.@selection1 = select(.menu_option1$, .menu_option2$, .menu_option3$);
    
    	mesclear();
    	mes(.npc_name$);
    
    	if (countitem(Silver_Coin) < 1) {
    		mes("You need at least 1 Silver Coin.");
    		close();
    	}
    
    	switch (.@selection1) {
    	case 1:
    		if (Zeny < 500) {
    			mes("You need at least 500z.");
    			close();
    		}
    		break;
    	case 2:
    		if (#CASHPOINTS < 10) {
    			mes("You need at least 10 Cash Points.");
    			close();
    		}
    		break;
    	case 3:
    		if (countitem(Poring_Coin) < 1) {
    			mes("You need at least 1 Poring Coin.");
    			close();
    		}
    		break;
    	}
    
    	mes("Are you sure?");
    
    	.@selection2 = select("Yes", "No");
    
    	mesclear();
    	mes(.npc_name$);
    
    	if (.@selection2 == 2) {
    		mes("Okay, see you.");
    		close();
    	}
    
    	delitem(Silver_Coin, 1);
    
    	switch (.@selection1) {
    	case 1: // 20% success chance.
    		.@failed = (rand(10000) < 8000) ? 1 : 0;
    		Zeny -= 500;
    		break;
    	case 2: // 50% success chance.
    		.@failed = (rand(10000) < 5000) ? 1 : 0;
    		#CASHPOINTS -= 10;
    		break;
    	case 3: // 90% success chance.
    		.@failed = (rand(10000) < 1000) ? 1 : 0;
    		delitem(Poring_Coin, 1);
    		break;
    	}
    
    	if (.@failed == 1) {
    		mes("Sorry, you had no luck.");
    	} else {
    		mes("You're a lucky person and obtain 1 Gold Coin.");
    		getitem(Gold_Coin, 1);
    	}
    
    	close();
    
    
    
    OnInit:
    	.npc_name$ = "[" + strnpcinfo(NPC_NAME_VISIBLE) + "]";
    	.menu_option1$ = "1 Silver Coin + 500z (20% chance)";
    	.menu_option2$ = "1 Silver Coin + 10 Cash Points (50% chance)";
    	.menu_option3$ = "1 Silver Coin + 1 Poring Coin (90% chance)";
    	end;
    }

     

     

     

    ~Kenpachi

    Thanks my idol @Kenpachi


  10. 1 hour ago, Kenpachi said:

    Hi.

     

    if (rand(10000) < 2000) // 20% chance to fail. // FAIL else // SUCCESS

    
    if (rand(10000) < 2000) // 20% chance to fail.
    	// FAIL
    else
    	// SUCCESS

     

     

    ~Kenpachi

    Hi my idol...can you show me how to put it specific on the script?

     

    and can you help me like this :

    1 silver coins + 500zeny = 20% chance to get  gold coins

    1 silver coins + 10cash = 50% chance to get gold coins

    1 silver coins + poring coin = 90% chance to get gold coins...

     

    sir @Kenpachi can you help me build this?

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.