reset.bat 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. @echo off
  2. rem OPTION Will update, the EQ2Emu World DB. 1 for on, anything else for off.
  3. rem Variables and Data
  4. SET NAME=ZekLabs.com
  5. TITLE %NAME%
  6. COLOR 0E
  7. echo [Downloading SQL Wipe.]
  8. echo [Download of SQL Wipe Complete.]
  9. echo [Removing SQL Database.]
  10. copy dangerous.sql ..\mariadb\bin
  11. cd ..\mariadb\bin\
  12. mysql -ueq2emu -peq2emu <dangerous.sql
  13. del dangerous.sql
  14. cd ..\..
  15. echo [You now have an empty database.]
  16. echo [Getting a NEW DB to fill it with.]
  17. wget -q -N --show-progress --progress=bar:force:noscroll https://zeklabs.com/dl/eq2emudb.rar
  18. echo [Extracting NEW DB]
  19. unrar x -y -inul eq2emudb.rar
  20. echo [Importing New DB.]
  21. cd mariadb\bin\
  22. mysql -ueq2emu -peq2emu --database=eq2emu < ..\..\eq2emu.sql
  23. cd ..\..
  24. del eq2emudb.rar
  25. del eq2emu.sql
  26. echo [DB Import Completed.]
  27. echo [Removing LUA files.]
  28. cd server\lua
  29. rmdir . /s /q
  30. cd ..\..
  31. echo [The Above error is expected and will not cause issues]
  32. echo [All LUA files Deleted.]
  33. echo [Getting LUA Files.]
  34. echo [This will take a moment due to number of files]
  35. cd server
  36. wget -q -N https://zeklabs.com/dl/eq2emulua.rar
  37. ..\unrar x -y -inul eq2emulua.rar
  38. del eq2emulua.rar
  39. echo [Completed LUA Updates]
  40. cd ..
  41. echo [Removing old Maps and Navs.]
  42. cd server\maps
  43. del /q *.eq2map
  44. rmdir nav /q
  45. cd ..\..
  46. echo [All Maps/Navs Deleted.]
  47. echo [Checking for MAP Updates]
  48. echo [This will take a moment due to LARGE map size]
  49. cd server
  50. ..\wget -q -N --show-progress --progress=bar:force:noscroll https://zeklabs.com/dl/eq2emumaps.rar
  51. echo [Begining Extraction of MAPs]
  52. ..\unrar x -y -inul eq2emumaps.rar
  53. del eq2emumaps.rar
  54. echo [Completed MAP Updates]
  55. cd ..\