Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 10/14/24 in all areas

  1. Allows you to send private messages to a player (char_id), you can use the char_id or a title as the sender. /** [Hyroshima] * whisper <CHAR_ID_TARGET>,<MESSAGE>,<CHAR_ID_SENDER/TITLE>}; * @return: 0 success, 1 target not found, 2 sender not found. **/ BUILDIN_FUNC(whisper){ map_session_data *ssd,*tsd; char message[70] = {0}; char wisp_title[NAME_LENGTH] = {0}; uint8 len = strlen(script_getstr(st,3)); if(!script_charid2sd(2,tsd)) { //Target not found / offline script_pushint(st,1); return SCRIPT_CMD_SUCCESS; } if(atoi(script_getstr(st,4))) { if(!script_charid2sd(4,ssd)) { //Sender not found. / offline script_pushint(st,2); return SCRIPT_CMD_SUCCESS; } else safestrncpy(wisp_title,ssd->status.name,NAME_LENGTH); } else safestrncpy(wisp_title,script_getstr(st,4),NAME_LENGTH); script_pushint(st,0); safestrncpy(message,script_getstr(st,3),len); clif_wis_message(tsd,wisp_title,message,len,0); return SCRIPT_CMD_SUCCESS; } BUILDIN_DEF(whisper, "is?"), //Hyroshima Example: *whisper 150001,"message test","Tester"; *whisper(150001,"message test",150002; A member had asked me if I would do it, I ended up doing it but then he had replied that he had already done it, so I am making available what I did.
    1 point
  2. Find OnInit and add these lines below it: setmapflag "guild_vs1", mf_loadevent; $@KoE_limit = 12; //how many guild members can participate Then add this anywhere: OnPCLoadMapEvent: if (strcharinfo(3) == "guild_vs1") { .@joined = getMapGuildUsers("guild_vs1",getcharid(2)); if (.@joined > $@KoE_limit) { dispbottom "Sorry. Your Guild has reached the limit of " + $@KoE_limit + " people on KoE."; dispbottom "Teleporting you out now."; warp "SavePoint",0,0; } } end; The OnPCLoadMapEvent will trigger when anyone enters the map, do a check on how many guild members are participating and then warp the player out if reached the limit. Find: if ( !getvariableofnpc( .start, "KoE" ) ) close; And add below it: .@joined = getMapGuildUsers("guild_vs1",getcharid(2)); if (.@joined >= $@KoE_limit) { clear; mes "[The King]"; mes "^FF0000Sorry. Your Guild has reached the limit of " + $@KoE_limit + " people on KoE.^000000"; close; } This will make the entrance NPC also do the same check.
    1 point
  3. - script sample -1,{ OnInit: setarray .map$, "prontera", "izlude"; .map_size = getarraysize(.map$); end; OnHour00: for (.@i = 0; .@i < .map_size; .@i++) { .@size = instance_list(.map$[.@i]); for (.@x = 0; .@x < .@size; .@x++) { instance_announce .@instance_list[.@x], "<SYSTEM> Instance are destroyed upon reached 12AM everyday.", bc_map; instance_destroy .@instance_list[.@x]); } } end; } required the Pull: 5112 mentioned above.
    1 point
  4. I think this will still trigger close function because of the end; and the close; is in the end of switch he need to remove it first. just a simple fix is this as i mention on my reply. This is what exact should be. guildhall,95,72,3 script Breaker Points Shop 512,{ query_sql("SELECT `count` FROM `breaker_ladder` WHERE `char_id` = "+ getcharid(0), .@count); cutin "woe_2020",2; mes "[ ^C6A518WoE Points Staff^000000 ]"; mes "Hey sir!"; mes " "; mes "Breaker Points: ^1DCE63 "+#EMPBREAKERPTS+" Points^000000 "; mes "Did you enjoy the WoE today?, Hows your day?"; next; switch(select("I want to check shop","I'm good thank you..")) { case 1: callshop "EmpBreakerShop", 4; mes "[ ^C6A518WoE Points Staff^000000 ]"; mes "Every and of the month the shop"; mes "Will have a new headgears manually"; mes "picked by the Players!"; mes " "; mes "^FF0000NOTE^000000: Please choose wisely"; break; case 2: mes "[ ^C6A518WoE Points Staff^000000 ]"; mes "Thats good to hear!"; close2; cutin "",255; end; break; } OnInit: // how much points gained per emp break? $@empbreakpoints = 1; query_sql("CREATE TABLE IF NOT EXISTS `breaker_ladder` (`char_id` int(11) unsigned NOT NULL, `count` int(11) NOT NULL DEFAULT '0', PRIMARY KEY ( `char_id` )) ENGINE=InnoDB"); } - pointshop EmpBreakerShop -1,#EMPBREAKERPTS,12202:1,12203:1,12207:1,12206:1,12205:1,12204:1,13517:1,14004:2 guildhall mapflag loadevent Thus always break; a statement on switch case because it will continues until end of function.
    1 point
  5. Mysterious, I think you're making confusion. His OnHour appears to be correct once it doesn't need minutes. But, I advice you Mr BrycE to use OnClock. OnClock0600: OnClock1000: OnClock1400: OnClock1800: OnClock2200: OnClock0200: So, you can set minutes if needed.
    1 point
×
×
  • Create New...