Jump to content
  • 0

hello requesting


Phantom Of Rogue-Gon

Question


  • Group:  Members
  • Topic Count:  65
  • Topics Per Day:  0.02
  • Content Count:  181
  • Reputation:   0
  • Joined:  08/07/13
  • Last Seen:  

can i request again :D

 

example

in arena or gold room when i kill poring i got 1 cashpoint

Link to comment
Share on other sites

5 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  38
  • Topics Per Day:  0.01
  • Content Count:  276
  • Reputation:   24
  • Joined:  07/06/13
  • Last Seen:  

Hope this help:

 

-	script	OnKillPVP	-1,{

OnNPCKillEvent:
if( strcharinfo(3) == "mapname" || strcharinfo(3) == "mapname" || strcharinfo(3) == "mapname" || strcharinfo(3) == "mapname" ){
    specialeffect2 725;
    specialeffect2 378;
    sleep2 900;
set #CASHPOINTS,#CASHPOINTS+1;
getitem 969,1;
dispbottom "You have gained 1 Cash points and 1 Gold. Total is "+#CASHPOINTS+" Cash points."
}

Added some nice after effects when someone killed. :D

 

-	script	OnGoldRoom	-1,{

OnNPCKillEvent:
if( killedrid == mobID) {
    specialeffect2 725;
    specialeffect2 378;
    sleep2 900;
set #CASHPOINTS,#CASHPOINTS+1;
getitem 969,1;
dispbottom "You have gained 1 Cash points and 1 Gold. Total is "+#CASHPOINTS+" Cash points."
}

 

PM me if theres something wrong, hmmm... maybe it should work fine.
 

Edited by Lil Troll
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  65
  • Topics Per Day:  0.02
  • Content Count:  181
  • Reputation:   0
  • Joined:  08/07/13
  • Last Seen:  

i try this one :D



what kind of mob is hard to kill?



-	script	OnGoldRoom	-1,{

OnNPCKillEvent:
if( killedrid == mobID) {
    specialeffect2 725;
    specialeffect2 378;
    sleep2 900;
set #CASHPOINTS,#CASHPOINTS+1;
getitem 969,1;
dispbottom "You have gained 1 Cash points and 1 Gold. Total is "+#CASHPOINTS+" Cash points."

this one script where can put the map?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  38
  • Topics Per Day:  0.01
  • Content Count:  276
  • Reputation:   24
  • Joined:  07/06/13
  • Last Seen:  

what kind of mob is hard to kill?

create a custom mob, its easy, modify it by your server rates.

 

this one script where can put the map?

there is no map attach in that only individual mobID

 

if you want adding map restriction try this: (Tell me if not working)

-	script	OnGoldRoom	-1,{

OnNPCKillEvent:
if( killedrid == mobID && strcharinfo(3) == "GoldRoomMap") {
    specialeffect2 725;
    specialeffect2 378;
    sleep2 900;
set #CASHPOINTS,#CASHPOINTS+1;
getitem 969,1;
dispbottom "You have gained 1 Cash points and 1 Gold. Total is "+#CASHPOINTS+" Cash points."
Edited by Lil Troll
Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  33
  • Topics Per Day:  0.01
  • Content Count:  1282
  • Reputation:   393
  • Joined:  02/03/12
  • Last Seen:  

Hi I made a script awhile back for a dynamic leveling room that instead of manually adding monsters it takes the level ranges from the database and adds them to a spawn. I think it will work very well here. I have also added the cashpoint option.

 

prontera,160,158,2	script	Training Room	100,{
	select(.menu$);
	warp getd(".room"+(@menu-1)+"$[1]"),0,0;
	end;

OnNPCKillEvent:
//OnMobDeath:
	for(set .@p,0;getarraysize(getd(".room"+.@p+"$"));set(.@p,.@p+1))
		if( playerattached() ) {
			if( getd(".room"+.@p+"$[1]") == strcharinfo(3) ) {
				dispbottom "Cashpoint get! "+#CASHPOINTS++;
				monster strcharinfo(3),0,0,"--ja--",killedrid,1/*,"Training Room::OnMobDeath"*/;
				break;
			}
		}
	end;
	
Oninit:
//Configuration
//	              #   Room Name                                ,  Map         ,  MobLvlRngLow ,  MobLvlRngHigh,  #SpawnMobs,  Mobs Limit(MAX 128),   Optional Search String    ;
	setarray .room0$, "Novice Room %s~%s (<mob>,<mob>...)"     ,  "06guild_01",  "0"          ,  "10"         ,  "20"      ,  "128"              ,   "`iName` LIKE '%Por%'"    ; // Would make a novice poring room.
	setarray .room1$, "Beginner Room %s~%s (<mob>,<mob>...)"   ,  "06guild_02",  "11"         ,  "20"         ,  "5"       ,  "128"              ,   ""                        ;
	setarray .room2$, "Adept Room %s~%s (<mob>,<mob>...)"      ,  "06guild_03",  "21"         ,  "30"         ,  "5"       ,  "128"              ,   ""                        ;
	setarray .room3$, "Advanced Room %s~%s (<mob>,<mob>...)"   ,  "06guild_04",  "31"         ,  "40"         ,  "5"       ,  "128"              ,   ""                        ;
	setarray .room4$, "Experts Room %s~%s (<mob>,<mob>...)"    ,  "06guild_05",  "41"         ,  "50"         ,  "5"       ,  "128"              ,   ""                        ;
	setarray .room5$, "Veterans Room %s~%s (<mob>,<mob>...)"   ,  "06guild_06",  "51"         ,  "60"         ,  "6"       ,  "128"              ,   ""                        ;
	setarray .room6$, "MVP Room %s~%s (<mob>,<mob>...)"        ,  "06guild_07",  "61"         ,  "70"         ,  "7"       ,  "128"              ,   ""                        ;
	setarray .room7$, "Like a Boss Room %s~%s (<mob>,<mob>...)",  "06guild_08",  "71"         ,  "80"         ,  "8"       ,  "128"              ,   ""                        ;
	
	
	set .srch$, "<mob>"; //String searched and replaced with mob name in the Room Name Feild.
	set .mvps, 0; //Mvps Summoned or not? 0=Off 1=On
//End

	for(set(.@a,0);getarraysize(getd(".room"+.@a+"$"));set(.@a,.@a+1)) {
		set .rmn$, ".room"+.@a+"$";
		set .nam$, ".name"+.@a+"$";
		set .mid$, ".id"+.@a;
		
		set .rrm$, getd(.rmn$+"[0]");
		set .map$, getd(.rmn$+"[1]");
		set .lrl$, getd(.rmn$+"[2]");
		set .lrh$, getd(.rmn$+"[3]");
		set .nsms, atoi(getd(.rmn$+"[4]"));
		set .mlim, atoi(getd(.rmn$+"[5]"));
		set .ops$, getd(.rmn$+"[6]");
		
		set .length, countstr(getd(.rmn$+"[0]"), .srch$);
		set .lengt, countstr(getd(.rmn$+"[0]"), "%s");
		if(.lengt>1) set .mes$[.@a], sprintf(.rrm$,.lrl$,.lrh$);
		
		set .len, query_sql("SELECT `ID`,`iName` FROM `mob_db` WHERE `LV` > "+.lrl$+" AND `LV` < "+.lrh$+" "+((.ops$!="")?"AND "+.ops$+" ":"")+((!.mvps)?"AND `MEXP` <= 0 ":"")+"ORDER BY RAND() LIMIT "+((.mlim>128)?128:.mlim )+";",.id,.name$);
		set .lens, getarraysize(.name$);
		
		copyarray getd(.nam$+"[0]"), .name$, .lens;
		copyarray getd(.mid$+"[0]"), .id, .lens;
		deletearray .name$;
		deletearray .id;
		
		while(.@i++<=.length )
		if(.@i<=.lens) set .mes$[.@a], replacestr(.mes$[.@a], .srch$, getd(.nam$+"["+(.@i-1)+"]"), 1, 1);
		set .@i,0;
		
		for(set(.@h,0);.@h<.lens;set(.@h,.@h+1)) {
			monster .map$,0,0,"--ja--",getd(.mid$+"["+.@h+"]"),.nsms/*,"Training Room::OnMobDeath"*/;
		}
	}
	
	set .menu$, implode(.mes$,":");
}
  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  38
  • Topics Per Day:  0.01
  • Content Count:  276
  • Reputation:   24
  • Joined:  07/06/13
  • Last Seen:  

Wow awesome thanks again Skorm! :D

BTW, Can you clean up this script?
 

///////////////////////////////////////
// LIL TROLL NUB MESSY SCRIPT       //
// Feel free to modify the script  //
////////////////////////////////////
//Map,x,y,direction<TAB>script<TAB>NPC NAME<TAB>SpriteID,{ 
ftown,209,209,4	script	Rare Card Trader	604,{ 
/////////////////////////////////
//          ARRAYS            //
//////////////////////////////////////////////////////////////////////////////////
// WARNING!! DO NOT USE SAME CARD REQUIREMENT OR ELSE IT WILL BE BUGGED        //
// FINDING FIX ATM...                                                         //
///////////////////////////////////////////////////////////////////////////////
//Edit Card that npc gives. you can add more cards if you want just add ,4007,4008,4009,4010,4011; and so on..
setarray .CardList[0],4001,4002,4003,4004,4005,4006;   // Card that NPC Sells. 
setarray .CardReq[0],4001,4002,4003,4004,4005,4006;   // 1st Requirement.
setarray .CardReq1[0],4001,4002,4003,4004,4005,4006; // 2nd Requirement.

set $CARD_TRADER$, "[Yugi]"; // Change the name
    mes $CARD_TRADER$ ;
    mes "Hi " + strcharinfo(0) +" I do have rare cards here to offer. These card is limited, for every hour the card will be changed. Also I will select random cards in exchange of the cards I offer..";
    next;
    mes $CARD_TRADER$ ;
    mes "This time I sell " + (getitemname(.CardList)) + ".";
    mes "I need "+ (getitemname(.CardReq)) +" and "+ (getitemname(.CardReq1)) +"."; // Required 1 & Required 2
    next;
    menu "Yes I want that card!",BBB,"No thanks!",CCC;
    close;
BBB:
    next;
    mes $CARD_TRADER$ ;
    mes "Checking Items:";
    sleep2 1000;
    mes ".........";
    sleep2 1000;
    if (countitem(.CardReq)==0)  
    mes "You dont have "+ (getitemname(.CardReq)) +".";
    if (countitem(.CardReq1)==0) 	
    mes "You dont have "+ (getitemname(.CardReq1)) +".";
    if(countitem(.CardReq)>=1 && countitem(.CardReq1)>=1) goto AAA; 
    close;
AAA:
    next;
    mes $CARD_TRADER$ ;
    mes "You bought "+ (getitemname(.Cardlist)) +".";         
    getitem .CardList,1;	 
    delitem .CardReq,1;
    delitem .CardReq1,1;
    close;
CCC:
    next;
    mes $CARD_TRADER$ ;
    mes "See you nextime arround!";
    close; 

OnInit:
npctalk "Rare cards has been shuffled!";
initnpctimer;
end;
//////////////////////////////////////////////////////////////////////////////
// Do not change variables below, unless someone refine the ontimer.     //
////////////////////////////////////////////////////////////////////////////
//         TIMERS             //
///////////////////////////////
OnTimer3600000:
npctalk "Rare cards has been shuffled!";
set .CardList,.CardList[rand(getarraysize(.CardList))];
set .CardReq,.CardReq[rand(getarraysize(.CardReq))];
set .CardReq1,.CardReq1[rand(getarraysize(.CardReq1))];

OnTimer3601000:
initnpctimer;
end;
}
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
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.

×
×
  • Create New...