Jump to content

chmuun

Members
  • Posts

    41
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

chmuun's Achievements

Advanced Member

Advanced Member (3/3)

0

Reputation

  1. Hello, Guys I have a really annoying problem with Data Execution Prevention with mangos. After every few hours... I get a message about DEP and mangos gets stuck and doesnt even restarts. I tried turning it off... But it says that it can be turned off for mangosd.exe Please anyone tell me how to fix this Thank you
  2. chmuun

    Soap?!

    You'll have access to all commands from console and some commands of game too I think.
  3. FragFrog Thanks for the tips but Only errors are logged and if the command it correct... there will be no logs... Logs are really important... maybe some one is using a variable in a function... He won't even know if there are errors try and catch is added because Soap commands creates a FATAL error if there is even one problem and on development sites it is better to give a custom error message than a auto php error message with all command info and connection info ... I've fixed the few errors and i've also removed the _ from the function... i only added it for my php class
  4. Thanks ... The easiest way is to make a function in Chat.cpp and Chat.h to run the protected function
  5. Can you also tell me how to Send a global announcement I tried ChatHandler chatGlobal = ChatHandler(); char victimglobalmessage[1024]; snprintf(victimglobalmessage, 1024, PVP_COLOR"%s lost a %u kill, killing spree by %s! Extra [%s]x5 is rewarded!", pvpVictim->GetName(), OldVictimKillingSpree*10, pvpPlayer->GetName(), "Badge of Justice"); chatGlobal.SendGlobalSysMessage(victimglobalmessage); But it gives an error: Error 2 error C2248: 'ChatHandler::SendGlobalSysMessage' : cannot access protected member declared in class 'ChatHandler' e:\\Aaam\\Source Code\\src\\game\\Player.cpp 20371
  6. Dude this thing is risky. Maybe people who don't use custom scripts or patches will find it useful. But great effort though Can you make an auto SQL update maker lyk ... Input start revision then all the files are executed after the "start" revision Its a real pain to update manually
  7. Hey guys, I've been getting a lot of help from the community so I thought why don't i help you guys too as a return. I've made a function for my custom website but I've changed this function to work normally without any libraries Just make sure you have PHP 5.0.1 or above $settings = array( "IP" => "127.0.0.1", //Your server's IP address "PORT" => 7878, //7878 is the default Port "USERNAME" => "USERNAME", //Must be in UPPERCASE in both, Database AND This file "PASSWORD" => "Password", //Password of the account give above "DEBUG" => true, //If "True" then errors will be printed in html and if false ... They'll only be printed in file ); function ExecuteSoapCommand($command) { global $settings; //Setup SOAP Client $client = new SoapClient(NULL, array( "location" => "http://".$settings['IP'].":".$settings['PORT']."/", "uri" => "urn:MaNGOS", "style" => SOAP_RPC, "login" => $settings['USERNAME'], "password" => $settings['PASSWORD'], )); try //Try to execute function { $result = $client->executeCommand(new SoapParam($command, "command")); } catch(Exception $e) //Don't give fatal error if there is a problem { LogSoapError($e); return array('sent'=>false, 'message'=>$e->getMessage()); } return array('sent'=>true, 'message'=>$result); } function LogSoapError($e) { global $settings; $date = date('D d/m/Y'); $time = date('G:i:s'); $ip = $_SERVER['REMOTE_ADDR']; $error = $e->getMessage(); $errorcode = $e->getCode(); $file = $e->getFile(); $line = $e->getLine(); $errorstring = "\\r\\n |----------------------------SOAP Command Error----------------------------------- |Date: $date, Time: $time, From: $ip |Where: $file(Line: $line) Error Code: $errorcode |Error: $error |----------------------------SOAP Command Error-----------------------------------"; $f = fopen("soaperror.log", "a+"); fwrite($f, $errorstring); fclose($f); //IF $debug == true the error will be shown in HTML if($settings['DEBUG']) { print $errorstring; } } I haven't tested the code yet because my server is down because VRTServers sucks really hard. Never get a server from them, lame customer support. Make sure you edit the $settings and the "DEBUG" is for showing the error and what kinda error it is.. in full details Here is an example of how to use this script $soap_command = ExecuteSoapCommand("server info"); if($soap_command['sent']) { print $soap_command['message']; //This is tell you the server info } else { print "There was an error while executing SOAP command. Please contact an administrator."; } Errors will be logged in file "soaperror.log" If you have an problems just reply Have Fun
  8. Why not use ScriptDev2? if u dont want useless scripts... u can remove it u know
  9. There are alot of custom npcs/objs/items here, also has TeleNPC but u might need to change a few things in it:
  10. Hi, Can someone please tell me how to check if some one is in group ... and i tried using this to check if the person's group is a raid group but it makes the server crash: if(pvpPlayer->GetGroup()->isRaidGroup()) { //If player is in a raid group } Thank you
  11. Hi, I have a crash dump... The crash is in player.cpp. its my own patch but i cant understand at which point is the server crashing... can crash dumps tell which line is bugged? Revision: * * 10155 * Date 9:7:2010. Time 19:23 //===================================================== *** Hardware *** Processor: Intel(R) Core(TM)2 Duo CPU E7500 @ 2.93GHz Number Of Processors: 1 Physical Memory: 2095608 KB (Available: 295264 KB) Commit Charge Limit: 4191216 KB *** Operation System *** Windows Vista or Windows Server 2008 Professional (Version 6.1, Build 7600) //===================================================== Exception code: C0000005 ACCESS_VIOLATION Fault address: 0056064A 01:0015F64A E:\\Aaam\\Core\\World Server\\mangosd.exe Registers: EAX:7F8C6080 EBX:74070090 ECX:00000000 EDX:00000000 ESI:00000021 EDI:008EC560 CS:EIP:001B:0056064A SS:ESP:0023:0B51AF00 EBP:0B51AF9C DS:0023 ES:0023 FS:003B GS:0000 Flags:00010246 Call stack: Address Frame Function SourceFile 0056064A 00000000 Player::RewardSinglePlayerAtKill+24A 00486F1F 00000000 Unit::DealDamage+D4F 00489C70 00000000 Unit::DealSpellDamage+180 00714925 00000000 Spell::DoAllEffectOnTarget+715 0071C2F5 00000000 Spell::handle_delayed+C5 00728F2B 00000000 SpellEvent::Execute+15B 00964C1C 00000000 EventProcessor::Update+EC 00484DBB 00000000 Unit::Update+3B 0051468C 00000000 Player::Update+EC 004DD52B 00000000 Map::Update+DB 006B4FC0 00000000 MapManager::Update+120 0063F5E6 00000000 World::Update+7A6 00457E7E 00000000 WorldRunnable::run+8E 008EC579 00000000 ACE_Based::Thread::ThreadTask+19 610B12C4 00000000 __WSAFDIsSet+FFFFFFFFFFFCC1EC 71C73433 00000000 _endthreadex+44 71C734C7 00000000 _endthreadex+D8 767D1174 00000000 BaseThreadInitThunk+12 77A2B495 00000000 RtlInitializeExceptionChain+63 77A2B468 00000000 RtlInitializeExceptionChain+36 Call stack: Address Frame Function SourceFile 77A164F4 00000000 KiFastSystemCallRet+0 767CF003 00000000 WaitForSingleObjectEx+43 767CEFB2 00000000 WaitForSingleObject+12 61069AC4 00000000 __WSAFDIsSet+FFFFFFFFFFF849EC 610D648A 00000000 __WSAFDIsSet+FFFFFFFFFFFF13B2 610D263F 00000000 __WSAFDIsSet+FFFFFFFFFFFED567 00668A3A 00000000 WorldSocketMgr::Wait+4A 74099D04 00000000 0000:00000000 74099D04 00000000 0000:00000000 6C696146 00000000
  12. Will this work Player * newVariable = ((Player*)UnitVariable);
  13. Hi, I've recently lost all my scripts... and i also forgot how to convert "Unit" to "Player" pointer. Please help Thanks
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use