Jump to content

✰ Euphy's Scripts ✰


Euphy

Recommended Posts


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@Jazz: You would pretty much need to rescript the entire thing.

@Dramosmith: Works fine for me. r16862 may be the cause (partially upgrading...?).

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  40
  • Topics Per Day:  0.01
  • Content Count:  275
  • Reputation:   7
  • Joined:  10/08/12
  • Last Seen:  

hi

Euphy

...I tried the script but i have a problem...I got errors when preview items...(ex. my Champion became Lord Knight no solar god helm then error after)/// any idea what's wrong????

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  175
  • Reputation:   14
  • Joined:  11/21/11
  • Last Seen:  

hi, im having a problem with the announce emp breaker in woe_controller because i don't know how to get the char_id of the player who breaks and i already tried using strcharinfo(0) and it's not attached.

Thanks.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  815
  • Reputation:   86
  • Joined:  10/26/12
  • Last Seen:  

hi euphy i got some error here

//===== rAthena Script =======================================
//= Euphy's Quest Shop
//===== By: ==================================================
//= Euphy
//===== Current Version: =====================================
//= 1.4a
//===== Compatible With: =====================================
//= rAthena SVN r15340+
//===== Description: =========================================
//= A dynamic quest shop based on Lunar's, with easier config.
//= Includes support for multiple shops & cashpoints.
//= Item Preview script by ToastOfDoom.
//============================================================

