Jump to content

Kokak

Members
  • Posts

    15
  • Joined

  • Last visited

Posts posted by Kokak

  1. 3 hours ago, ManokStreZ said:

    try follow this one, my "Weapons" , "Other" and "NewShop" , become together with "Hat Maker" 

    any clue how to fix it ? 

    change the first value of the Add function.

    therefore, for "Hat Maker" use Add(1,x,x,x,x.....); Weapons use Add(2,x,x,x,x....) and so on.

  2. new_1-1,139,107,4	script	First 500	871,{
    if( !#First_275 ) {
    	set #First_275,1;
    	$count++;
    	setarray .rewardssss[0],18642,18643,18644;
    	set $rewardssss,.rewardssss[rand(getarraysize(.rewardssss))];
    	mes "Welcome to Ragnarok Online.";
    	mes "You received 1 random lower headgear as a freebie.";
    	getitembound $rewardssss,1,Bound_Account;
    	close;
    } else if( $count == 275 ) {
    	mes "Times Up! 275 players already got the reward!";
    	close;
    } else {
    	mes "You have claimed the Reward already.";
    	close;
    }
    }

     

  3. 10 minutes ago, Seravy said:

    What matters, assuming the skill does try to break the equipment by calling skill_break_equip, "150*skillvl" is the chance of success. It'll return true if it did break something and false if it did not. It won't always break something. In addition to that, you also need to display "fail" if you didn't even call the function, like in your example if the monster is the wrong size. But I don't think he asked for that?

     

    Yes, "150*SkillLvl" is the chance of success. It will only return a "SUCCESS" message whenever it did break the weapon. (Skill failed if not).

  4. 7 hours ago, Sakurada said:

    try adding a break after the skill works

    
    case WS_CRUSHWEAPON:
    	{
    		int s = 0;
    		skill_break_equip(src,bl, EQP_WEAPON, 150*skill_lv, BCT_ENEMY);
    		clif_displaymessage(sd->fd, "SUCCESS.");
    
    		break;
    
    		if( sd && !s ){
    			clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
    			return 0;
    		}
    		
    		clif_skill_nodamage(src,bl,skill_id,skill_lv,1);
    	}
    	break;

    ah well we may have to change this around

     

    edit: cant fucking write with this........

     

    but you just need to do something like this and break it in 2... and use clif_skill_nodamage in 2 spots...

    could be another way

    
    	case SM_BASH:
    		{
    		int s = 0;
    			skill_break_equip(src,bl, EQP_WEAPON, 150*skill_lv, BCT_ENEMY);
    			clif_displaymessage(sd->fd, "SUCCESS.");
    			clif_skill_nodamage(src,bl,skill_id,skill_lv,1);
    		break;
    		
    		if( sd && !s ){
    			clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
    			return 0;
    		}
    	}
    	break;

    Dont really know what your int s is so idk if you need to add it to that part.. its your % chance? then yeah i guess you do but not sure if i would place it under over over the return 0; so deal with it

    I tried doing this. Now it throws me "Success" always even though the skill failed to break the weapon.

  5. Hi, I have successfully implemented a custom skill.

    I just have a problem about the Success Message and Skill Failed Message:

    When you have successfully break the enemy's weapon, the message must be "SUCCESS", and "Skill Failed" when you fail to break it.

    But, it always throws me the Skill Failed message even though I successfully break the weapon.

    Here is my code:

    case WS_CRUSHWEAPON:
    	{
    		int s = 0;
    		skill_break_equip(src,bl, EQP_WEAPON, 150*skill_lv, BCT_ENEMY);
    		clif_displaymessage(sd->fd, "SUCCESS.");
    		
    		if( sd && !s ){
    			clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
    			return 0;
    		}
    		
    		clif_skill_nodamage(src,bl,skill_id,skill_lv,1);
    	}
    	break;

     

  6. 4 minutes ago, lllaaazzz said:

    What do you mean?

     

    You can just download as zip in top right corner green button on windows then use that in your server just change all your conf files for your sql

    Not the answer i need. I know that i can download as zip.

×
×
  • Create New...