Jump to content

t3quila

Members
  • Posts

    36
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by t3quila

  1. is this possible?

    	case SP_MAGIC_HP_DRAIN_RATE: // bonus2 bMagicHPDrainRate,x,n;
    		if(!sd->state.lr_flag) {
    			sd->skillatk.hp_drain_rate.rate += type2;
    			sd->skillatk.hp_drain_rate.per += val;
    		}
    		break;
    	case SP_MAGIC_SP_DRAIN_RATE: // bonus2 bMagicSPDrainRate,x,n;
    		if(!sd->state.lr_flag) {
    			sd->skillatk.sp_drain_rate.rate += type2;
    			sd->skillatk.sp_drain_rate.per += val;
    		}
    		break;

     

  2. I use latest rathena, and i can convert it to rathena, but not completely fixed,

    no error for image, but still, i stuck in "while (true) {"

    anyone can help me to solve it?

     

    1540358234242.gif

     

    i stuck in here

      while (true) {
            if ( (zeny < .Zeny_Cost) && (#freewheelfortunespin < 0))
                callsub S_End;
            switch (select(
                (#freewheelfortunespin > 0)?"Yes! Use free spin! ("+#freewheelfortunespin+" left)":
                (Zeny >= .Zeny_Cost)?"Yes! Use Zeny. (costs "+.Zeny_Cost+"z)":
                "No (Leave)"
            )) {
            // pay with free spin
            case 1:
                if (#freewheelfortunespin > 0) {
                    if ((#freewheelfortunespin -= 1) < 0)
                        #freewheelfortunespin = 0;
                    callsub S_Spin;
                } else
                    callsub S_End;
                break;
    
            // Pay with zeny
            case 2:
                if (zeny >= .Zeny_Cost) {
                    set zeny,zeny-.Zeny_Cost;
                    callsub S_Spin;
                } else {
                    cutin "aca_salim02",2;
                    mes .EventName$;
                    mes "Awww, you don't have enough to gamble...";
                    mes " ";
                    mes "Have you ever heard?";
                    mes "'Money isn't all that matters' Got it?";
                    mes "Byeeeeeeeeeeeeee ;)";
                    callsub S_End;
                }
                break;
    
            default:
                callsub S_End;
            }
        }

     

  3. do you mean like this?

    skill.c / skill.cpp

    
    case SM_BASH:
    		if( sd && skill_lv > 5 && pc_checkskill(sd,SM_FATALBLOW)>0 ){
    			//BaseChance gets multiplied with BaseLevel/50.0; 500/50 simplifies to 10 [Playtester]
    			status_change_start(src,bl,SC_STUN,(skill_lv-5)*sd->status.base_level*10,
    				skill_lv,0,0,0,skill_get_time2(SM_FATALBLOW,skill_lv),SCSTART_NONE);
    		}
    		//Your Custom SC for BASH | 2*skill_lv+10 = is Chance | skill_get_time2 (duration) you can add sum or min for this
    		sc_start(src,bl,SC_BASHMARK,(2*skill_lv+10),skill_lv,skill_get_time2(skill_id,skill_lv));
    		sc_start(src,bl,SC_BURNING,(2*skill_lv+10),skill_lv,skill_get_time2(skill_id,skill_lv));
    		sc_start(src,bl,SC_STONE,(2*skill_lv+10),skill_lv,skill_get_time2(skill_id,skill_lv));
    		sc_start(src,bl,SC_MAGICMUSHROOM,(2*skill_lv+10),skill_lv,skill_get_time2(skill_id,skill_lv));
    		sc_start(src,bl,SC_DPOISON,(2*skill_lv+10),skill_lv,skill_get_time2(skill_id,skill_lv));
    		break;

    &

    skill_cast_db.txt

    //-- SM_BASH
    5,0,0,0,10000,10000,0,0 // 10000 Means 10 seconds of all your Bash Debuff duration (randomly)

     

  4. i use this for a chance

    		int8 rchance = rnd()%100;
    
    		if( rchance > 10 ){
    		//if( rd.flag[sd->roulette.stage][sd->roulette.prizeIdx]&1 ){
    			result = GENERATE_ROULETTE_LOSING;
    			sd->roulette.stage = 0;
    		}else{
    			result = GENERATE_ROULETTE_SUCCESS;
    			sd->roulette.stage++;
    		}
    	}

    it means, chance success just only 10%

    Quote

     

     

  5. in clif.cpp

    You can find in there

    
    	if( !sd->roulette.stage && sd->roulette_point.bronze <= 0 && sd->roulette_point.silver < 10 && sd->roulette_point.gold < 10 ){
    		result = GENERATE_ROULETTE_NO_ENOUGH_POINT;
    	}else{
    		if (!sd->roulette.stage) {
    			if (sd->roulette_point.bronze > 0) {
    				sd->roulette_point.bronze -= 1;
    				pc_setreg2(sd, ROULETTE_BRONZE_VAR, sd->roulette_point.bronze);
    			} else if (sd->roulette_point.silver > 9) {
    				sd->roulette_point.silver -= 10;
    				sd->roulette.stage = 2;
    				pc_setreg2(sd, ROULETTE_SILVER_VAR, sd->roulette_point.silver);
    			} else if (sd->roulette_point.gold > 9) {
    				sd->roulette_point.gold -= 10;
    				sd->roulette.stage = 4;
    				pc_setreg2(sd, ROULETTE_GOLD_VAR, sd->roulette_point.gold);
    			}
    		}

    (dont forget recompile)

    • Upvote 1
    • Like 1
  6. i have no idea for add option in battle config,

    but if you just want showing Devotion Icon for who receiving status devotion,

    you just add this on status.c

    StatusIconChangeTable[SC_DEVOTION] = SI_DEVOTION;
    recompile, and you must add your image icon (example devotion.tga) to effect folder, and add name and description to your status icon lua (luafiles514/lua files/stateicon)
  7. you can add SC_WARMER and modif it, in status.c if you want..

    for exp:

    	case SC_DEEPSLEEP:
    	case SC_SLEEP:
    	case SC_STUN:
    	case SC_FREEZING:
    	case SC_CRYSTALIZE:
    		if (sc->opt1)
    			return 0; // Cannot override other opt1 status changes. [Skotlex]
    		if((type == SC_FREEZE || type == SC_FREEZING || type == SC_CRYSTALIZE) && sc->data[SC_WARMER])
    			return 0; // Immune to Frozen and Freezing status if under Warmer status. [Jobbie]
    	break;
    
    ///////////////////////////////
    	case SC_WARMER:
    		status_change_end(bl, SC_CRYSTALIZE, INVALID_TIMER);
    		status_change_end(bl, SC_FREEZING, INVALID_TIMER);
    		status_change_end(bl, SC_FREEZE, INVALID_TIMER);
    		break;
    
    add this:

    StatusIconChangeTable[SC_ANTIFROST] = SI_ANTIFROST; //in line statusiconchangetable
    
    	case SC_DEEPSLEEP:
    	case SC_SLEEP:
    	case SC_STUN:
    	case SC_FREEZING:
    	case SC_CRYSTALIZE:
    		if (sc->opt1)
    			return 0; // Cannot override other opt1 status changes. [Skotlex]
    		if((type == SC_FREEZE || type == SC_FREEZING || type == SC_CRYSTALIZE) && sc->data[SC_WARMER])
    			return 0; // Immune to Frozen and Freezing status if under Warmer status. [Jobbie]
    		if((type == SC_FREEZE) && sc->data[SC_ANTIFROST])
    			return 0; // Immune to Frozen only. [T3quila]
    	break;
    
    ///////////////////////////////
    	case SC_WARMER:
    		status_change_end(bl, SC_CRYSTALIZE, INVALID_TIMER);
    		status_change_end(bl, SC_FREEZING, INVALID_TIMER);
    		status_change_end(bl, SC_FREEZE, INVALID_TIMER);
    		break;
    	case SC_ANTIFROST:
    		status_change_end(bl, SC_FREEZE, INVALID_TIMER);
    		break;
    
    dont forget to add SC_ANTIFROST and SI_ANTIFROST to status.h and const.txt, dont forget for recompile your server, and add your stateicon folder .lua/lub in your client.
  8. maybe you can add status icon with Urgent call/Guild Recall with SI_ in status.c

    for exp:

    set_sc( GD_EMERGENCYCALL, SC_GUILDCALL, SI_GUILDCALL, SCB_NONE );
    
    StatusIconChangeTable[SC_GUILDCALL] = SI_GUILDCALL;
    
    
    after create that status icon,

    dont forget to recompile your map server.

    and dont forget to add skill_db.txt,etc and .lua/lub for your client.

    exp: http://rathena.org/b...om-guild-skill/

  9. you can modif it in battle.c and search SC_SPIRIT

    for example, you want change damage for holy light (if priest given sl spirit)

    					case AL_HOLYLIGHT:
    						skillratio += 25;
    						if (sd && sd->sc.data[SC_SPIRIT] && sd->sc.data[SC_SPIRIT]->val2 == SL_PRIEST)
    							[b]skillratio *= 5; //Does 5x damage include bonuses from other skills?[/b]
    						break;
    
    most important to modif effect of the spirit is from

    if (sd && sd->sc.data[SC_SPIRIT] && .....blablabla)
  10. thank's Emistry, but.. i can't modify source, its to hard for me hahaha >_<

    oh i can see annie's modification in here.. adding source onPcChatEvent?

    - script asdfadsfasdfa -1,{
    OnPCChatEvent:
    for ( set .@i, 0; .@i < .size; set .@i, .@i +1 ) {
    if ( compare( @pc_chattext$, .foul$[.@i] ) ) {
    announce strcharinfo(0) +", stop speaking rude ! detect '"+ .foul$[.@i] +"'", 0;
    end;
    }
    }
    end;
    OnInit:
    setarray .foul$, "tanga", "shit", "fuck", "asshole";
    set .size, getarraysize(.foul$);
    }
    
    
    
    still could use it in last git?
  11. Hallo Masters of Source, after i discussed about PCRE and whisper_sys with Emistry in this topic

    i wish, this function can be reality if anyone can help me how to create source about deffpatern with global npc (like whisper_sys do)..

    for example:

    -	script	HealMeEverywhere	-1,{

    end;

    OnHealPlayer:

    percentheal 100, 100;

    specialeffect2 EF_HEAL;

    end;

    OnInit:

    (for example)defpatternglobal 1, "([^:]+):.*\\sheal plz(\\s.*)?", "OnHealPlayer";

    activatepset 1;

    }

    so when i use normal chat "heal plz" global npc automatic heal me, in everywhere and everytime i need..

    anyone can help my wishing for? i think it's possible to make great thing like this. ^^

    thank you ^^

  12. mmmh i think use with PCRE for example.. hehehe =P

    but emistry it is possible if use PCRE without a whisper?maybe use script like this but combine with pcre?

    -	script	testpcre	-1,{
    //script for example give a blessing anywhere when i use chat "angel please blessing me" (without near npc/whispering)
    }
    possible?
  13. it is possible using normal chat to command/trigerred npc?

    not like bindatcmd with "@" but like a normal chat?

    for example:

    1. i use normal chat to command npc to release the monsters, like "hey kafra you fool!" then kafra release the monster for me.

    2. or like this "Angel please blessing me" and global npc gift me a blessing skill on my mine.

    it is posibble? if yes, please help me how to write the script like that? thanks everyone

    *sorry for my bad english.

  14. i don't think so it was a bug, because in official idro it wasn't bug until now, it summon 5 balls in level 1.

    you can change this in skill.c (if you want back turn effect the old one)

    from

    		{
    			short element = 0, sctype = 0, pos = -1, j = 0;
    			struct status_change *sc = status_get_sc(src);
    
    			if( !sc )
    				break;
    
    			for( i = SC_SPHERE_1; i data[i] )
    					sctype = i; // Take the free SC
    				if( sc->data[i] ) {
    					pos = max(sc->data[i]->val2,pos);
    					j++;
    				}
    			}
    
    			if( !sctype || j >= skill_lv ) {
    				if( sd ) // No free slots to put SC
    					clif_skill_fail(sd,skill_id,USESKILL_FAIL_SUMMON,0);
    				break;
    			}
    
    			pos++; // Used in val2 for SC. Indicates the order of this ball
    			switch( skill_id ) { // Set val1. The SC element for this ball
    				case WL_SUMMONFB:    element = WLS_FIRE;  break;
    				case WL_SUMMONBL:    element = WLS_WIND;  break;
    				case WL_SUMMONWB:    element = WLS_WATER; break;
    				case WL_SUMMONSTONE: element = WLS_STONE; break;
    			}
    
    			sc_start4(src,src,(enum sc_type)sctype,100,element,pos,skill_lv,0,skill_get_time(skill_id,skill_lv));
    			clif_skill_nodamage(src,bl,skill_id,0,0);
    		}
    		break;
    

    to this

    {
    			short element = 0, sctype = 0, pos = -1;
    			struct status_change *sc = status_get_sc(src);
    		
    			if( !sc ) break;
    
    			for( i = SC_SPHERE_1; i data[i] )
    					sctype = i; // Take the free SC
    				if( sc->data[i] )
    					pos = max(sc->data[i]->val2,pos);
    			}
    
    			if( !sctype )
    			{
    				if( sd ) // No free slots to put SC
    					clif_skill_fail(sd,skill_id,USESKILL_FAIL_SUMMON,0);
    				break;
    			}
    
    			pos++; // Used in val2 for SC. Indicates the order of this ball
    			switch( skill_id )
    			{ // Set val1. The SC element for this ball
    				case WL_SUMMONFB:    element = WLS_FIRE;  break;
    				case WL_SUMMONBL:    element = WLS_WIND;  break;
    				case WL_SUMMONWB:    element = WLS_WATER; break;
    				case WL_SUMMONSTONE: element = WLS_STONE; break;
    			}
    
    			sc_start4(src,src,(enum sc_type)sctype,100,element,pos,skill_lv,0,skill_get_time(skill_id,skill_lv));
    			clif_skill_nodamage(src,bl,skill_id,0,0);
    		}
    		break;
    

    i almost forgot..look it this (in iro) same as in ratemyserver script.10gn1xw.jpgits level is only affected by damage, duration and sp cost.for me this is very disappointing to know that http://rathena.org/board/tracker/issue-9120-warlock-summon-elemental-balls/ this custom request like this can make aleos replace its original script on last git. (sorry not offens aleos )

×
×
  • Create New...