Jump to content
  • 0

Help with customize points gold room


Gelo

Question


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  56
  • Reputation:   1
  • Joined:  05/10/12
  • Last Seen:  

Need some modifications here..

the NPC have this options:

1. Enter Greedy Points Room

2. Exchange Points to Bronze Coins

3. Check Points

4. Exit

I would like to make it a room with Barricades(mob id 1906)

For every Barricade killed, there is random points from 1 to 2.

If player select the option Exchange Points to Bronze Coins,

It will Show the user how many points are available and it will ask how many points he/she wants to exchange.

The Exchange rate is this:

10 Points = 1 Bronze Coins

I am also trying to script solve this, but I think I need help from you, thanks :)

Sorry for my bad english xD

// Gold Room Ordeal by Rokimoki v1.0
// Request by: InsanityProductionsR (eAthena Forum)
// ---
// Gold Room Warper v1.0
prontera,167,172,4 script Gold Room 107,{
set .@nombre$, "[^0000FFCucaracha de Oro^000000]";
mes .@nombre$;
if (gold > 0) {
mes "BZbRzBrZ !!";
next;
mes .@nombre$;
mes "Now I can talk!! Hey, do you want to exchange gold points to gold item?";
next;
if (select("Sure!:Nope") == 2) close;
mes .@nombre$;
mes "Done ^^ BzBzBZ!!";
getitem 969,gold;
set gold, 0;
next;
mes .@nombre$;
} // End if
mes "Bz Bz BZ!¡¡!";
next;
if (select("Gold BzBz!!:A bug?") == 2) close;
close2;
warp "ordeal_3-2",154,154;
end;
} // End Script
// Script Gold v1.0
- script GoldRoom -1,{
OnNPCKillEvent:
if (strcharinfo(3) != "ordeal_3-2") end;
if (killedrid != 1233) end;
switch (rand(2)) {
case 0:
 set .@g, 1;
 set gold, gold + .@g;
 break;

case 1:
 set .@g, 2;
 set gold, gold + .@g;
 break;
 break;
} // End switch
dispbottom "You earned " +.@g +" Gold Points, you have at the moment " +gold +" Greedy points.";
end;
OnPCDieEvent:
if (strcharinfo(3) != "ordeal_3-2") end;
dispbottom "You have lost all your gold points, you have been killed by a player inside the Greedy room.";
set gold, 0;
end;
} // End Script
// Warps a prontera v1.0
- script Retorno::Retorno 45,2,2,{
end;
OnTouch:
warp "prontera",153,193;
end;
} // End Script
// Duplicados Warps v1.0
ordeal_3-2,24,228,0 duplicate(Retorno) Retorno#r1 45
ordeal_3-2,25,58,0 duplicate(Retorno) Retorno#r2 45
ordeal_3-2,289,130,0 duplicate(Retorno) Retorno#r3 45
ordeal_3-2,283,230,0 duplicate(Retorno) Retorno#r4 45
ordeal_3-2,210,203,0 duplicate(Retorno) Retorno#r5 45
// Natural Monsters v1.0
ordeal_3-2,154,153,0,0 monster Gold Peco Peco 1233,10,0,0,0
ordeal_3-2,164,163,0,0 monster Gold Peco Peco 1233,10,0,0,0
ordeal_3-2,141,1137,0,0 monster Gold Peco Peco 1233,10,0,0,0
ordeal_3-2,159,173,0,0 monster Gold Peco Peco 1233,10,0,0,0
ordeal_3-2,0,0,0,0 monster Gold Peco Peco 1233,200,0,0,0
ordeal_3-2,0,0,0,0 monster Gold Peco Peco 1233,200,0,0,0
ordeal_3-2,0,0,0,0 monster Gold Peco Peco 1233,200,0,0,0
// Map Flags v1.0
ordeal_3-2 mapflag noskill
ordeal_3-2 mapflag nobranch
ordeal_3-2 mapflag nomemo
ordeal_3-2 mapflag nowarpto
ordeal_3-2 mapflag nopenalty
ordeal_3-2 mapflag pvp_noparty
// Put this in the mob_db2.txt without "//" and with the gm do @reloadmobdb or reboot the server
// 1233,PECOPECO,Gold Peco Peco,Gold Peco Peco,60,3500,0,0,0,1,300,400,0,0,1,13,13,25,27,9,10,12,2,2,23,0x1089,200,1564,864,576,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
// 1439,G_HIGH_ORC,High Orc,High Orc,90,9000000,0,0,0,1,5000,10000,90,90,90,90,90,90,90,90,10,12,2,7,43,0x3885,160,1500,500,1000,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0

Link to comment
Share on other sites

4 answers to this question

Recommended Posts


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

