Jump to content

Haziel

Content Moderator
  • Posts

    639
  • Joined

  • Last visited

  • Days Won

    90

Posts posted by Haziel

  1. My If just checks if it's on correct time.

    if (
    	gettime(4) == 5		// GetTime(4) returns the Day of Week, 5 is Friday
    	&& 
    	gettime(3) => 15	// GetTime(5) returns the Hour, 15 means 15:00 
    	&&
    	gettime (3) =< 23	// Same as above.
    ){
    

    It checks if it's Friday, AND the hour is 15 or above AND the hour is 23 or below.
    If it's not, it'll just close the window.

    You can add an else { } with some message warning that it only works on those day and hours.
    If you want the NPC to hide itself when It's not that period of time, just add.

    OnFriday1500:
    	enablenpc "Scarlet Palace";
    	end;
    
    OnSaturday0000:
    	disablenpc "Scarlet Palace";
    	end;
    

    And edit:

    OnInit:
    	if (gettime(4) == 5 && gettime(3) => 15 && gettime (3) =< 23) disablenpc "Scarlet Palace";
    	setarray .Castles$[0],"payg_cas02";
    	end;
    
  2. Add, below:

    if (agitcheck() || agitcheck2()) { mes "WoE is currently still in progress."; close; }
    

    This line:

    if (gettime(4) == 5 && gettime(3) => 15 && gettime (3) =< 23){
    

    And close it before the last close:

        getitem 7227,10;
        getitem    7199,10;
        getitem 674,2;
        getitem .RandItem[rand(getarraysize(.RandItem))], 1;  //Set your prize here!
    }
    close;

    By the way, a simple look on doc/script_commands.txt and a few tries and you could solve this by yourself.

  3. 1. Increase STR based on Refine of the (item like armor or weapon) compounded to:

    bonus bStr, getrefine() * x;	// Where x is the number of STR points per refine 
    

    2. Increase MaxHP by 100 per base Vit:

    bonus bMaxHP, bVit * 100;	// Change the 100 if you want a different multiplier
    

    3. Increase 10% of your Attack in Poison Damage:

    bonus bAtkEle,Ele_Poison;	// Turning into Poison Element
    bonus bAtkRate,10;  		// Adding 10% on Damage 
    

    4. Increase MAtk by 2 times of your Job Level and reduces your after cast delay or Skill Delay by Job Level/50:

    bonus bMatk, 2 * JobLevel;			// Increasing MAtk
    bonus bDelayrate, -1 * (JobLevel/50); 		// Reducing Aftercast Delay
    

    5. Reduce Damage from Reflected Melee Attacks:

    I could not find a code for this one.
  4. Try this one:

    <?xml version="1.0" encoding="euc-kr" ?>
    <clientinfo>
    	<desc>Ragnarok Client Information</desc>
    	<servicetype>korea</servicetype>
    	<servertype>primary</servertype>
    	<connection>
    		<display>Ragnarok</display>
    		<desc>Ragnarok Online</desc>
    		<balloon></balloon>
    		<address>127.0.0.1</address>
    		<port>6900</port>
    		<version>38</version>
    		<langtype>0</langtype>
    		<registrationweb>REGISTRATION URL HERE</registrationweb>
    		<aid>
    			<admin>2000000</admin>
    		</aid>
    		<loading>
    			<image>loading00.jpg</image>
    		</loading>
    	</connection>
    </clientinfo>
    
  5. Well, you can just change the If, if there will will be only a few maps to:

    if ( .@map$ == "aldeg_cas01" || .@map$ == "prtg_cas01" || .@map$ == "arug_cas01" || .@map$ == "schg_cas01") {
    

    Since || means 'or'.

     

    Or else, you can set an array and verify it with a for, something like:

    	setarray .@maps$[0],"aldeg_cas01","prtg_cas01","arug_cas01","schg_cas01";
    	
    	getmapxy .@map$, .@x, .@y, 0;
    	
    	for(set .@i,0; .@i < .@count; set .@i,.@i+1){
    		if (.@map$ == .@maps$[.@i]){
    			query_sql "SELECT `connect_member` FROM `guild` WHERE `guild_id` = '" +getcharid(2)+ "'",.@c;
    			if ( .@c > 10 ) {
    				message strcharinfo(0),"Your guild members are over the limit";
    				sleep2 2000;
    				warp "prontera",156,183;
    			}
    			end;
    		}
    	}	
    	end;
    

    Also, remember that only maps with loadevent mapflag will trigger the OnPCLoadMapEvent label.

×
×
  • Create New...