zhakastia,94,37,1 script Silver Coin Exchanger 112,{
function Add; function Chk; function Slot; function A_An;
if(.Shops$ != "") set .@i,1;
else {
 set .@menu$,"";
 for(set .@i,1; .@i<=getarraysize(.Shops$); set .@i,.@i+1)
  set .@menu$, .@menu$+.Shops$[.@i]+":";
 set .@i, select(.@menu$); }
dispbottom "Select one item at a time.";
callshop "qshop"+.@i,1;
npcshopattach "qshop"+.@i;
end;
function Add {
if (getitemname(getarg(1))=="null") {
 debugmes "Quest reward #"+getarg(1)+" invalid (skipped)."; return; }
for(set .@n,5; .@n<127; set .@n,.@n+2) {
 if (!getarg(.@n,0)) break;
 if (getitemname(getarg(.@n))=="null") {
  debugmes "Quest requirement #"+getarg(.@n)+" invalid (skipped)."; return; } }
for(set .@i,2; .@i<.@n; set .@i,.@i+1)
 set getd(".q_"+getarg(1)+"["+(.@i-2)+"]"), getarg(.@i);
npcshopadditem "qshop"+getarg(0),getarg(1),((.ShowZeny)?getarg(3):0);
return; }
function Chk {
if (getarg(0)<getarg(1)) { set @qe0,1; return "^FF0000"; }
else return "^00FF00"; }
function Slot {
set .@s$,getitemname(getarg(0));
switch(.ShowSlot){
 case 1: if (!getitemslots(getarg(0))) return .@s$;
 case 2: if (getiteminfo(getarg(0),11)>0) return .@s$+" ["+getitemslots(getarg(0))+"]";
 default: return .@s$; } }
function A_An {
setarray .@A$[0],"a","e","i","o","u";
set .@B$, "_"+getarg(0);
for(set .@i,0; .@i<5; set .@i,.@i+1)
 if (compare(.@B$,"_"+.@A$[.@i])) return "an "+getarg(0);
return "a "+getarg(0); }
OnBuyItem:
set .@q[0],@bought_nameid;
copyarray .@q[1],getd(".q_"+@bought_nameid+"[0]"),getarraysize(getd(".q_"+@bought_nameid+"[0]"));
if (!.@q[1]) { message strcharinfo(0),"An error has occurred."; end; }
mes "[Quest Shop]";
mes "Reward: ^0055FF"+((.@q[1]>1)?.@q[1]+"x ":"")+Slot(.@q[0])+"^000000";
mes "Requirements:";
if (.@q[2]) mes " > "+Chk(Zeny,.@q[2])+.@q[2]+" Zeny^000000";
if (.@q[3]) mes " > "+Chk(getd(.Points$[0]),.@q[3])+.@q[3]+" "+.Points$[1]+" ("+getd(.Points$[0])+"/"+.@q[3]+")^000000";
if (.@q[4]) for(set .@i,4; .@i<getarraysize(.@q); set .@i,.@i+2)
 mes " > "+Chk(countitem(.@q[.@i]),.@q[.@i+1])+((.DisplayID)?"{"+.@q[.@i]+"} ":"")+Slot(.@q[.@i])+" ("+countitem(.@q[.@i])+"/"+.@q[.@i+1]+")^000000";
next;
set @qe1, getiteminfo(.@q[0],5); set @qe2, getiteminfo(.@q[0],11);
addtimer 1000, strnpcinfo(1)+"::OnEnd";
while(1){
 switch(select(" ~ Purchase ^0055FF"+getitemname(.@q[0])+"^000000:"+((((@qe1&1) || (@qe1&256) || (@qe1&512)) && @qe2>0 && !@qe6)?" ~ Preview...":"")+": ~ ^777777Cancel^000000")) {
  case 1:
   if (@qe0) {
    mes "[Quest Shop]";
    mes "You're missing one or more quest requirements.";
    close; }
   if (!checkweight(.@q[0],.@q[1])) {
    mes "[Quest Shop]";
    mes "^FF0000You need "+(((.@q[1]*getiteminfo(.@q[0],6))+Weight-MaxWeight)/10)+" additional weight capacity to complete this trade.^000000";
    close; }
   if (.@q[2]) set Zeny, Zeny-.@q[2];
   if (.@q[3]) setd .Points$[0], getd(.Points$[0])-.@q[3];
   if (.@q[4]) for(set .@i,4; .@i<getarraysize(.@q); set .@i,.@i+2)
    delitem .@q[.@i],.@q[.@i+1];
   getitem .@q[0],.@q[1];
   if (.Announce) announce strcharinfo(0)+" has created "+A_An(getitemname(.@q[0]))+"!",0;
   specialeffect2 699;
   close;
  case 2:
   set @qe3, getlook(3); set @qe4, getlook(4); set @qe5, getlook(5);
   if (@qe1&0) atcommand "@changelook 4 "+@qe2;
   if (@qe1&256) atcommand "@changelook 1 "+@qe2;
   if (@qe1&512) atcommand "@changelook 2 "+@qe2;
   set @qe6,1;
   break;
  case 3:
   close; } }
OnEnd:
if (@qe6) { atcommand "@changelook 4 "+@qe3; atcommand "@changelook 1 "+@qe4; atcommand "@changelook 2 "+@qe5; }
for(set .@i,0; .@i<7; set .@i,.@i+1) setd "@qe"+.@i,0;
end;
OnInit:
freeloop(1);
// --------------------- Config ---------------------
// Custom points, if needed: "<variable>","<name to display>"
setarray .Points$[0],"#CASHPOINTS","Cash Points";
set .Announce,0; // Announce quest completion? (1: yes / 0: no)
set .ShowSlot,0; // Show item slots? (2: all equipment / 1: if slots > 0 / 0: never)
set .DisplayID,0; // Show item IDs? (1: yes / 0: no)
set .ShowZeny,0; // Show Zeny cost, if any? (1: yes / 0: no)
// Shop categories, if needed: "<Shop 1>","<Shop 2>"{,...};
// Duplicate dummy data for any additional shops (bottom of script).
// If no categories, use the second line instead (remove //).
setarray .Shops$[4],"Silver Coin";
// set .Shops$,"n/a";
// Add(<shop number>,<reward ID>,<reward amount>,<Zeny cost>,<point cost>,
//     <required item ID>,<required item amount>{,...});
// Shop number corresponds with order above (default is 1).
// Note: Do NOT use a reward item more than once!
Add(4,678,1,0,0,7960,1);
Add(4,12114,1,0,0,7960,1);
Add(4,12115,1,0,0,7960,1);
Add(4,12117,1,0,0,7960,1);
Add(4,12215,1,0,0,7960,1);
Add(4,12216,1,0,0,7960,1);
Add(4,12217,1,0,0,7960,1);
Add(4,12218,1,0,0,7960,1);
Add(4,12219,1,0,0,7960,1);
Add(4,12220,1,0,0,7960,1);
Add(4,12251,1,0,0,7960,1);
Add(4,12250,1,0,0,7960,1);
Add(4,12253,1,0,0,7960,1);
Add(4,12255,1,0,0,7960,1);
Add(4,12206,1,0,0,7960,1);
Add(4,12220,1,0,0,7960,1);
// --------------------------------------------------
freeloop(0);
for(set .@i,1; .@i<=getarraysize(.Shops$); set .@i,.@i+1)
 npcshopdelitem "qshop"+.@i,909;
end;
}
// -------- Dummy data (duplicate as needed) --------
- shop qshop4 -1,909:-1

debug script debug : 110148609 : quest requirement # invalid skipped

Edited by Euphy
Codeboxed.
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  5
  • Topics Per Day:  0.00
  • Content Count:  62
  • Reputation:   2
  • Joined:  10/17/12
  • Last Seen:  

Hi Friend @euphy

Could you help me? :)

How can i script like

i want hide them from level 0 GM(public) but show only for GM level 1(superplayer) if can? Just Only Number 3 qshop3

Add(3,531,1,3,0,512,1,713,1);
Add(3,532,1,3,0,513,1,713,1);
Add(3,533,1,3,0,514,1,713,1);
Add(3,534,1,3,0,515,1,713,1);

Thanks you if you reply,

Dramosith.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@miczster: r16862

@Feefty: My script does not control that. Edit your guild files.

@Mootie: The Add() function checks if the item ID is valid. It should have included an ID in the output... check what's missing from your shop?

@Dramosith: You'll need to move the menu loop back up to the top (not OnInit, which I added in v1.4b), and add the GM level check there in the shop selection.

  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  5
  • Topics Per Day:  0.00
  • Content Count:  62
  • Reputation:   2
  • Joined:  10/17/12
  • Last Seen:  

