Jump to content

Map Of The Week - Quest / Event - With Rewards - Best For Low or Mid Rate Servers


Recommended Posts

Posted (edited)

Map of the week

 

//===== rAthena Script ======================================================================
//= Map Of The Week v4.4
//===== Original By =========================================================================
//= Kaushik
//===== Current Version: ====================================================================
//= 1.0 - Script Release.
//= 1.1 - Added GM selection of Map Of The Week.
//= 1.2 - Fixed Timer Selection of the Map is on Sunday @ 24:00 server time.
//= 2.0 - Added Contract System.
//= 2.1 - Fixed Contract Expiry (Set #MOTWC to 0 once contract is expired).
//= 2.2 - Cleaned Script to remove some unneeded repertition and script. [ToastOfDoom]
//= 2.3 - Added Bottle Grenade ingredients to the script as it was missed.
//= 2.4 - Decreased the drop rate.
//= 2.5 - Changed announce and dispbottom.
//= 3.0 - Added Whisper Functions. (map, kills, contract, gm).
//= 3.1 - Changed to dynamic Cost and Kills - @motwcost & @motwkill to your desired numbers.
//= 3.2 - Added Menu To The NPC.
//= 4.0 - Added GM commands to change random map, selected map & to Destroy all contracts.
//= 4.1 - Removed SQL unwanted variable.
//= 4.2 - Fixed script contract count variable.
//= 4.3 - Fixed tweet to not give out contract if no map of the week is assigned.
//= 4.4 - Fixed NPC Whisper
//= 5.0 - Changed rewards to dynamic rewards [WIP].
//===== Compatible With: ====================================================================
//= Tested in SQL Revision 14435
//===== Description: ========================================================================
//= A Random Map Will be selected and edp, acid demo bottle ingredients are rewarded.
//===========================================================================================



Features

  • Selects a map every week in Prontera, Payon and Morroc Fields[Completed]
  • Rewards given when killed a monster[Completed]
  • Contract System[Completed]
  • Limited Kills[Completed]
  • Wisper System [Complete]
  • Easy configuration of the Script[Complete]
  • GM Commands[Complete]
  • Changes Map Automatically Every Week[Completed]
  • Rewards Can be set as required[Completed]
  • Fun Unlimited[Completed]

About:
This script works like this after it selects a map by itself ( can change the time to test in the script search for OnClock) this map becomes map of the week and when u kill any monster in this map on random chances you get a reward which is also set in the script.

Also there is a special function in this script it doesnt work for everyone a player has to first sign the Contract i.e he has to pay 200000Zeny for killing 10000 Monsters i.e after he kills 10000 monsters he wont be able to get any kind of rewards from that Map which is map of the week and it will be a normal map..

So if he needs to get rewards again he has to buy the contract again.
Give reviews to motivate smile.pngsmile.png


motw_v4.4.txt

motw_v4.1.txt

motw_v4.2.txt

Edited by Vengeance
  • Upvote 6
Posted (edited)

Nice script. I saw something in the script that you will need to change.

Under OnNPCKIllEvent:

