用户工具

站点工具


waypoints-information

差别

这里会显示出您选择的修订版和当前版本之间的差别。

到此差别页面的链接

后一修订版
前一修订版
waypoints-information [2023/10/03 17:34] – 创建 adminwaypoints-information [2023/10/03 17:38] (当前版本) – [A few helpful SQL statements] admin
行 41: 行 41:
 Example creature GUID: 1234567, example path id: 123456700 Example creature GUID: 1234567, example path id: 123456700
  
-Create a macro 'wp1' with this command: +  * Create a macro 'wp1' with this command: 
-.wp add 123456700 +<code>.wp add 123456700</code> 
-Create a macro 'wp2' with these commands: +  Create a macro 'wp2' with these commands: 
-.wp reload 123456700 +<code>.wp reload 123456700 
-.wp load 123456700 +.wp load 123456700</code> 
-Create a macro 'wp3' with this command: +  Create a macro 'wp3' with this command: 
-.wp show on 123456700 +<code>.wp show on 123456700</code> 
-Create a macro 'wp4' with this command: +  Create a macro 'wp4' with this command: 
-.wp show off 123456700 +<code>.wp show off 123456700</code> 
-Teleport to the creature: +  Teleport to the creature: 
-.go creature 1234567 +<code>.go creature 1234567</code> 
-Use macro 'wp1' +  Use macro 'wp1' 
-Create the path: +  Create the path: 
-Go to the position where the next waypoint should be and use macro 'wp1' +    Go to the position where the next waypoint should be and use macro 'wp1' 
-repeat until all waypoints are set (don't forget to also create a path back to the starting position) +    repeat until all waypoints are set (don't forget to also create a path back to the starting position) 
-use macros 'wp3' and 'wp4' to show / hide the path (GM on required to actually see the path) +    use macros 'wp3' and 'wp4' to show / hide the path (GM on required to actually see the path) 
-ensure that the waypoints are not too far away from each other, especially if the creature is walking over hills etc. as it will try to directly move to the next waypoint, even if this means going through the ground +    ensure that the waypoints are not too far away from each other, especially if the creature is walking over hills etc. as it will try to directly move to the next waypoint, even if this means going through the ground 
-Select the creature and use macro 'wp2'; it should now start moving+  Select the creature and use macro 'wp2'; it should now start moving
 ===== A few helpful SQL statements ===== ===== A few helpful SQL statements =====
  
-Delete path +**Delete path** 
-Select the creature, then unload the path:+  Select the creature, then unload the path:
  
-.wp unload +<code>.wp unload</code> 
-Delete the path from the DB, for example 123456700:+  Delete the path from the DB, for example 123456700: 
 +<code>DELETE FROM `waypoint_data` WHERE `id` = 123456700;</code> 
 +**Take over the waypoints from 'waypoint_data' to 'waypoints' (SmartAI)**
  
-DELETE FROM `waypoint_data` WHERE `id` = 123456700; 
-Take over the waypoints from 'waypoint_data' to 'waypoints' (SmartAI) 
 If you need the waypoints for SmartAI you have to copy the waypoints from table waypoint_data into table waypoints and then delete the original waypoints (unload the path for the creature via .wp unload if it was loaded before). Here an example for path 123456700: If you need the waypoints for SmartAI you have to copy the waypoints from table waypoint_data into table waypoints and then delete the original waypoints (unload the path for the creature via .wp unload if it was loaded before). Here an example for path 123456700:
  
-INSERT INTO `waypoints` (`entry`,`pointid`,`position_x`,`position_y`,`position_z`)+<code>INSERT INTO `waypoints` (`entry`,`pointid`,`position_x`,`position_y`,`position_z`)
 SELECT `id`,`point`,`position_x`,`position_y`,`position_z` FROM `waypoint_data` WHERE `id` = 123456700; SELECT `id`,`point`,`position_x`,`position_y`,`position_z` FROM `waypoint_data` WHERE `id` = 123456700;
-DELETE FROM `waypoint_data` WHERE `id` = 123456700; +DELETE FROM `waypoint_data` WHERE `id` = 123456700;</code> 
-Take over the waypoints from 'waypoint_data' to 'script_waypoint' (CreatureAI)+**Take over the waypoints from 'waypoint_data' to 'script_waypoint' (CreatureAI)** 
 The same as above, but now for script_waypoint instead of waypoints. The entry of script_waypoint has to be the creature_template.entry, here for example 1234567: The same as above, but now for script_waypoint instead of waypoints. The entry of script_waypoint has to be the creature_template.entry, here for example 1234567:
  
-INSERT INTO `script_waypoint` (`entry`,`pointid`,`location_x`,`location_y`,`location_z`)+<code>INSERT INTO `script_waypoint` (`entry`,`pointid`,`location_x`,`location_y`,`location_z`)
 SELECT 1234567 AS `entry`,`point`,`position_x`,`position_y`,`position_z` FROM `waypoint_data` WHERE `id` = 123456700; SELECT 1234567 AS `entry`,`point`,`position_x`,`position_y`,`position_z` FROM `waypoint_data` WHERE `id` = 123456700;
-DELETE FROM `waypoint_data` WHERE `id` = 123456700;+DELETE FROM `waypoint_data` WHERE `id` = 123456700;</code>
  
 Don't forget to unload the path from the creature if it was loaded before. Don't forget to unload the path from the creature if it was loaded before.
waypoints-information.1696325680.txt.gz · 最后更改: 2023/10/03 17:34 由 admin

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki