Jump to content

FatalEror

Members
  • Posts

    67
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by FatalEror

  1. Here: void clif_parse_Broadcast(int fd, struct map_session_data* sd) { char* msg = (char*)RFIFOP(fd,4); char output[CHAT_SIZE_MAX]; char title[25]; // 25 should be enough.. char lv_gm, len; int lv, color; lv_gm = pc_isGM(sd); if( battle_config.atc_gmonly && !lv_gm ) return; if( lv_gm < (lv=get_atcommand_level(atcommand_broadcast)) ) return; if (lv_gm >= 20 && lv_gm < 40) { color = 0xFF0000; strcpy(title, "Support"); } else if (lv_gm >= 40 && lv_gm < 60) { color = 0x800000; strcpy(title, "Event GM"); } else if (lv_gm >= 60 && lv_gm < 80) { color = 0x4B0082; strcpy(title, "Sub GM"); } else if (lv_gm >= 80 && lv_gm < 99) { color = 0x0000FF; strcpy(title, "GM"); } else if (lv_gm == 99) { color = 0xFF0000; strcpy(title, "Administrator"); } sprintf(output, "[%s] %s", title, msg); // as the length varies depending on the command used, just block unreasonably long strings len = mes_len_check(output, strlen(output) + 1, CHAT_SIZE_MAX); intif_broadcast2(output, len, color, 0x190, 12, 0, 0); if(log_config.gm && lv >= log_config.gm) { char logmsg[CHAT_SIZE_MAX+4]; sprintf(logmsg, "/b %s", msg); log_atcommand(sd, logmsg); } } And yeah, stop bumping like that
  2. @Judas here: http://www.megaupload.com/?d=0A44U6S1
  3. I've extracted it with 7-Zip, and got no error... And btw, it's 2011-03-15aRagexeRE i589.photobucket.com/albums/ss337/ZeroBytes/upload.png
  4. Copy that luac5.0.2.exe in your "Lua Files" folder Create a batch file(eg:convert.bat) Copy paste this to convert.bat and save it... @echo off for /f "usebackq tokens=*" %%a in (`dir /b/s/a:d`) do ( for %%l in (%%~nxa\*.lua) do ( luac5.0.2 -o %%~nxa\%%~nl.lub %%l ) ) for %%l in (*.lua) do ( luac5.0.2 -o %%~nl.lub %%l ) pause Run convert.bat
  5. ../db/item_noequip.txt // The equipment/items/cards restriction file // here you define which items may not be used at PvP / GvG // format: <item id>,<mode> // mode // 1 - restricted in normal maps // 2 - restricted in PVP // 4 - restricted in GVG // 8 - restricted in Battlegrounds // Restricted zones - they're configured by 'restricted <number>' mapflag // 32 - restricted in zone 1 // 64 - restricted in zone 2 // 128 - restricted in zone 3 // 256 - restricted in zone 4 // 512 - restricted in zone 5 // 1024 - restricted in zone 6 // 2048 - restricted in zone 7 // 2 - restricted in PVP // 4 - restricted in GVG So it should be: ItemID, 6
  6. Long Attack Resist: sd->long_attack_def_rate = val; // 100 = 100% ; Stun Resist: sd->reseff[sC_STUN] = val; // 10000 = 100%
  7. I think this is the problem: sprintf(temp,"You sold the goods for %dz.", (int)z);
  8. My bad... Add this line in ..db/const.txt below bHealPower2 breakhplimit 1100 And apply this patch: breakhplimit.diff
  9. Just search this line in status.c if( status->max_hp > (unsigned int)battle_config.max_hp ) change into: if( status->max_hp > (unsigned int)battle_config.max_hp && !pc_readglobalreg(sd, "breakhplimit") ) max_hp type is unsigned int, so it should support max hp until 4294967295...
  10. Index: atcommand.c =================================================================== --- atcommand.c (revision 14998) +++ atcommand.c (working copy) @@ -47,6 +47,7 @@ // extern variables char atcommand_symbol = '@'; // first char of the commands +char atcommand_string[] = "cmd"; char charcommand_symbol = '#'; char* msg_table[MAX_MSG]; // Server messages (0-499 reserved for GM commands, 500-999 reserved for others) @@ -8948,7 +8949,7 @@ message += 3; //Should display as a normal message - if ( *message != atcommand_symbol && *message != charcommand_symbol ) + if ( *message != atcommand_symbol && *message != charcommand_symbol && (strncmp(message, atcommand_string, strlen(atcommand_string)) != 0 || message[strlen(atcommand_string)] != ' ')) return false; // type value 0 = server invoked: bypass restrictions @@ -9012,6 +9013,12 @@ //pass through the rest of the code compatible with both symbols sprintf(atcmd_msg, "%s", message); } + + if (strncmp(message, atcommand_string, strlen(atcommand_string)) == 0) { + sprintf(atcmd_msg, "%s", message); + memmove(atcmd_msg, atcmd_msg+strlen(atcommand_string), strlen(atcmd_msg)); + atcmd_msg[0] = atcommand_symbol; + } //Clearing these to be used once more. memset(command, '\0', sizeof(command)); command_string.diff
×
×
  • Create New...