-
Content Count
4 -
Joined
-
Last visited
-
Days Won
1
Posts posted by afonya
-
-
I can code it for you. Price depends on complexity (as in if you want any extra functionality apart from patching and tweak protection). Can provide with my work examples upon request. Although I have to say that patcher does not prevent users from tweaking their clients (maybe does from those who have no or very little experience with coding).
-
Gameserver can also be crashed by spamming apply to guild packets, but this applies only to gameserver containing ascaron. Open wpe, start recording, apply to guild, start sending packets and gameserver crashes within seconds.
-
<?php $host = "127.0.0.1, 3707"; $database = "GameDB"; $user = "game"; $pass = "Y87dc#$98"; $conn = new PDO("sqlsrv:server=$host ; Database = $database", $user, $pass); $query = "SELECT cha_name, job FROM character WHERE mem_addr > 0"; if ($conn) { $stmt = $conn->query($query); $fetch = $stmt->fetch(PDO::FETCH_ASSOC); if (is_array($fetch)) { echo "Имя игрока, профессия<br />"; while ($row = $stmt->fetch()) { echo $row['cha_name'].", ". $row['job']."<br />\n"; } } else { echo "Нет игроков в сети."; } } else { die("нет соединения."); } ?>
Стоит заметить, что job хранит id профессии, а не само название. Я так понимаю, должен быть какой-то дополнительный функционал, чтобы отобразить собственно название профессии.
- 1
-
-
I'm assuming split returns a list of table values? if so, you need to compare the opening time to the current server time. I'm unsure what would be the best and some real quality code, but pseudo code would be as follows:
Spoilerfunction IsPortalOpen(open_hour, close_minute) local time = os.date("*t") local current_hour, current_minute, current_second = time.hour, time.min, time.sec local last_min = close_minute - 1 local res = false local i = {3, 5, 7, 9 , 11, 13, 15, 17, 19, 21, 23} local j = {2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24} if open_hour % 2 ~= 0 then if open_hour == 1 then if current_minute <= last_min and current_second <= 59 then res = true end else for x, v in pairs(i) do if x == open_hour then if current_hour % open_hour == 0 then if current_minute <= last_min and current_second <= 59 then res = true end end end end end else for i, v in pairs(j) do if i == open_hour then if current_hour % open_hour == 0 then if current_minute <= last_min and current_second <= 59 then res = true end end end end end return res end //EntryMaps.Conf['garner2'] = {"2006/10/18/11/0", "0/1/0", "0/0/30", "0/0/45"} // Current time: 13:27 // print(IsPortalOpen(1, 30)) --returns true //EntryMaps.Conf['darkswamp'] = {"2006/10/18/11/0", "0/8/0", "0/0/50", "0/0/55"} // Current time: 16:42 // print(IsPortalOpen(8, 50)) --returns true // // Current time: 20:42 // print(IsPortalOpen(8, 50)) --returns false
- 1
setting up top website using zend
in Questions & Help
Posted · Report reply
depending on what variable is used, it has to be at the very least 'host' => $host, cause you wanna pass the variable to host, not the question marks.