try this


prontera,155,181,5 script Sample 757,{
switch( select( "Enter Greedy Points Room",
   "Exchange Points to "+getitemname(.CoinID),
   "Check Points",
   "Exit" ) ){
Case 1: warp .Map$,0,0; end;
Case 2:
 mes "You got "+#Points+" Points.";
 mes "How many will be used to change into "+getitemname(.CoinID)+" ?";
 mes "Each "+getitemname(.CoinID)+" = "+.Rate+" Points.";
 if( #Points >= .Rate ){
  input .@Amount,0,#Points;
  set .@Calculation,( .@Amount / .Rate );
  if( .@Calculation ){
   set #Points,#Points - ( .@Calculation * .Rate );
   getitem 673,.@Calculation;
   mes "Gained "+.@Calculation+" x "+getitemname(.CoinID);
  }
 }
 close;
Case 3: mes "You got "+#Points+" Points.";
default: break;
}
close; 
OnInit:
set .Map$,"guild_vs5";
set .CoinID,673;
set .Rate,10;
monster .Map$,0,0,1002,100,strnpcinfo(0)+"::OnKilled";
end;
OnKilled:
set #Points,#Points + rand(1,2);
monster .Map$,0,0,1002,1,strnpcinfo(0)+"::OnKilled";
end;
}

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  56
  • Reputation:   1
  • Joined:  05/10/12
  • Last Seen:  

Thanks emistry! I'll try this right away :)

Already tried it mr. Emistry, It is not working well..

When i choose option 2, it wont show the input box.

I think that is only the problem?

Thanks :)

Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

it will only show when you have meet the minimum point to exchange to bronze coin

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  56
  • Reputation:   1
  • Joined:  05/10/12
  • Last Seen:  

ohh..

anyways I tried this one:

prontera,155,181,5 script Sample 757,{
switch( select( "Enter Greedy Points Room",
    "Exchange Points to "+getitemname(.CoinID),
    "Check Points",
    "Exit" ) ){
Case 1: warp .Map$,0,0; end;
Case 2:
 mes "You got "+#Points+" Points.";
 mes "How many will be used to change into "+getitemname(.CoinID)+" ?";
 mes "Each "+getitemname(.CoinID)+" = "+.Rate+" Points.";
 if( #Points >= .Rate ){
  input .@Amount,0,#Points;
  set .@Calculation,( .@Amount / .Rate );
  if( .@Calculation ){
    set #Points,#Points - ( .@Calculation * .Rate );
    getitem 673,.@Calculation;
    mes "Gained "+.@Calculation+" x "+getitemname(.CoinID);
  }
 }
 close;
Case 3: mes "You got "+#Points+" Greedy Points.";
default: break;
}
close;
OnInit:
set .Map$,"guild_vs5";
set .CoinID,673;
set .Rate,10;
monster .Map$,0,0,1906,100,strnpcinfo(0)+"::OnKilled";
end;
OnKilled:
set #Points,#Points + rand(1,2);
monster .Map$,0,0,1906,1,strnpcinfo(0)+"::OnKilled";
end;
}
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0

But when I kill a barricade, no points..

It's already working!

I'll share it to you if you just want to use it :)

Thank you very much Mr. Emistry, you're one of the best! :)

prontera,155,181,5 script Sample 757,{
switch( select( "Enter Greedy Points Room",
    "Exchange Points to "+getitemname(.CoinID),
    "Check Points",
    "Exit" ) ){
Case 1: warp .Map$,0,0; end;
Case 2:
 mes "You got "+#Points+" Points.";
 mes "How many will be used to change into "+getitemname(.CoinID)+" ?";
 mes "Each "+getitemname(.CoinID)+" = "+.Rate+" Points.";
 if( #Points >= .Rate ){
  input .@Amount,0,#Points;
  set .@Calculation,( .@Amount / .Rate );
  if( .@Calculation ){
    set #Points,#Points - ( .@Calculation * .Rate );
    getitem 673,.@Calculation;
    mes "Gained "+.@Calculation+" x "+getitemname(.CoinID);
  }
 }
 close;
Case 3: mes "You got "+#Points+" Greedy Points.";
default: break;
}
close;
OnInit:
set .Map$,"guild_vs5";
set .CoinID,673;
set .Rate,10;
monster .Map$,0,0,1906,100,strnpcinfo(0)+"::OnKilled";
end;
OnNPCKillEvent:
set #Points,#Points + rand(1);
monster .Map$,0,0,1906,1,strnpcinfo(0)+"::OnKilled";
dispbottom "You Currently Have " +#Points +" Greedy Points";
end;
}
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0
guild_vs5,0,0,0,0 monster Greedy Barricade 1906,10,0,0,0

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