Browse Source

update 1.42

teralove 8 years ago
parent
commit
3fd866bd26
2 changed files with 14 additions and 0 deletions
  1. 2 0
      README.MD
  2. 12 0
      index.js

+ 2 - 0
README.MD

@@ -24,6 +24,8 @@ tera-proxy module that skips lockons and instantly heals and cleanses party memb
 ## Changelog
 <details>
 
+    1.42
+    - Added S_USER_LOCATION_IN_ACTION hook. (Fixes issue with brawlers not getting lockons)
     1.41
     - Updated protocol versions.
     - Set max distance to 32m

+ 12 - 0
index.js

@@ -5,6 +5,7 @@
 // - C_PLAYER_LOCATION
 // - S_SPAWN_USER
 // - S_USER_LOCATION
+// - S_USER_LOCATION_IN_ACTION
 // - S_PARTY_MEMBER_CHANGE_HP
 // - C_START_SKILL
 // - S_CREST_INFO
@@ -82,6 +83,17 @@ module.exports = function AutoHeal(dispatch) {
         }
     })
     
+    dispatch.hook('S_USER_LOCATION_IN_ACTION', 2, (event) => {
+        if (partyMembers.length != 0) {
+            for (let i = 0; i < partyMembers.length; i++) {
+                if (partyMembers[i].gameId.equals(event.gameId)) {
+                    partyMembers[i].loc = event.loc;
+                    return;
+                }
+            }
+        }
+    })
+    
     dispatch.hook('S_SPAWN_USER', 13, (event) => {
         if (partyMembers.length != 0) {
             for (let i = 0; i < partyMembers.length; i++) {