Jump to content
  • 0

Donate once a day only


Eross

Question


  • Group:  Members
  • Topic Count:  155
  • Topics Per Day:  0.11
  • Content Count:  349
  • Reputation:   12
  • Joined:  04/05/20
  • Last Seen:  

Hi ! I modified a script that I got from rathena called Monster of the day (credits to the author) and added a donation system that will allow players to donate certain amount of zeny to trigger the Repick mode .. My problem is .. How will I make one player to vote once every day only to avoid abuse ?? and I need to add a timer cooldown so players who didnt donate will not be able to cast donation once the repick has done on the same day .. 

//**********************************************************************************
// ____                    _                                            _   _  ____ 
//|  _ \ ___   ___   ____ | |  ___   ____   ___   ___   __  ___   _  _ | |_| |/ __ |
//| |__// _ \ / _ \ |  _ \| | / _ \ |  _ \ / _ \ /  _| / _)/ _ \ | \| ||___  |\__  |
//| |  |  __/ ||_|| | |__/| ||  __/ | |__/|  __/ | |  _\ \ ||_|| | \\ |    | |   | |
//|_|___\___|_\___/_| |___|_|_\___|_| |____\___|_|_|_(___/ \___/_|_|\_|____|_|___|_|
//------------------|_|-------------|_|---------------------------------------------
//**********************************************************************************
//===== rAthena Script =============================================================
//= Monster Of The Day
//===== By: ========================================================================
//= Peopleperson49 (Eddie) - [email protected]
//===== Start Date: ================================================================
//= 20NOV2011
//===== Current Version: ===========================================================
//= 1.4
//===== Compatible With: ===========================================================
//= rAthena SVN
//===== Description: ===============================================================
//= Another Monster Of The Day script. I made this one from scratch to be very
//=	simple and work automatically. Uses almost the full list of monsters from
//=	the mob_branch. I included the dispbottom here when players login, but I
//=	actually perfer to use a login script with this in it.
//===== Version Control: ===========================================================
//= 1.0 First Version.
//= 1.1	Broke .MobTypeArray[0] into ten seperate arrays to allow full list of mobs
//=	to be used without overflowing the array. Before I had to limit the number
//=	of mobs in an array to around 100 or I would randomly get an error from it.
//= 1.2	Modified script to not change mobs if scripts are reloaded. Will set mob if
//=	not already set on OnInit.
//= 1.3 Changed getexp to BaseExp.
//= 1.4 Added bindatcmd to allow GM to repick the MOTD.
//===== Additional Comments:========================================================
//= 
//==================================================================================
//-	script	MOTD#RoUG	-1,{
//prontera,158,190,4	script	Monster Of The Day	844,{
prontera,158,190,4	script	Monster Spirit	802 ,{
	mes "[Monster Of The Day]";
	mes "You will earn twice the EXP from killing "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!";
	next;
	mes "[Monster Of The Day]";
	mes "You can donate on our Monster Control Department if you wish to ramdomly change the MOTD.";
	switch(select("Donate ["+callfunc("F_InsertComma",$motd_zeny) + "/"+callfunc("F_InsertComma",.motd_td)+"].","Nevermind.")) {
		case 1:
	Change_Amount:		
			mes "[Monster Of The Day]";
			mes "Please input desired amount.";
			next;
			input .@motd_zeny;
			if (.@motd_zeny < 1) {
				mes "[Monster Of The Day]";
				mes "Input number greater than 0.";
				end;		
			}	
			mes "[Monster Of The Day]";
			mes "Please confirm Zeny transfer.";
			next;
			switch(select("Change Amount:Confirm")) {
				case 1:
					.@motd_zeny = 0;
					next;
					goto Change_Amount;
					end;
				case 2:
					if (Zeny < .@motd_zeny) {
						mes "[Monster Of The Day]";
						mes "Sorry, but you don't have enough";
						mes "zeny to donate.";
						end;
					}
					if (.@motd_zeny > $motd_diff) {
						mes "[Monster Of The Day]";
						mes "The amount you entered will exceed on remaining balance.";
						mes "Remaining Balance: "+callfunc("F_InsertComma",$motd_diff)+" Zeny";
						mes "^ff0000*Please input exact amount next time*.";
						end;
					}	
					if (.@motd_zeny == $motd_diff) {
						goto Initiate_MOTD;
						end;
					}
					Initiate_MOTD:	
					mes "[Monster Of The Day]";
					mes "Zeny has succesfully transfered.";
					Zeny -= .@motd_zeny;
					$motd_zeny += .@motd_zeny;
					$motd_diff -= .@motd_zeny;
					
					if ($motd_zeny >= .motd_td) {
						$motd_zeny = 0;	
						announce ""+.npc$+": We reached the target donation to repick the monster of the day!",bc_all,0xFF6060;					
						// Up to you whether you want to add an extra hour or not, as otherwise the event will be below 48 hours.
						goto OnAtcommand;		
					}
			}	
		case 2:
			end;
	}
		
	end;

OnInit:
.motd_td = 50000;
$motd_diff = .motd_td - $motd_zeny; 			//Difference between target funds and balance

bindatcmd "motd",strnpcinfo(0)+"::OnCheck";
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;

bindatcmd "repickmotd",strnpcinfo(3)+"::OnAtcommand",20,99;
if($MobType!=0) { end; }
OnClock0000:
set .RandomArray,rand(0,9);
if(.RandomArray==0) { setarray .MobTypeArray[0],1001,1002,1004,1005,1007,1008,1009,1010,1011,1012,1013,1014,1015,1016,1018,1019,1020,1023,1024,1025,1026,1028,1029,1030,1031,1032,1033,1034,1035,1036,1037,1040,1041,1042,1044,1045,1047,1048; }
if(.RandomArray==1) { setarray .MobTypeArray[0],1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1076,1077,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1099; }
if(.RandomArray==2) { setarray .MobTypeArray[0],1100,1101,1102,1103,1104,1105,1106,1107,1108,1109,1110,1111,1113,1114,1116,1117,1118,1119,1121,1122,1123,1124,1125,1126,1127,1128,1129,1130,1131,1132,1133,1134,1135,1138,1139,1140,1141,1143; }
if(.RandomArray==3) { setarray .MobTypeArray[0],1144,1145,1146,1148,1149,1151,1152,1153,1154,1155,1156,1158,1160,1161,1163,1164,1165,1166,1167,1169,1170,1174,1175,1176,1177,1178,1179,1180,1182,1185,1186,1188,1189,1191,1192,1193,1194,1195; }
if(.RandomArray==4) { setarray .MobTypeArray[0],1196,1197,1199,1200,1201,1202,1203,1204,1205,1206,1207,1208,1209,1211,1212,1213,1214,1215,1216,1219,1242,1243,1245,1246,1248,1249,1250,1253,1254,1255,1256,1257,1258,1259,1260,1261,1262,1263; }
if(.RandomArray==5) { setarray .MobTypeArray[0],1264,1265,1266,1267,1268,1269,1270,1271,1273,1274,1275,1276,1277,1278,1279,1280,1281,1282,1283,1289,1290,1291,1292,1293,1294,1295,1296,1297,1298,1299,1300,1301,1302,1303,1304,1305,1306,1307; }
if(.RandomArray==6) { setarray .MobTypeArray[0],1308,1309,1310,1311,1313,1314,1315,1316,1317,1318,1319,1320,1321,1322,1323,1365,1366,1367,1368,1369,1370,1371,1372,1374,1375,1376,1377,1378,1379,1380,1381,1382,1383,1384,1385,1386,1387,1390; }
if(.RandomArray==7) { setarray .MobTypeArray[0],1391,1392,1400,1401,1402,1403,1404,1405,1406,1408,1409,1410,1412,1413,1415,1416,1417,1493,1494,1495,1497,1498,1499,1500,1503,1504,1505,1506,1507,1508,1509,1510,1512,1513,1514,1515,1516,1517; }
if(.RandomArray==8) { setarray .MobTypeArray[0],1519,1520,1582,1584,1586,1587,1613,1614,1615,1616,1617,1618,1619,1620,1621,1622,1627,1628,1629,1631,1632,1633,1664,1665,1666,1667,1668,1669,1670,1671,1672,1673,1675,1676,1677,1678,1679,1680; }
if(.RandomArray==9) { setarray .MobTypeArray[0],1681,1682,1686,1687,1692,1693,1694,1695,1696,1699,1703,1713,1714,1715,1717,1718,1736,1737,1738,1752,1753,1754,1755,1769,1770,1772,1773,1774,1775,1776,1777,1778,1780,1781,1782,1783,1784,1789; }
set $MobType,.MobTypeArray[rand(0,37)];
announce "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s ["+$MobType+"] today!",0;
//set $MonsterName$,getmonsterinfo($MobType,0);
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;
end;

OnCheck:
dispbottom "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!",0xFFFF00;
end;


OnNPCKillEvent:
	if(killedrid!=$MobType) { end; }
	dispbottom "MOTD Experience Gained Base:"+strmobinfo(6,killedrid)+" Job:"+strmobinfo(7,killedrid)+"";
	set BaseExp,(BaseExp+strmobinfo(6,killedrid));
	set JobExp,(JobExp+strmobinfo(7,killedrid));
	end;

OnAtcommand:
if(getgmlevel()<99) { dispbottom "You do not have permission to use this command."; end; }
set .RandomArray,rand(0,9);
if(.RandomArray==0) { setarray .MobTypeArray[0],1001,1002,1004,1005,1007,1008,1009,1010,1011,1012,1013,1014,1015,1016,1018,1019,1020,1023,1024,1025,1026,1028,1029,1030,1031,1032,1033,1034,1035,1036,1037,1040,1041,1042,1044,1045,1047,1048; }
if(.RandomArray==1) { setarray .MobTypeArray[0],1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1076,1077,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1099; }
if(.RandomArray==2) { setarray .MobTypeArray[0],1100,1101,1102,1103,1104,1105,1106,1107,1108,1109,1110,1111,1113,1114,1116,1117,1118,1119,1121,1122,1123,1124,1125,1126,1127,1128,1129,1130,1131,1132,1133,1134,1135,1138,1139,1140,1141,1143; }
if(.RandomArray==3) { setarray .MobTypeArray[0],1144,1145,1146,1148,1149,1151,1152,1153,1154,1155,1156,1158,1160,1161,1163,1164,1165,1166,1167,1169,1170,1174,1175,1176,1177,1178,1179,1180,1182,1185,1186,1188,1189,1191,1192,1193,1194,1195; }
if(.RandomArray==4) { setarray .MobTypeArray[0],1196,1197,1199,1200,1201,1202,1203,1204,1205,1206,1207,1208,1209,1211,1212,1213,1214,1215,1216,1219,1242,1243,1245,1246,1248,1249,1250,1253,1254,1255,1256,1257,1258,1259,1260,1261,1262,1263; }
if(.RandomArray==5) { setarray .MobTypeArray[0],1264,1265,1266,1267,1268,1269,1270,1271,1273,1274,1275,1276,1277,1278,1279,1280,1281,1282,1283,1289,1290,1291,1292,1293,1294,1295,1296,1297,1298,1299,1300,1301,1302,1303,1304,1305,1306,1307; }
if(.RandomArray==6) { setarray .MobTypeArray[0],1308,1309,1310,1311,1313,1314,1315,1316,1317,1318,1319,1320,1321,1322,1323,1365,1366,1367,1368,1369,1370,1371,1372,1374,1375,1376,1377,1378,1379,1380,1381,1382,1383,1384,1385,1386,1387,1390; }
if(.RandomArray==7) { setarray .MobTypeArray[0],1391,1392,1400,1401,1402,1403,1404,1405,1406,1408,1409,1410,1412,1413,1415,1416,1417,1493,1494,1495,1497,1498,1499,1500,1503,1504,1505,1506,1507,1508,1509,1510,1512,1513,1514,1515,1516,1517; }
if(.RandomArray==8) { setarray .MobTypeArray[0],1519,1520,1582,1584,1586,1587,1613,1614,1615,1616,1617,1618,1619,1620,1621,1622,1627,1628,1629,1631,1632,1633,1664,1665,1666,1667,1668,1669,1670,1671,1672,1673,1675,1676,1677,1678,1679,1680; }
if(.RandomArray==9) { setarray .MobTypeArray[0],1681,1682,1686,1687,1692,1693,1694,1695,1696,1699,1703,1713,1714,1715,1717,1718,1736,1737,1738,1752,1753,1754,1755,1769,1770,1772,1773,1774,1775,1776,1777,1778,1780,1781,1782,1783,1784,1789; }
set $MobType,.MobTypeArray[rand(0,37)];
announce "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s ["+$MobType+"] today!",0;
//set $MonsterName$,getmonsterinfo($MobType,0);
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;
end;

OnPCLoginEvent:
if (#pcloginflag&128) end;
	dispbottom "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!",0xFFFF00;
	end;
}

 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2346
  • Joined:  10/28/11
  • Last Seen:  

when player try to donate, add this validation

if (#motd_daily_limit == gettime(DT_YYYYMMDD)) {
	mes "[Monster Of The Day]";
	mes "You have already donated today. Come back again tomorrow.";
	close;
}		

when they success donate, add this

mes "[Monster Of The Day]";
mes "Zeny has succesfully transfered.";
Zeny -= .@motd_zeny;
$motd_zeny += .@motd_zeny;
$motd_diff -= .@motd_zeny;
#motd_daily_limit = gettime(DT_YYYYMMDD);        // <----- THIS LINE

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  241
  • Reputation:   18
  • Joined:  06/04/14
  • Last Seen:  

On 8/9/2021 at 9:39 PM, Origami said:

Hi ! I modified a script that I got from rathena called Monster of the day (credits to the author) and added a donation system that will allow players to donate certain amount of zeny to trigger the Repick mode .. My problem is .. How will I make one player to vote once every day only to avoid abuse ?? and I need to add a timer cooldown so players who didnt donate will not be able to cast donation once the repick has done on the same day .. 

//**********************************************************************************
// ____                    _                                            _   _  ____ 
//|  _ \ ___   ___   ____ | |  ___   ____   ___   ___   __  ___   _  _ | |_| |/ __ |
//| |__// _ \ / _ \ |  _ \| | / _ \ |  _ \ / _ \ /  _| / _)/ _ \ | \| ||___  |\__  |
//| |  |  __/ ||_|| | |__/| ||  __/ | |__/|  __/ | |  _\ \ ||_|| | \\ |    | |   | |
//|_|___\___|_\___/_| |___|_|_\___|_| |____\___|_|_|_(___/ \___/_|_|\_|____|_|___|_|
//------------------|_|-------------|_|---------------------------------------------
//**********************************************************************************
//===== rAthena Script =============================================================
//= Monster Of The Day
//===== By: ========================================================================
//= Peopleperson49 (Eddie) - [email protected]
//===== Start Date: ================================================================
//= 20NOV2011
//===== Current Version: ===========================================================
//= 1.4
//===== Compatible With: ===========================================================
//= rAthena SVN
//===== Description: ===============================================================
//= Another Monster Of The Day script. I made this one from scratch to be very
//=	simple and work automatically. Uses almost the full list of monsters from
//=	the mob_branch. I included the dispbottom here when players login, but I
//=	actually perfer to use a login script with this in it.
//===== Version Control: ===========================================================
//= 1.0 First Version.
//= 1.1	Broke .MobTypeArray[0] into ten seperate arrays to allow full list of mobs
//=	to be used without overflowing the array. Before I had to limit the number
//=	of mobs in an array to around 100 or I would randomly get an error from it.
//= 1.2	Modified script to not change mobs if scripts are reloaded. Will set mob if
//=	not already set on OnInit.
//= 1.3 Changed getexp to BaseExp.
//= 1.4 Added bindatcmd to allow GM to repick the MOTD.
//===== Additional Comments:========================================================
//= 
//==================================================================================
//-	script	MOTD#RoUG	-1,{
//prontera,158,190,4	script	Monster Of The Day	844,{
prontera,158,190,4	script	Monster Spirit	802 ,{
	mes "[Monster Of The Day]";
	mes "You will earn twice the EXP from killing "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!";
	next;
	mes "[Monster Of The Day]";
	mes "You can donate on our Monster Control Department if you wish to ramdomly change the MOTD.";
	switch(select("Donate ["+callfunc("F_InsertComma",$motd_zeny) + "/"+callfunc("F_InsertComma",.motd_td)+"].","Nevermind.")) {
		case 1:
	Change_Amount:		
			mes "[Monster Of The Day]";
			mes "Please input desired amount.";
			next;
			input .@motd_zeny;
			if (.@motd_zeny < 1) {
				mes "[Monster Of The Day]";
				mes "Input number greater than 0.";
				end;		
			}	
			mes "[Monster Of The Day]";
			mes "Please confirm Zeny transfer.";
			next;
			switch(select("Change Amount:Confirm")) {
				case 1:
					.@motd_zeny = 0;
					next;
					goto Change_Amount;
					end;
				case 2:
					if (Zeny < .@motd_zeny) {
						mes "[Monster Of The Day]";
						mes "Sorry, but you don't have enough";
						mes "zeny to donate.";
						end;
					}
					if (.@motd_zeny > $motd_diff) {
						mes "[Monster Of The Day]";
						mes "The amount you entered will exceed on remaining balance.";
						mes "Remaining Balance: "+callfunc("F_InsertComma",$motd_diff)+" Zeny";
						mes "^ff0000*Please input exact amount next time*.";
						end;
					}	
					if (.@motd_zeny == $motd_diff) {
						goto Initiate_MOTD;
						end;
					}
					Initiate_MOTD:	
					mes "[Monster Of The Day]";
					mes "Zeny has succesfully transfered.";
					Zeny -= .@motd_zeny;
					$motd_zeny += .@motd_zeny;
					$motd_diff -= .@motd_zeny;
					
					if ($motd_zeny >= .motd_td) {
						$motd_zeny = 0;	
						announce ""+.npc$+": We reached the target donation to repick the monster of the day!",bc_all,0xFF6060;					
						// Up to you whether you want to add an extra hour or not, as otherwise the event will be below 48 hours.
						goto OnAtcommand;		
					}
			}	
		case 2:
			end;
	}
		
	end;

OnInit:
.motd_td = 50000;
$motd_diff = .motd_td - $motd_zeny; 			//Difference between target funds and balance

bindatcmd "motd",strnpcinfo(0)+"::OnCheck";
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;

bindatcmd "repickmotd",strnpcinfo(3)+"::OnAtcommand",20,99;
if($MobType!=0) { end; }
OnClock0000:
set .RandomArray,rand(0,9);
if(.RandomArray==0) { setarray .MobTypeArray[0],1001,1002,1004,1005,1007,1008,1009,1010,1011,1012,1013,1014,1015,1016,1018,1019,1020,1023,1024,1025,1026,1028,1029,1030,1031,1032,1033,1034,1035,1036,1037,1040,1041,1042,1044,1045,1047,1048; }
if(.RandomArray==1) { setarray .MobTypeArray[0],1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1076,1077,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1099; }
if(.RandomArray==2) { setarray .MobTypeArray[0],1100,1101,1102,1103,1104,1105,1106,1107,1108,1109,1110,1111,1113,1114,1116,1117,1118,1119,1121,1122,1123,1124,1125,1126,1127,1128,1129,1130,1131,1132,1133,1134,1135,1138,1139,1140,1141,1143; }
if(.RandomArray==3) { setarray .MobTypeArray[0],1144,1145,1146,1148,1149,1151,1152,1153,1154,1155,1156,1158,1160,1161,1163,1164,1165,1166,1167,1169,1170,1174,1175,1176,1177,1178,1179,1180,1182,1185,1186,1188,1189,1191,1192,1193,1194,1195; }
if(.RandomArray==4) { setarray .MobTypeArray[0],1196,1197,1199,1200,1201,1202,1203,1204,1205,1206,1207,1208,1209,1211,1212,1213,1214,1215,1216,1219,1242,1243,1245,1246,1248,1249,1250,1253,1254,1255,1256,1257,1258,1259,1260,1261,1262,1263; }
if(.RandomArray==5) { setarray .MobTypeArray[0],1264,1265,1266,1267,1268,1269,1270,1271,1273,1274,1275,1276,1277,1278,1279,1280,1281,1282,1283,1289,1290,1291,1292,1293,1294,1295,1296,1297,1298,1299,1300,1301,1302,1303,1304,1305,1306,1307; }
if(.RandomArray==6) { setarray .MobTypeArray[0],1308,1309,1310,1311,1313,1314,1315,1316,1317,1318,1319,1320,1321,1322,1323,1365,1366,1367,1368,1369,1370,1371,1372,1374,1375,1376,1377,1378,1379,1380,1381,1382,1383,1384,1385,1386,1387,1390; }
if(.RandomArray==7) { setarray .MobTypeArray[0],1391,1392,1400,1401,1402,1403,1404,1405,1406,1408,1409,1410,1412,1413,1415,1416,1417,1493,1494,1495,1497,1498,1499,1500,1503,1504,1505,1506,1507,1508,1509,1510,1512,1513,1514,1515,1516,1517; }
if(.RandomArray==8) { setarray .MobTypeArray[0],1519,1520,1582,1584,1586,1587,1613,1614,1615,1616,1617,1618,1619,1620,1621,1622,1627,1628,1629,1631,1632,1633,1664,1665,1666,1667,1668,1669,1670,1671,1672,1673,1675,1676,1677,1678,1679,1680; }
if(.RandomArray==9) { setarray .MobTypeArray[0],1681,1682,1686,1687,1692,1693,1694,1695,1696,1699,1703,1713,1714,1715,1717,1718,1736,1737,1738,1752,1753,1754,1755,1769,1770,1772,1773,1774,1775,1776,1777,1778,1780,1781,1782,1783,1784,1789; }
set $MobType,.MobTypeArray[rand(0,37)];
announce "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s ["+$MobType+"] today!",0;
//set $MonsterName$,getmonsterinfo($MobType,0);
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;
end;

OnCheck:
dispbottom "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!",0xFFFF00;
end;


OnNPCKillEvent:
	if(killedrid!=$MobType) { end; }
	dispbottom "MOTD Experience Gained Base:"+strmobinfo(6,killedrid)+" Job:"+strmobinfo(7,killedrid)+"";
	set BaseExp,(BaseExp+strmobinfo(6,killedrid));
	set JobExp,(JobExp+strmobinfo(7,killedrid));
	end;

OnAtcommand:
if(getgmlevel()<99) { dispbottom "You do not have permission to use this command."; end; }
set .RandomArray,rand(0,9);
if(.RandomArray==0) { setarray .MobTypeArray[0],1001,1002,1004,1005,1007,1008,1009,1010,1011,1012,1013,1014,1015,1016,1018,1019,1020,1023,1024,1025,1026,1028,1029,1030,1031,1032,1033,1034,1035,1036,1037,1040,1041,1042,1044,1045,1047,1048; }
if(.RandomArray==1) { setarray .MobTypeArray[0],1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1076,1077,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1099; }
if(.RandomArray==2) { setarray .MobTypeArray[0],1100,1101,1102,1103,1104,1105,1106,1107,1108,1109,1110,1111,1113,1114,1116,1117,1118,1119,1121,1122,1123,1124,1125,1126,1127,1128,1129,1130,1131,1132,1133,1134,1135,1138,1139,1140,1141,1143; }
if(.RandomArray==3) { setarray .MobTypeArray[0],1144,1145,1146,1148,1149,1151,1152,1153,1154,1155,1156,1158,1160,1161,1163,1164,1165,1166,1167,1169,1170,1174,1175,1176,1177,1178,1179,1180,1182,1185,1186,1188,1189,1191,1192,1193,1194,1195; }
if(.RandomArray==4) { setarray .MobTypeArray[0],1196,1197,1199,1200,1201,1202,1203,1204,1205,1206,1207,1208,1209,1211,1212,1213,1214,1215,1216,1219,1242,1243,1245,1246,1248,1249,1250,1253,1254,1255,1256,1257,1258,1259,1260,1261,1262,1263; }
if(.RandomArray==5) { setarray .MobTypeArray[0],1264,1265,1266,1267,1268,1269,1270,1271,1273,1274,1275,1276,1277,1278,1279,1280,1281,1282,1283,1289,1290,1291,1292,1293,1294,1295,1296,1297,1298,1299,1300,1301,1302,1303,1304,1305,1306,1307; }
if(.RandomArray==6) { setarray .MobTypeArray[0],1308,1309,1310,1311,1313,1314,1315,1316,1317,1318,1319,1320,1321,1322,1323,1365,1366,1367,1368,1369,1370,1371,1372,1374,1375,1376,1377,1378,1379,1380,1381,1382,1383,1384,1385,1386,1387,1390; }
if(.RandomArray==7) { setarray .MobTypeArray[0],1391,1392,1400,1401,1402,1403,1404,1405,1406,1408,1409,1410,1412,1413,1415,1416,1417,1493,1494,1495,1497,1498,1499,1500,1503,1504,1505,1506,1507,1508,1509,1510,1512,1513,1514,1515,1516,1517; }
if(.RandomArray==8) { setarray .MobTypeArray[0],1519,1520,1582,1584,1586,1587,1613,1614,1615,1616,1617,1618,1619,1620,1621,1622,1627,1628,1629,1631,1632,1633,1664,1665,1666,1667,1668,1669,1670,1671,1672,1673,1675,1676,1677,1678,1679,1680; }
if(.RandomArray==9) { setarray .MobTypeArray[0],1681,1682,1686,1687,1692,1693,1694,1695,1696,1699,1703,1713,1714,1715,1717,1718,1736,1737,1738,1752,1753,1754,1755,1769,1770,1772,1773,1774,1775,1776,1777,1778,1780,1781,1782,1783,1784,1789; }
set $MobType,.MobTypeArray[rand(0,37)];
announce "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s ["+$MobType+"] today!",0;
//set $MonsterName$,getmonsterinfo($MobType,0);
//setnpcdisplay "Monster Of The Day",$MonsterName$,$MobType;
end;

OnPCLoginEvent:
if (#pcloginflag&128) end;
	dispbottom "[Monster Of The Day]: You will earn twice the EXP from hunting "+getmonsterinfo($MobType,0)+"s [^0000ff"+$MobType+"^000000] today!",0xFFFF00;
	end;
}

 

Hi Mate, 

You can check this out.  

 

Link to comment
Share on other sites

Join the conversation

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

Guest
Answer this question...

×   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.

×
×
  • Create New...