@miczster: r16862

@Feefty: My script does not control that. Edit your guild files.

@Mootie: The Add() function checks if the item ID is valid. It should have included an ID in the output... check what's missing from your shop?

@Dramosith: You'll need to move the menu loop back up to the top (not OnInit, which I added in v1.4b), and add the GM level check there in the shop selection.

hi friend euphy,can you please show me how add codes? i am really sorry because i missunderstand

very thanks you if you try help me :)

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@Dramosith: Doing it statically requires least modification, which would be:

-    if (.Shops$ == "") set .@i, select(.menu$);
+    if (.Shops$ == "") {
+        if (getgmlevel()) set .@i, select(.menu$);
+        else set .@i, select(.Shops$[1],.Shops$[2]);
+    }

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  175
  • Reputation:   14
  • Joined:  11/21/11
  • Last Seen:  

@miczster: r16862

@Feefty: My script does not control that. Edit your guild files.

@Mootie: The Add() function checks if the item ID is valid. It should have included an ID in the output... check what's missing from your shop?

@Dramosith: You'll need to move the menu loop back up to the top (not OnInit, which I added in v1.4b), and add the GM level check there in the shop selection.

got it thanks!

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  99
  • Reputation:   4
  • Joined:  10/25/12
  • Last Seen:  

Euphy, about your quest shop I try to duplicate the npc and each npc sell different items. The problem is All the item will be at all npcs that i duplicated.

How can i seperate the item for each npc. I dont wanna use multi function.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@scenarykeem: Copy the script, find&replace "qshop" with another name. For more efficiency, see post #20.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  45
  • Topics Per Day:  0.01
  • Content Count:  172
  • Reputation:   0
  • Joined:  07/07/12
  • Last Seen:  

After Guild 1 kill Emperium ( all map WOE ), Guild 2 can't kill again :(]

it mean can't kill two times

I use Euphy's WOE Controller and already disable two file!

npc\guild\agit_controller.txt

npc\guild2\agit_start_se.txt

I think it error about script default of rathena!

not script of Euphy =.=

Because that script is just a controller

bump, please help :((

Edited by zhaosin
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

WOE Controller updated to v1.4! The LoadEvent implementation now allows you to use other WOE scripts along with this (ex. Emistry's class restrictions), and makes modifications easier in general. There is now a setting to kick players from unconquered castles outside of WOE, as requested. Script format standardized (mostly).

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  6
  • Topics Per Day:  0.00
  • Content Count:  26
  • Reputation:   0
  • Joined:  06/25/12
  • Last Seen:  

Hi Euphy! :) I want to create multiple quest shop. how?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@cawogeek: 3 posts above

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  6
  • Topics Per Day:  0.00
  • Content Count:  26
  • Reputation:   0
  • Joined:  06/25/12
  • Last Seen:  

hehe thanks! it worked! :)

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  10
  • Reputation:   0
  • Joined:  02/05/12
  • Last Seen:  

I am using the following script however I am having a problem

Euphy's Quest Shop v1.4b.txt

My store does not open with the items and should only opens with this image below

2iiubya.jpg

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@RafaelS2Tatiana: The OnInit label must not have loaded properly, try an @reloadscript.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  1
  • Topics Per Day:  0.00
  • Content Count:  9
  • Reputation:   0
  • Joined:  10/23/12
  • Last Seen:  

Thanks mr. Euphy /no1

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  45
  • Topics Per Day:  0.01
  • Content Count:  172
  • Reputation:   0
  • Joined:  07/07/12
  • Last Seen:  

How to disable Music ( Sound ) of your Emperium Script :(

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@zhaosin: Delete this part:

OnAgitStart: while(agitcheck()) { misceffect 58; sleep 425; } end;

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  99
  • Reputation:   4
  • Joined:  10/25/12
  • Last Seen:  

Quest shop bug when preview. Kick out from game.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  815
  • Reputation:   86
  • Joined:  10/26/12
  • Last Seen:  

Hi euphy is your hunting mission can be per account and per character so it wont be abuse if they create another char? and per ip? example 3-4 times for same ip's cause some other players is playing in cafe so that will be same ip and for those people who have their own computer will be 1 ip allowed only is it possible? or other ways to do so

setarray .Modifier[0],	// Multipliers for Base Exp, Job Exp, and Zeny rewards.
	getbattleflag("base_exp_rate")/100,getbattleflag("job_exp_rate")/100,60;

i dont understand about this config? is this a 2x? per monster?..

Also some error shows post-9398-0-59633600-1354205501_thumb.png

how to setup to 2hours per hunting mission?

Edited by Mootie
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

@scenenarykeem: You're probably using a version incompatible with your SVN revision.

@Mootie: It's already account-based, yes you can create an IP restriction through a separate SQL table, no you cannot give exceptions to cafe players. The multiplier is exactly what it's defined as: base value x modifier (ex. setting to "1" would be 1x rates, "10" would be 10x rates, the default is your server's rates). The warning is because your rates are too high for the calculation (e.g. exceeds 2^31), so you need to lower the modifier value.

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
Reply to this topic...

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