Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

[DL] Item Proto Converter


Arthir

Rekomendowane odpowiedzi

Opublikowano

Witam,

 

Postanowiłem trochę zmienić standardowego convertera udostępnionego przez iMer'a.

Umożliwia on konwertowanie pliku item_proto do formatu *.sql.

Dodałem klawisz "Forum", troszkę poukładałem buttony, nadałem kilka zmian i proszę :

 

Item Proto Converter | iMer

 

rava.jpg

 

Download :

 

Item Proto Converter.zip

 

Skan :

 

http://screenshooter.net/data/uploads/pr/gv/prhl.jpg

 

Źródło :

 

http://www.elitepvpers.com/forum/metin2-hacks-bots-cheats-exploits-macros/414486-tool-item_proto-dumps-zu-sql-file.html

 

Source : Proszę kogoś o zrobienie skana na virustotal.com, ponieważ mam problem z internetem...

 

#include <String.au3>
#include <File.au3>
#include <GUIConstants.au3>
#include <WindowsConstants.au3>
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
Opt("GUIOnEventMode", 1)
Global $ScriptDir = @ScriptDir
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Item_Proto Converter | iMer", 368, 214, 586, 300)
GUISetOnEvent($GUI_EVENT_CLOSE, "_close")
$input = GUICtrlCreateInput("", 128, 45, 121, 21)
$Button1 = GUICtrlCreateButton("Change...", 264, 43, 75, 25)
GUICtrlSetOnEvent($Button1, "_input")
$Label1 = GUICtrlCreateLabel("Item_proto_dump.xml :", 16, 48, 110, 17)
$Label2 = GUICtrlCreateLabel("Item_proto.sql :", 48, 96, 76, 17)
$output = GUICtrlCreateInput("", 128, 91, 121, 21)
$Button2 = GUICtrlCreateButton("Change...", 264, 89, 75, 25, 0)
GUICtrlSetOnEvent($Button2, "_output")
$Button3 = GUICtrlCreateButton("Convert !", 264, 136, 75, 25, 0)
$label3 = GUICtrlCreateLabel("Autor : iMer", 8, 192, 58, 17)
$Button4 = GUICtrlCreateButton("Forum", 168, 136, 75, 25)
$label4 = GUICtrlCreateLabel("Design : Arth", 300, 192, 65, 17)
GUICtrlSetOnEvent($Button3, "_con")
GUICtrlSetOnEvent($Button4, "_forum")
GUISetState(@SW_SHOW)
$Form2 = GUICreate("Item_Proto Converter | iMer", 369, 215, 527, 303)
GUISetOnEvent($GUI_EVENT_CLOSE, "_close")
$t1we = GUICtrlCreateLabel("Postęp :", 144, 80, 44, 17)
$insgzeilen = GUICtrlCreateLabel("Loading...", 195, 80, 57, 17)
$dsv = GUICtrlCreateLabel("Aktualizacja :", 120, 104, 63, 17)
$aktuellzeilen = GUICtrlCreateLabel("Loading...", 195, 104, 78, 17)
$Progress1 = GUICtrlCreateProgress(64, 144, 230, 17)
$Cancel = GUICtrlCreateButton("Cancel", 144, 184, 75, 25)
GUISetState(@SW_SHOW)
GUICtrlSetOnEvent($Cancel, "_close")
GUISetState(@SW_HIDE)
#EndRegion ### END Koda GUI section ###
;$string=_StringBetween($sString,$start,$ende)
while 1
   sleep (100)
WEnd

Func _con ()
   $lin = 0
   GUISetState(@SW_HIDE,$Form1)
   GUISetState(@SW_SHOW,$Form2)
   $outfile = GUICtrlRead($output)
   $file =    GUICtrlRead($input)
   if $file = "" Then
       MsgBox(48,"Błąd","Nie określono pliku *.xml!")
       _input()
   EndIf
   if $outfile = "" Then
       if FileExists($ScriptDir&"item_proto.sql") then
           _output ()
       Else
       $outfile = "item_proto.sql"
   EndIf
   EndIf
$lines = _FileCountLines($file) - 1
$ges = _FileCountLines($file) - 2
$start = '"'
$ende = '"'
While $lines-1 >= 1
   $lin = $lin+1
   $sString= FileReadLine($file,$lines)
   $string=_StringBetween($sString,$start,$ende)
   FileWrite($outfile,"INSERT INTO `item_proto` (`vnum`,`name`,`gb2312name`,`type`,`subtype`,`weight`,`size`,`antiflag`,`flag`,`wearflag`,`immuneflag`,`gold`,`shop_buy_price`,`limittype0`,`limitvalue0`,`limittype1`,`limitvalue1`,`applytype0`,`applyvalue0`,`applytype1`,`applyvalue1`,`applytype2`,`applyvalue2`,`value0`,`value1`,`value2`,`value3`,`value4`,`value5`,`socket0`,`socket1`,`socket2`,`socket3`,`socket4`,`socket5`,`refined_vnum`,`refine_set`,`magic_pct`,`specular`,`socket_pct`) VALUES (")
       FileWrite($outfile,"'"&$string[0]&"',")
       FileWrite($outfile,$string[1]&",")
   For $a = 2 to 38 Step 1
       FileWrite($outfile,"'"&$string[$a]&"',")
   Next
   FileWrite($outfile,"'"&$string[39]&"'")
   FileWrite($outfile,");"&@CRLF)
   Local $perc = Round($lin/$ges*100)
   GUICtrlSetData($Progress1,$perc)
   GUICtrlSetData($insgzeilen,$ges)
   GUICtrlSetData($aktuellzeilen,$lin)
$lines=$lines-1
WEnd
MsgBox(64,"Gotowe!","Plik *.xml został przekonwertowany do *.sql!")
_ende ()
EndFunc

Func _input ()
   $in = FileOpenDialog('Plik...',"",'Plik *.xml(*.xml)')
   GUICtrlSetData($input,$in)
EndFunc

Func _output ()
   $out = FileOpenDialog('Zapisz...',"",'Plik *.sql(*.sql)')
   GUICtrlSetData($output,$out)
EndFunc

Func _ende ()
   Exit
EndFunc

Func _forum ()
ShellExecute ("http://www.elitepvpers.com/forum/metin2-hacks-bots-cheats-exploits-macros/414486-tool-item_proto-dumps-zu-sql-file.html")
EndFunc

Func _close ()
   Exit
EndFunc

 

Have fun ! :)

screenshot_10.jpg


  • 1 miesiąc temu...

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...