Change:

	if (#MOTWKI >= 10000) goto MO_ContractEnd;

To This

	if (#MOTWKI >= @motwkill) goto MO_ContractEnd;

This enables players to change the max kills per contract and have it being checked on the monster kill events.

Edited by Syouji
Posted (edited)

I also noticed that if you choose random map option it picks maps that dont exist. For example: it chose prt_fild00 as the MOTW when i hit random map. Another thing is if you whisper the NPC for your kills if you dont have a contract, the message box window pops up empty with no close button and you can't exit the chat unless you relog.

EDIT: The random map generator was my fault. It works fine.

Edited by Syouji
Posted (edited)

Here are the areas I was talking about.

Case 1: (Msg Box Freezes Fix that had no close button when you whisper the NPC to check your kills IF you didnt have a contract)

Before:

MO_NoContract:
next;
 mes "[Map Of The Week]";
 mes "You are not under a contract";
 close;

After:

MO_NoContract:
 mes "[Map Of The Week]";
 mes "You are not under a contract";
 close;

Case 2: (NPC states that no map of the week has been assigned if the player checks the MOTW NPC by clicking and NOT whispering when there isnt one)

Before:

switch(select("^00FF00•^000000Check Map Of The Week","^00FF00•^000000Check Rewards","^00FF00•^000000Contract Status","^00FF00•^000000Sign a Contract","^00FF00•^000000Commands","^FF0000•^000000Nothing"))
{
case 1:
 next;
 mes "[Map Of The Week]";
 mes "The Map Of The Week Is ^FF0000"+$MOTW$+"^000000.";
 close;

After:

switch(select("^00FF00•^000000Check Map Of The Week","^00FF00•^000000Check Rewards","^00FF00•^000000Contract Status","^00FF00•^000000Sign a Contract","^00FF00•^000000Commands","^FF0000•^000000Nothing"))
{
case 1:
 next;
 if($MOTW$ == ""){
 mes "The Map Of The Week has not been assigned.";
 close;
  }
 mes "[Map Of The Week]";
 mes "The Map Of The Week Is ^FF0000"+$MOTW$+"^000000.";
 close;

Case 3: (Prevent player from purchasing a contract if no map of the week has been assigned fix)

Before:

case 4:
 next;
 mes "[Map Of The Week]";
 mes "Do you want to buy a contract?";
 if(select("Yes:NO")-1) {
  mes "[Map Of The Week]";
  mes "So Long Looser";
  atcommand "@die";
  close;
  }

After:

case 4:
 next;
 mes "[Map Of The Week]";
 if($MOTW$ == ""){
 mes "The Map Of The Week has not been assigned. You cannot purchase a contract at this time.";
 close;
  }
 mes "Do you want to buy a contract?";
 if(select("Yes:NO")-1) {
  mes "[Map Of The Week]";
  mes "So Long Looser";
  atcommand "@die";
  close;
  }

Edited by Syouji
  • Upvote 1
  • 11 months later...
  • 5 months later...
Posted

Oops my mistake had it updated in my server but the works folder was not updated thx for notifying have now updated the script

 

Hi, what do i do to turn it into a daily event?

  • 2 weeks later...
Posted (edited)

Gm Menu doesnt appear to me,

if(compare(@whispervar0$,"gm")) {
            if(getgmlevel() > 99) end;
            mes "[Map Of The Day]";
            mes "What do you want to do GM "+strcharinfo(0)+"?";
            switch(select("^00FF00-^000000Random MOTW","^00FF00-^000000Enter MOTW","^FF0000-^000000Destroy All Contracts","^FF0000-^000000Nothing"))
            {
            case 1:
                switch(rand(3)){
                    case 0:
                        set $@MOTWS, rand(1,11);
                        set $mapotw$, "pay_fild" + (($@MOTWS < 10)?"0":"") + $@MOTWS;
                        set $MOTW$, "Payon Forest "+$@MOTWS;
                        break;
                
                    case 1:
                        set $@MOTWS, rand(0,11);
                        set $mapotw$, "prt_fild" + (($@MOTWS < 10)?"0":"") + $@MOTWS;
                        set $MOTW$, "Prontera Field "+$@MOTWS;
                        break;
                
                    case 2:
                        set $@MOTWS, rand(1,22);
                        set $mapotw$, "moc_fild" + (($@MOTWS < 10)?"0":"") + $@MOTWS;
                        set $MOTW$, "Sograt Desert "+$@MOTWS;
                        break;
                    }
                announce "MOTW : The Map Of The Day is "+$MOTW$+"!!!!",0;
                next;
                mes "[Map Of The Day]";
                mes "The Map Of The Day is ^FF0000"+$MOTW$+"^000000!!!!";
                close;
            case 2:
                goto MOTW_Name;
            case 3:
                next;
                mes "[Map Of The Day]";
                mes "Destroyed All Contracts";
                query_sql "DELETE FROM global_reg_value where str = '#MOTWC'";
                query_sql "DELETE FROM global_reg_value where str = '#MOTWKI'";
                close;
            case 4:
                next;
                mes "[Map Of The Day]";
                mes "Come Back When You are free again";
                close;
            }
        }
Edited by Capuche
Change to BBCode
  • 3 weeks later...
  • 3 weeks later...
Posted

Yeahh.. me too..
A actually dont know how to make this script works..
Someone could come in and tell us how to make this script working with each explanation...

  • 4 weeks later...
  • 3 weeks later...
  • 1 month later...
  • 5 months later...
  • 10 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...