Changeset 58 for trunk/www/model/realm.php
- Timestamp:
- Aug 4, 2009, 7:21:15 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/www/model/realm.php
r57 r58 85 85 } 86 86 // Lookup nearest database with full import 87 $DbResult = $this->Database->query('SELECT * FROM `Database` WHERE (`Emulator` <> 0) AND (`Revision` <= '.$this-> Server['Database']['Revision'].') AND (`SourceFileName` <> "") ORDER BY `Revision` DESC');87 $DbResult = $this->Database->query('SELECT * FROM `Database` WHERE (`Emulator` <> 0) AND (`Revision` <= '.$this->Realm['Database']['Revision'].') AND (`SourceFileName` <> "") ORDER BY `Revision` DESC'); 88 88 $Database = $DbResult->fetch_assoc(); 89 89 … … 99 99 $this->Task->Add('Inicializace databáze', $CommandList); 100 100 101 if($Database['Id'] != $this-> Server['Database']['Id'])102 { 103 $NewDatabaseId = $this-> Server['Database']['Id'];104 $this-> Server['Database']['Id'] = $Database['Id'];101 if($Database['Id'] != $this->Data['Database']['Id']) 102 { 103 $NewDatabaseId = $this->Data['Database']['Id']; 104 $this->Data['Database']['Id'] = $Database['Id']; 105 105 $this->Update($NewDatabaseId, false, false); 106 106 } … … 221 221 $EmulatorConfig->ParameterList['WorldServerPort'] = $this->Data['NetworkPortWorldd']; 222 222 $EmulatorConfig->ParameterList['Motd'] = $this->Data['Motd']; 223 print_r($this->Data);224 223 $EmulatorConfig->ParameterList['DataDir'] = 'wowclient/'.$this->Data['Database']['Emulator']['Client']['Version']; 225 $EmulatorConfig->ParameterList['LogsDir'] = ' server/'.$this->Id.'/log';224 $EmulatorConfig->ParameterList['LogsDir'] = 'realm/'.$this->Id.'/log'; 226 225 $EmulatorConfig->ParameterList['LogLevel'] = 1; 227 226 $EmulatorConfig->ParameterList['PlayerLimit'] = $Config['MaxOnlinePlayerCountPerServer']; … … 261 260 'php www/shell.php RealmLock '.$this->Id, 262 261 ); 263 $DbResult = $this->Database->query('SELECT `Revision` FROM `Database` WHERE `Id` = '.$this-> Server['Database']['Id']);262 $DbResult = $this->Database->query('SELECT `Revision` FROM `Database` WHERE `Id` = '.$this->Data['Database']['Id']); 264 263 $DbRow = $DbResult->fetch_assoc(); 265 264 $DatabaseRevisionStart = $DbRow['Revision']; … … 308 307 { 309 308 $Output = array(); 310 if(isset($this-> Server['Database']['Emulator']['Id']))311 exec('ps -aux|grep "emulator/'.$this-> Server['Database']['Emulator']['Id'].'/bin/mangos-worldd -c realm/'.$this->Id.'/etc/mangosd.conf"| grep -v grep', $Output);309 if(isset($this->Data['Database']['Emulator']['Id'])) 310 exec('ps -aux|grep "emulator/'.$this->Data['Database']['Emulator']['Id'].'/bin/mangos-worldd -c realm/'.$this->Id.'/etc/mangosd.conf"| grep -v grep', $Output); 312 311 if(count($Output) > 0) 313 312 {
Note:
See TracChangeset
for help on using the changeset viewer.