Jump to content

Nerfwood

Members
  • Posts

    104
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by Nerfwood

  1. I'm only replying here because no one else did, even if I don't understand much of your issue.

     

    So I assume that you mean conquered castles are not spawning Emperium during WoE (because they really don't if WoE is disabled, just to make things clear).

     

    Have you disabled the official WoE controllers (agit_controller.txt) in scripts_guild.conf and you didn't disable agit_main.txt as well?

     

    If you haven't disabled the official WoE controller, then disable it. If you have disabled the agit_main.txt, then go enable it.

    You may also want to switch to Euphy's WoE controller, but make sure to apply the changes I have mentioned.

    Edit:
    If those doesn't work, then you should provide more information.

  2. Not sure about this, but check skill.c

    		if( sd && battle_config.equip_self_break_rate )
    		{	// Self weapon breaking
    			rate = battle_config.equip_natural_break_rate;
    			if( sc )
    			{
    				if(sc->data[SC_GIANTGROWTH])
    					rate += 10;
    				if(sc->data[SC_OVERTHRUST])
    					rate += 10;
    				if(sc->data[SC_MAXOVERTHRUST])
    					rate += 10;
    			}
    
    • Upvote 2
  3. Have you already tried the example?

     

    Anyway, try this one.

    case SC_FREEZE:
    sc_def = status->mdef*100;
    sc_def2 = status->luk*100/35 + status_get_lv(bl)*10 - status_get_lv(src)*10;
    tick_def2 = status->luk*10 + status_src->luk*-10; // Caster can increase final duration with luk
    break;
    

    Hard/equip mdef should already be decreasing the duration by 0.1 sec each. Or are you referring to soft/status mdef?

    • MVP 1
  4. As stated in the script_commands.txt file:

     

     

    *unitwalk <GID>,<x>,<y>;
    *unitwalk <GID>,<Target ID>;

    This command will tell a <GID> to walk to a position, defined either as a set of
    coordinates or another object. The command returns a 1 for success and 0 upon failure.

    If coordinates are passed, the <GID> will walk to the given x,y coordinates on the
    unit's current map. While there is no way to move across an entire map with 1 command
    use, this could be used in a loop to move long distances.

     

     

    It also has something to do with the mob's sight range, if not mistaken, just like how you can't directly walk to cells that is not within your character's view or walk range. (Not sure about this.) I don't recommend increasing it because the mob will be able to detect players from afar as well.

     

    Just try looping unitwalk until the mob reaches its destination.

    • Upvote 1
  5. Try this?

     

     

    *checkoption(<option number>)
    *checkoption1(<option number>)
    *checkoption2(<option number>)
    *setoption <option number>{,<flag>};

    The 'setoption' series of functions check for a so-called option that is set on
    the invoking character. 'Options' are used to store status conditions and a lot
    of other non-permanent character data of the yes-no kind. For most common cases,
    it is better to use 'checkcart','checkfalcon','checkriding' and other similar
    functions, but there are some options which you cannot get at this way. They
    return 1 if the option is set and 0 if the option is not set.

    Option numbers valid for the first (option) version of this command are:

    0x1       - Sight in effect.
    0x2       - Hide in effect.
    0x4       - Cloaking in effect.
    0x8       - Cart number 1 present.
    0x10      - Falcon present.
    0x20      - Peco Peco present.
    0x40      - GM Perfect Hide in effect.
    0x80      - Cart number 2 present.
    0x100     - Cart number 3 present.
    0x200     - Cart number 4 present.
    0x400     - Cart number 5 present.
    0x800     - Orc head present.
    0x1000    - The character is wearing a wedding sprite.
    0x2000    - Ruwach is in effect.
    0x4000    - Chasewalk in effect.
    0x8000    - Flying or Xmas suit.
    0x10000   - Sighttrasher.
    0x100000  - Warg present.
    0x200000  - The character is riding a warg.

    ...read script_commands.txt for more info

     

    Untested:

    ....{},{ setoption 0x100000; },{ setoption 0x100000,0; }

    This should add a warg to the character if the item is equipped, and remove the warg if it's unequipped. I do not guarantee that this will work, whatsoever.

  6. Aside from Skorm's way, you can use item_noequip.txt in your /db/import folder in conjunction with the restricted zone mapflag to add restrictions to items in certain maps. This method is longer but preferable when adding numerous item (and/or skill) restrictions.

     

    For skills, use skill_nocast_db.txt instead of item_noequip.txt.

  7. It has been over a year, and, I presume, it's still on hold. It would be really great if there's an update regarding this new upcoming feature of rAthena. Any way the community can help to speed up the process?

     

    Also, is it possible to develop this feature without looking into multi-client support? I mean, why is it so important to put the development on hold because of multi-client support? I genuinely don't know what I'm talking about, so please do enlighten me.

  8. pc_status_def_rate: 35 = 350?

     

    No, don't change that, unless you want all statuses to be about 3x harder to resist. It only changes the natural resistance of players comparative to those set in status.c. So let's say you set pc_status_def_rate to 200, which is twice as normal. It will make resisting all the statuses twice as easier, e.g., 50 vit instead of 100 for stun immunity.

     

    Just change the following in status.c:

    	case SC_FREEZE:
    sc_def = status->mdef*100;
    sc_def2 = status->luk*10 + status_get_lv(bl)*10 - status_get_lv(src)*10;
    tick_def2 = status_src->luk*-10; // Caster can increase final duration with luk
    break;
    

    to:

    	case SC_FREEZE:
    sc_def = status->mdef*100 + status->luk*100/35;
    sc_def2 = status->luk*10 + status_get_lv(bl)*10 - status_get_lv(src)*10;
    tick_def2 = status->luk*10 + status_src->luk*-10; // Caster can increase final duration with luk
    break;
    

    350 LUK should give a 100% immunity, but immunity can also be achieved with less LUK by having a high/decent MDEF. (1MDEF = 1% resistance.)

     

     

    Target's LUK should also affect the duration now, but not sure if every 100 LUK can reduce 1 second.

  9.  

    Someone have the effects?

     

    "Burn away as you hold this CD in our mouth.",
    "While attacking has a 6% chance of activating for 5 seconds a random level 1-5 [Fire Bolt] [Cold Bolt] [Lightning Bolt] [Earth Spike] or [Soul Strike] on your target.",
    "Class: ^777777Headgear^000000",
    "Defense: ^7777770^000000",
    "Location: ^777777Lower^000000",
    "Weight: ^77777720^000000",
    "Required Level: ^77777720^000000",
    "Jobs: ^777777All class except novice^000000"

     

     

     

    I really don't like to spoonfeed people, but since I already have the code:

     

    18666,CD_In_Mouth,CD In Mouth,4,20,,200,,0,,0,0xFFFFFFFE,63,2,1,,20,0,815,{ autobonus "{ bonus3 bAutoSpell,8013,5,40; bonus3 bAutoSpell,8013,4,40; bonus3 bAutoSpell,8013,3,40; bonus3 bAutoSpell,8013,2,40; bonus3 bAutoSpell,8013,1,40; bonus3 bAutoSpell,13,1,10; bonus3 bAutoSpell,13,2,10; bonus3 bAutoSpell,13,3,10; bonus3 bAutoSpell,13,4,10; bonus3 bAutoSpell,13,1,10;   }",60,5000,0,"{ specialeffect2 EF_POTION_BERSERK;   }"; },{},{}
    

    Notes:

    • Skill ID 8013 = Caprice; 13 = Soul Strike. Autobonus doesn't support skill names since they (skill names) break the quotation ("") marks.
    • Caprice randomly casts FB, LB, CB and ES. I gave it a 4% chance of autocasting so as if each bolt is casted at a 1% rate.

    Edit: Should have been posted at the requests section?

    • Upvote 1
    • Love 1
  10. Replace the comma at the end of L_arug_cas01 with a semi-colon (;).

    menu
    "Kriemhild",L_prt_cas01,
    "Sacred Altar",L_pay_cas04,
    "Horn",L_arug_cas03,
    "Vidblainn",L_schg_cas03,
    "Mardol",L_arug_cas01,

    You should look at the console next time to see the errors you are getting. Also, I'm not sure if there are any other errors in this script.

  11. Edit it at src/map/status.c.

     

     

    Start at Line 7190. I'm not sure about the exact values, but sc_def and sc_def2 deals with the resistance, while tick_def deals with the duration. I'm guessing that a 100 sc_def will result to 100% resistance a.k.a. immunity, but I'm not so sure. Go experiment.

    And remember to compile after saving your changes, or it won't take effect.

  12. I would really like to see a script command where we can spawn a monster and set it as a player's ally without being in a battleground area.

    If there's a command like that, please let me know since I need it for a script I'm itching to do. lol :lol:

    I'll try to apply this patch sometime later... hope it works!

  13. You mean to add more cards available to sell? which is the MVP cards right?

     

    If im correct here are the list of the ID# of the MVP cards that are available for sell.

    you can see that on the script. just add the ID# of the cards you want to be available.

     

    I believe he meant to add another category aside from the Normal and MVP cards.

     

     

    Hi,

     

    Can anyone help me modify Euphy's Card Trader script to add more card categories like Category 1,2 3 & 4 instead of just having normal and MvP cards?

     

    Anyway, here it is. All cards are categorized as class 1 by default. You have to specify which will be class 2, 3 and 4 in the script.

    Note: I did not edit the information part so you have to edit it yourself.

    //===== rAthena Script =======================================
    //= Card Trader
    //===== By: ==================================================
    //= Euphy
    //===== Current Version: =====================================
    //= 1.1 
    //===== Compatible With: =====================================
    //= rAthena SVN
    //===== Description: =========================================
    //= Exchange cards for points.
    //============================================================
     
    ruhel,74,58,4	script	Card Captor Sakura	10044,{
    	mes "[^995050Card Captor Sakura^000000]";
    	mes "Hi, "+strcharinfo(0)+"!";
    	mes "What can I do for you?";
    	next;
    	switch(select(" > Information: > Trade in cards: > Point shop (^0055FF"+getd(.Points$)+"^000000): > Leave")) {
    	case 1:
    		mes "[^995050Card Captor Sakura^000000]";
    		mes "Do you find that you've got";
    		mes "useless cards lying around?";
    		mes "I'll be glad to take them off";
    		mes "your hands!";
    		next;
    		mes "[^995050Card Captor Sakura^000000]";
    		mes "I'll give you ^0055FF"+.Points[0]+" Point"+((.Points[0] == 1)?"":"s")+"^000000 for each";
    		mes "card you give me, and";
    		mes "^0055FF"+.Points[1]+" Points^000000 for MVP cards.";
    		mes "You can trade those points";
    		mes "for items later on.";
    		mes "How does that sound?";
    		emotion e_cash;
    		close;
    	case 2:
    		mes "[^995050Card Captor Sakura^000000]";
    		mes "Select the cards you";
    		mes "want to trade in.";
    		if (.Level) {
    			mes " ";
    			mes "They must be dropped";
    			mes "by monsters of level";
    			mes .Level+" and above.";
    		}
    		deletearray @sold_nameid[0],getarraysize(@sold_nameid);
    		callshop "card_shop",2;
    		npcshopattach "card_shop";
    		end;
    	case 3:
    		mes "[^995050Card Captor Sakura^000000]";
    		mes "You have ^0055FF"+getd(.Points$)+"^000000 Point"+((getd(.Points$) == 1)?".":"s.");
    		callshop "card_shop",1;
    		npcshopattach "card_shop";
    		end;
    	case 4:
    		mes "[^995050Card Captor Sakura^000000]";
    		mes "*yawn*";
    		mes "See you later!";
    		emotion e_yawn;
    		close;		
    	}
     
    OnSellItem:
    	mes "Cards to sell:";
    	mes "-----------------------------------";
    	for(set .@i,0; .@i<getarraysize(@sold_nameid); set .@i,.@i+1)
    		if (@sold_nameid[.@i] > 4000 && @sold_nameid[.@i] < 4700) {
    			if (.Level) {
    				query_sql("SELECT `LV` FROM `mob_db` WHERE `DropCardid` = "+@sold_nameid[.@i],.@lv);
    				if (.@lv < .Level) {
    					dispbottom getitemname(@sold_nameid[.@i])+" is under the minimum level.";
    					continue;
    				}
    			}
    			set .@card_id[getarraysize(.@card_id)], @sold_nameid[.@i];
    			set .@card_amt[getarraysize(.@card_amt)], @sold_quantity[.@i];
    			set .@class2, compare(.class2$,""+@sold_nameid[.@i]);
    			set .@class3, compare(.class3$,""+@sold_nameid[.@i]);
    			set .@class4, compare(.class4$,""+@sold_nameid[.@i]);
    			mes ((.@class2 || .@class3 || .@class4)?"  ^FF0000":"  ^777777")+@sold_quantity[.@i]+"x "+getitemname(@sold_nameid[.@i])+"^000000";
    			if(.@class2) { .@class=1; }
    			else if(.@class3) { .@class=2; }
    			else if(.@class4) { .@class=3; }
    			else { .@class=0; } 
    			set .@card_total, .@card_total+ ( @sold_quantity[.@i]* .Points[.@class] );
    		}
    	deletearray @sold_nameid[0], getarraysize(@sold_nameid);
    	deletearray @sold_quantity[0], getarraysize(@sold_quantity);
    	if (!.@card_id) {
    		mes "  ^777777(none)^000000";
    		emotion e_swt;
    		close;
    	}
    	mes " ";
    	mes "---------- Total: ^0055FF"+.@card_total+" pt.^000000 -------";
    	next;
    	if(select(" > ^0055FFComplete trade...^000000: > ^777777Cancel^000000") == 2) {
    		mes "[Card Trader]";
    		mes "Oh, okay...";
    		emotion e_hmm;
    		close;
    	}
    	for(set .@i,0; .@i<getarraysize(.@card_id); set .@i,.@i+1)
    		delitem .@card_id[.@i],.@card_amt[.@i];
    	setd .Points$, getd(.Points$)+.@card_total;
    	mes "[Card Trader]";
    	mes "All done!";
    	emotion e_ho;
    	close;
     
    OnBuyItem:
    	for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1)
    		for(set .@j,0; .@j<getarraysize(.Shop); set .@j,.@j+2)
    			if (@bought_nameid[.@i] == .Shop[.@j]) {
    				set .@cost, .@cost+(.Shop[.@j+1]*@bought_quantity[.@i]);
    				break;
    			}
    	if (.@cost > getd(.Points$)) {
    		mes "[Card Trader]";
    		mes "You don't have enough Points.";
    		emotion e_omg;
    	}
    	else {
    		mes "Items purchased:";
    		mes "-----------------------------------";
    		for(set .@i,0; .@i<getarraysize(@bought_nameid); set .@i,.@i+1) {
    			getitem @bought_nameid[.@i], @bought_quantity[.@i];
    			mes "  ^777777"+@bought_quantity[.@i]+"x "+getitemname(@bought_nameid[.@i])+"^000000";
    		}
    		mes " ";
    		mes "---------- Total: ^0055FF"+.@cost+" pt.^000000 -------";
    		setd .Points$, getd(.Points$)-.@cost;
    		emotion e_cash;
    	}
    	deletearray @bought_nameid[0], getarraysize(@bought_nameid);
    	deletearray @bought_quantity[0], getarraysize(@bought_quantity);
    	close;
     
    OnInit:
    	set .Level,0;		   // Minimum monster level to trade corresponding cards.
    	set .Points$,"#CASHPOINTS";	// Variable to store points.
    	setarray .Shop[0],		// Card Shop items: <ID>,<point cost>
    	  5027,10, 18505,10, 5176,10, 5305,20;
    
    	//setarray .Points[0],5,100;	// Points per <normal card>,<MVP card>
    	setarray .Points[0],3,5,10,25;	// Points per <Class 1>,<Class 2>,<Class 3>,<Class 4>
    	
    	set .class2$,	// Class 2 cards | Those not within Class 2 ~4 are all Class 1
    		"4268,4194,4222,4275";
    		
    	set .class3$,
    		"4054,4047,4174";
    		
    	set .class4$,			// List of MVP cards. | Previously .MVP$
    		"4121,4123,4128,4131,4132,4134,4135,4137,4142,4143,4144,4145,4146,4147,4148,4168,4236,"+
    		"4241,4263,4276,4302,4305,4318,4324,4330,4342,4357,4359,4361,4363,4365,4399,4403,4407";
    	
    	npcshopdelitem "card_shop",909;
    	for(set .@i,0; .@i<getarraysize(.Shop); set .@i,.@i+2)
    		npcshopadditem "card_shop",.Shop[.@i],.Shop[.@i+1];
    	end;
    }
    -	shop	card_shop	-1,909:-1
    
    • Upvote 1
  14. Anyone can help me to know how to back the old interface of pvp room.. when you enter the room you can choose a different  room limit of a level of char.

     

    Are you referring to the X/Y pvp ranking display on the lower right corner of the screen? If so, it won't show if your server is on PK mode.

     

    If you're referring to official servers' PVP room brackets, then just copy them?

  15. but how if i want that refine level also random ?

     

    Use rand(min,max) for the refine argument, e.g.,

    getitem2 <item id>,<amount>,<identify>,rand(5,10),<attribute>,<card1>,<card2>,<card3>,<card4>;

    The above code will generate an item with a random refine rate of 5 ~ 10.

  16. its posibble to make opened pvp party only around 8 PM - 11 PM

    thats mean pvp solo and 1 vs 1 will closed if 8 PM - 11PM

     

    Use the OnClock<time>, label and then set an npc-only variable to disable access to the said rooms.

     

    Sample:

    OnClock2000:
    	set .partyonly,1;
    	announce "1v1 and No Party PvP rooms have been closed.",bc_all;
    	end; 
    OnClock2300:
    	set .partyonly,0;
    	announce "1v1 and No-Party PvP rooms are now open.",bc_all;
    	end;
    

    Then, add an if statement:

    switch( select( "PVP No Party ["+getmapusers("guild_vs3")+"]",
    								"PVP Normal ["+getmapusers("Party_PvP")+"]",
    								"PVP 1 vs 1 ["+getmapusers("1vs1_PvP")+"]" ) ){
    		Case 1:
    				if(.partyonly) { mes "This PvP room is currently closed. Please comeback later."; close; }
    				warp "guild_vs3",0,0;
    				break;
    		Case 2:
    				warp "Party_PvP",0,0;
    				break;
    		Case 3:
    				if(.partyonly) { mes "This PvP room is currently closed. Please comeback later."; close; }
    				if( getmapusers("1vs1_PvP") > 1 ){
    						mes "Room Full";
    				}else{
    						warp "1vs1_PvP",40,34;
    				}
    				break;
    		}
    close;
    

    You can also disable the rooms by making the menu as a variable instead, then change its value with the OnClock label. I haven't tested that yet though. :)

    • Upvote 1
  17. the script has this function

    // check if any available equip to refine
    if( !.@equipment_count ){
    	message strcharinfo(0),"Sorry, but you didnt have equipment that refined between "+.@arg[1]+" ~ "+.@arg[2]+" for refine.";
    	end;
    

    and I am using a consumable item for this Refine Function. what i want is not to delete the " Refine Ticket " when Player don't have any items equipped. 

     

     

    When the player doesn't have any items equipped, it won't be displayed on the menu. Thus, it's impossible for the refine ticket to be consumed.

     

    Also, the function you quoted only checks if the item is within the allowable refine range. If there's no item, then that argument won't be called.

     

    Here's an example of that usage: let's say your defined minimum refine rate is 5 and the max is 8. If you have a +3 item, then you cannot refine that item because it doesn't meet the minimum requirement. Same with a +9 item. The min/max refine range can be defined at arg2 and arg3, as explained in the script.

    callfunc( "RefineFunc",<arg1>,<arg2>,<arg3>,<arg4>,<arg5>,<arg6>,<arg7>,<arg8>{,<arg9>,<arg10>} );
    for example Refine level of the weapon is on +10 if you continue to refine the weapon up to +11 it will consume 2 Refinery Ticket instead of 1 Ticket from 0 ~ 10.

     

     

    I'm as lazy as I'm interested on doing this, so I'm sorry. It seems fun to code, though. I'll try to code this one if nobody provided you within a week or so. ^_^

×
×
  • Create New...