Просмотр исходного кода

Compatibility with the latest Tera-Proxy programs

TeraProxy лет назад: 8
Родитель
Сommit
0de9314c8a
2 измененных файлов с 9 добавлено и 5 удалено
  1. 5 3
      README.md
  2. 4 2
      index.js

+ 5 - 3
README.md

@@ -2,14 +2,14 @@
 Working on NA Counterpunch patch with the latest https://github.com/meishuu/tera-data.  
 Please always keep your tera-data up-to-date.  
 Other regions will work if the opcodes are mapped but I personally only test modules on NA.  
-
+  
 If you enjoy my work and wish to support future development, feel free to drop me a small donation: [![Donate](https://www.paypalobjects.com/webstatic/en_US/i/buttons/PP_logo_h_100x26.png)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=A3KBZUCSEQ5RJ&lc=US&item_name=TeraProxy&curency_code=USD&no_note=1&no_shipping=1&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted)
   
 # AFKer
 A tera-proxy module that prevents you from getting back to the character select screen. 
 This has the side effect that the server's AFK check will not kick you out of the game.  
   
-## Usage  
+## Usage
 The script is enabled by default and will prevent you from getting logged out when you are standing still for an hour.  
 Simply moving your character will make you able to go back to character selection and reset the 1 hour timer.  
   
@@ -23,6 +23,8 @@ The following commands are supported:
 Whatever you send to the proxy chat in game is intercepted client-side. The chat is NOT sent to the server.  
   
 ## Changelog
+### 1.2.2
+* [*] Updated hook versions for compatibility with the latest Tera-Proxy programs
 ### 1.2.1
 * [*] Some code cleanup
 * [*] Full conversion to Pinkie Pie's command module
@@ -33,4 +35,4 @@ Whatever you send to the proxy chat in game is intercepted client-side. The chat
 ### 1.1.0
 * [+] Added !afk command to toggle between "on" and "off" in non-whisper chats
 ### 1.0.0
-* [*] Initial Release
+* [*] Initial Release

+ 4 - 2
index.js

@@ -1,3 +1,5 @@
+// Version 1.2.2
+
 const Command = require('command')
 
 module.exports = function AFKer(dispatch) {
@@ -5,13 +7,13 @@ module.exports = function AFKer(dispatch) {
 		afk = false,
 		afkCheck = null
 	
-	dispatch.hook('C_PLAYER_LOCATION', 1, () => {
+	dispatch.hook('C_PLAYER_LOCATION', 'raw', () => {
 		clearTimeout(afkCheck)
 		afk = false
 		afkCheck = setTimeout(() => {afk = true}, 3600000) // 1 hour
 	})
 
-	dispatch.hook('C_RETURN_TO_LOBBY', 1, () => {
+	dispatch.hook('C_RETURN_TO_LOBBY', 'raw', () => {
 		if (enabled && afk) return false // Prevents you from being automatically logged out while AFK
 	})