Jump to content

Lil Troll

Members
  • Posts

    276
  • Joined

  • Last visited

  • Days Won

    2

Posts posted by Lil Troll

  1. Thanks guys.. that a lot of explanation... 

    Im trying to understand now..  ^ ^

    Thanks to 

    Patskie

     

    Lil Troll

     

    for help..  ^ ^

     

    Here actually what i need

    • Cluckers.txt                        Everyday.(Each 12pm,1pm,12am,1am)
    • Code_Breaker.txt                Everyday.(Each  5pm,7pm,5am,7am)
    • Dice_event.txt                     Everyday.(Each 3pm,9pm,3am,9am)
    • Flower_Counting_Game.txt    Everyday.(Each(2pm,3pm,4pm,8pm,9pm,10pm)
    • Guess_The_Number.txt        Everyday.(Each Saturday Only at (5pm,7pm,5am,7am)
    • FindTheMushroom.txt           Everyday.(Each Sunday Only at (5pm,7pm,5am,7am)

      Trying to make custom of it...  ^ ^

      And also want learn more about this timing section..

      Thanks again...

      Will help ya....  Lil Troll

       

    Ok I put OnClock`s based on what you stated, just look at OnClock inside script, now its all automatic except I haven't finished adding CodeBreaker event because I need to modify the script and dissect it first. Just give me time on it. Sorry took me so long haven't open the forums recently.

     

    Also I modified the cluckers event of yours because its really outdated, tell me if not working and i will revert it back to your old ver.

    Cluckers.txt

    Dice_Event.txt

    FindTheMushroom.txt

    Flower_Counting_Game.txt

    Guess_the_Number.txt

    • Upvote 1
  2. Kinda sleepy so i don't know if this will work 

    -    script    Sample    -1,{
        OnInit:
            setarray .mob_id[0],1002,1113,1399,1159;
            set .size, getarraysize(.mob_id);
            set .random, rand(.size);
            set .amount, 5; // amount of monster spawned
            end;
            
        OnMinute30:
            set .monster, .mob_id[.random];
            monster "prontera",0,0,getmonsterinfo(.monster, 0),.monster,.amount,strnpcinfo(0)+ "::OnKill";
            end;
            
        OnKill:
            announce "Monster is already killed",0;
            end;
    }
    

    Add this for every 30mins

    OnMinute00:
    OnMinute30:
    
  3. As the tittle says. It took me a little bit of my time finishing this script. This is very simple atm, but am planning to make it more cooler. Its easy to config, just improve the npc dialogue, with sql query. Credits to xienne15 for requesting the script from this topic.

     

     

    Do you have any suggestions, did you found an error or bug? Feel free to post it all here.

     

     

    quest_limit.txt

  4. If you mind, would you give me the call func script of yours, or if not want just give me sample, i would like to create query insert when using that callfunc, im thinking of using global var but its only limited query is much better if you wanted this.

  5. Try this. Didn't test yet, tell me if not working.

    //===== rAthena Script ======================================= 
    //= Find the Mushroom
    //===== By: ================================================== 
    //= Mysterious
    //===== Current Version: ===================================== 
    //= 3.6a
    //===== Compatible With: ===================================== 
    //= rAthena SVN
    //===== Description: ========================================= 
    //= Find the Mushroom - random amount of Mushrooms spawns in random maps.
    //= Players need to find these mushrooms and kill them to gain prizes!
    //===== Additional Comments: =================================
    //= 3.0 Fully Functional with Rewritten script. [Mysterious]
    //= 3.6a Slightly edited. [Euphy]
    //============================================================ 
    
    prontera,142,228,6	script	Find the Mushroom	1084,{
    	mes "[ Find The Mushroom ]";
    	if (!.Status)
    		mes "There is no event at the moment!";
    	else {
    		mes "There are "+.Spawn+" Mushrooms left in "+.Map$+"!";
    		mes "Find and kill the mushrooms to gain "+getitemname(.Prize)+"!";
    	}
    	if (.Status || getgmlevel() < .GM) close;
    	mes "Start the event?";
    	next;
    	if(select("- No:- Yes") == 1) close;
    	donpcevent strnpcinfo(0)+"::OnMinute60";
    	mes "[ Find The Mushroom ]";
    	mes "Event started!";
    	close;
    
    OnInit:
    	set .Prize,7505;	// Reward item ID
    	set .Amount,1;	// Reward item amount
    	set .GM,60;	// GM level required to access NPC
    	setarray .Maps$[0],"izlude","prontera","geffen","aldebaran","alberta","yuno","payon"; // Possible maps
    	end;
    
    OnMinute00:
    	if (.Status) {
    		killmonster .Map$,"All";
    		set .Status,0;
    	}
    	set .Status,1;
    	set .Spawn,rand(20,20);	// How many Mushrooms should spawn?
    	set .Map$,.Maps$[rand(getarraysize(.Maps$))];
    	killmonster .Map$,"All";
    	monster .Map$,0,0,"Please don't kill me!",1084,.Spawn,strnpcinfo(0)+"::OnMobKilled";
    	announce "Find the Mushroom : Total of "+.Spawn+" Mushrooms have been spawned in "+.Map$+"!",0;
    	sleep 2500;
    	announce "Find the Mushroom : Every Mushroom you kill will give you "+getitemname(.Prize)+"!",0;
    	end;
    
    OnMobKilled:
    	set .Spawn, .Spawn - 1;
    	getitem .Prize, .Amount;
    	if (.Spawn) announce "[ "+strcharinfo(0)+" ] has killed a Mushroom. There are now "+.Spawn+" Mushroom(s) left.",bc_map;
    	else {
    		announce "The Find the Mushroom Event has ended. All the Mushrooms have been killed.",0;
    		set .Status,0;
    	}
    	end;
    }
    
  6. for(set .@i,0; .@i<getarraysize(.MVP) set .@i,.@i+1){
    monster .Map$[ .RandMap ],0,0,"MVP Event",.MVP[ .@i ],1,strnpcinfo(0)+"::OnKilled"; }
    

    It will summon all MVP in array.

    Actually i havent test it yet, but i think it would work, tell me if not.

  7. Hai rAthena anyone can help me help to edit this script. I want make every Friday at 11PM this event will

    start and will finish at Sunday 11PM.

     

    -	script	double_exp_2weeks	-1,{
    OnInit:
    	// original Base/Job Exp and Drop Rates
    	set .bexp_rate, 25;
    	set .jexp_rate, 25;
    	set .drop_rate, 25;
    	
    	if (atoi(gettimestr("%Y%m%d",9)) < 20130203) {
    		setbattleflag "base_exp_rate", .bexp_rate*100 * 2;
    		setbattleflag "job_exp_rate", .jexp_rate*100 * 2;
    		
    		setbattleflag "item_rate_common", .drop_rate*100 * 2;
    		setbattleflag "item_rate_heal", .drop_rate*100 * 2;
    		setbattleflag "item_rate_use", .drop_rate*100 * 2;
    		setbattleflag "item_rate_equip", .drop_rate*100 * 2;
    		setbattleflag "item_rate_card", .drop_rate*100 * 2;
    		
    		atcommand "@reloadmobdb";
    		announce "The Double Exp Event continues!", bc_all;
    	}
    	end;
    	
    OnDay0203: // Feb 3
    	setbattleflag "base_exp_rate", .bexp_rate*100;
    	setbattleflag "job_exp_rate", .jexp_rate*100;
    	
    	setbattleflag "item_rate_common", .drop_rate*100;
    	setbattleflag "item_rate_heal", .drop_rate*100;
    	setbattleflag "item_rate_use", .drop_rate*100;
    	setbattleflag "item_rate_equip", .drop_rate*100;
    	setbattleflag "item_rate_card", .drop_rate*100;
    	
    	atcommand "@reloadmobdb";
    	announce "The Double Exp Event has ended.", bc_all;
    	end;
    }
    

     

    I take this script from here http://rathena.org/board/topic/77571-rate-x2-for-2-week/

     

    Thanks

    done :)

    -	script	double_exp_2weeks	-1,{
    OnInit:
    	set .bexp_rate, 25;
    	set .jexp_rate, 25;
    	set .drop_rate, 25;
    end;
    
    OnFri2300:
    	setbattleflag "base_exp_rate", .bexp_rate*100 * 2;
    	setbattleflag "job_exp_rate", .jexp_rate*100 * 2;
    	setbattleflag "item_rate_common", .drop_rate*100 * 2;
    	setbattleflag "item_rate_heal", .drop_rate*100 * 2;
    	setbattleflag "item_rate_use", .drop_rate*100 * 2;
    	setbattleflag "item_rate_equip", .drop_rate*100 * 2;
    	setbattleflag "item_rate_card", .drop_rate*100 * 2;
    	atcommand "@reloadmobdb";
    	announce "Week End Double Exp Started!", bc_all;
    end;
    
    OnSun2300:
    	setbattleflag "base_exp_rate", .bexp_rate*100;
    	setbattleflag "job_exp_rate", .jexp_rate*100;
    	setbattleflag "item_rate_common", .drop_rate*100;
    	setbattleflag "item_rate_heal", .drop_rate*100;
    	setbattleflag "item_rate_use", .drop_rate*100;
    	setbattleflag "item_rate_equip", .drop_rate*100;
    	setbattleflag "item_rate_card", .drop_rate*100;
    	atcommand "@reloadmobdb";
    	announce "The Double Exp Event has ended.", bc_all;
    end;
    }
    
  8. ////////////////////////////////////////////////////////////////////////
    //--------------------------------------------------------------------//
    //                            BULLETIN NPC                            //
    //                     AUTHOR: LIL TROLL//COLDFIRE                    //
    //--------------------------------------------------------------------//
    //                          RATHENA SCRIPT                            //
    //--------------------------------------------------------------------//
    //                             Version 1                              //
    //--------------------------------------------------------------------//
    //   CREDITS TO : Phantom Of Rouge-Gon for requesting the script.     //
    //   FEATURES : Market Bulletin NPC for Buying&&Selling Items.        //
    //   - Full SQL SUPPORT with one GlobalVar used "$BulletinCount"      //
    //   - Auto/Manual Installation of SQL_Query.			      //
    //   - Very easy to config and very customizable. (See OnInit)	      //
    //   GM MENU :							      //
    //   - Can Delete any post.					      //
    //   - Can View Account ID && Ban/Unban any, who abuses the Bulletin. //
    //   PLAYER MENU:						      //
    //   - Create any post per category.				      //
    //   - Delete his/her own post.					      //
    //   - Built in search for online character of the poster Account-Id  //
    //     when he/she want to buy or sell an item to the post maker.     //
    //--------------------------------------------------------------------//
    ////////////////////////////////////////////////////////////////////////

    If someone found any error or bug, please report it directly to this topic. Suggestions are welcome! Have fun using the script! :)

     

    bulletin_npc_v1.txt

    • Upvote 1
  9. ..

    Try this:

    prontera,150,165,5	script	Hourly reward	87,{
    	if ( #hourly_timer > gettimetick(2) ) {
    		mes "You must wait "+ callfunc( "timeleft__",#hourly_timer-gettimetick(2) ) +".";
    		close;
    	}
    	mes "Here your hourly Item : x"+ .item_amount +" ^ff0000"+ getitemname( .item_ID );
    	getitem .item_ID, .item_amount;
    	set #hourly_timer,gettimetick(2)+3600;
    	close;
    OnInit:
    	set .item_ID,501;
    	set .item_amount,1;
    	end;
    }
    
  10. Do you want all NPC to start at the same time? Every 4hours or like below:

    12.00am  - Guess the Number

    4.00am - Flower Counting

    8.00am - Dice Event

    12.00pm  - Guess the Number

    5.pm - Flower Counting

    8.pm- Dice Event

     

    Give me the same format as this, then ill edit those script and make them automatically set to what time you stated. I will leave marks so that you will find where did I modify the script, and learn from it. :)

    • Upvote 1
  11. Ok give me a bit, i must create a condition if you are a guild master.



    I figure that you cannot change the name in your the Guild Listing, I think its because its client sided or something is preventing that, i tried changing the names in guild_member in query but everytime I char select and refresh the sql it returns back to original name. The best way is to prevent any player from changing name when they are in guild.

     

    Now here is the script. Just modify the dialogues. :)

    -Added if Char Name already exists restrictions.

    -Added if Char is already in a guild restrictions.

    (Use transfer Guild Leader first before changing name if character is a Guild Leader.)

    prontera,158,182,0	script	Sample	100,{
    	mes "Blahblah";
    	menu "Change Name",one,"Change Birth",two;
    		one:
    			query_sql "SELECT `name` FROM `ragnarok`.`char` WHERE `name` = '"+strcharinfo(0)+"'",.@current$;	
    			set @GID,getcharid(2);
    			if(!@GID==0){
    				mes "Please leave your guild first before you change name.";
    				close;
    			}
    			mes "Input name...";
    			input .@name$;
    			if(getstrlen(.@name$)<4| getstrlen(.@name$)>23){
    				mes "You cannot enter less than minimum of 4 and greater than maximum of 23 characters.";
    				close;
    			}
    			if(.@name$ == strcharinfo(0)) {
    				mes "You cannot enter same name.";
    				close;
    			}
    			query_sql "SELECT `name` FROM `ragnarok`.`char` WHERE `name` = '"+.@name$+"'",.@existing$;
    			if(.@name$ == .@existing$){
    				mes "Name already exists.";
    				close;
    			}				
    			mes "New name: "+.@name$+"";
    			query_sql "UPDATE `char` SET `name` = '"+escape_sql(.@name$)+"' WHERE `name` = '"+strcharinfo(0)+"'";
    			sleep2 1000;
    			mes "Name successfully changed, please relog to see changes.";
    			close;
    		two:
    			query_sql "SELECT `birthdate` FROM `ragnarok`.`login` WHERE `account_id` = '"+getcharid(3)+"'",.@birthdate$;
    			mes "Birth Date: "+.@birthdate$+"";
    			mes "Input Year of Birth.";
    			input .@year;
    			if(.@year==0){
    				mes "You entered wrong number of month.";
    				close;
    			}
    			mes "Input Month of Birth.";
    			input .@month;
    			if(.@month==0||.@month>12){
    				mes "You entered wrong number of month.";
    				close;
    			}
    			mes "Input Day of Birth.";
    			input .@day;
    			if(.@day==0||.@day>31){
    				mes "You entered wrong number of day.";
    				close;
    			}
    			mes "New B-D: "+.@year+"-"+.@month+"-"+.@day+"";
    			query_sql "UPDATE `login` SET `birthdate` = '"+escape_sql(.@year)+"-"+escape_sql(.@month)+"-"+escape_sql(.@day)+"' WHERE `account_id` = '"+getcharid(3)+"'";
    			sleep2 1000;
    			mes "Birth Date successfully changed!";
    			close;
    }
    
    • Upvote 1
×
×
  • Create New...