Server Database Editor

@@Tokeiburu ok problem fix. thanks for the update
default_smile.png
cool

 
@@Tokeiburu

I've been wondering, is there a way that you can search empty/unfilled values? Like, for instance, I want to check if there are unfilled values under unidentified item name on client item tab.

Also, is there be a way to show only items with errors in them (missing resources, per instance)?

 
@@Tokeiburu

I've been wondering, is there a way that you can search empty/unfilled values? Like, for instance, I want to check if there are unfilled values under unidentified item name on client item tab.

Also, is there be a way to show only items with errors in them (missing resources, per instance)?
Yep, it is possible...!

You can use the search box and type in "[property_name_here]". In your case that would be "[un._display_name]" which will give you all empty unidentified display names. Other examples would be :

[view_id] 5 // returns all items with view id 5

[is_card] true // returns all cards

[number_of_slots] 2 // returns all items with 2 slots

[id._resource_name] // returns all identified resource names which are empty

[un._resource_name] // returns all unidentified resource names which are empty

[id._description] // empty identified description

[un._description] // empty unidentified description

[display_name] // empty identified display name

[un._display_name] // empty unidentified display name

This works for all the tables in SDE of course.

X6mtr4O.png


The other method is with scripting (Tools > IronPython Script...) :

selection.Clear();for tuple in client_items: if (tuple["un_display_name"].strip() == ""): selection.Add(tuple) elif (tuple["display_name"].strip() == ""): selection.Add(tuple)# Press Ctrl-R to only show the selected items in the list.# To remove the Ctrl-R restriction, go in search options and clear the "Range field".
x85YY21.png


If you're looking for something more specific, let me know!

Edit : I almost forgot your second question...! You could do that with scripting, although you may lag a bit when you execute the script. Also be careful with the encodings of the fieds :

def is_in_grf(resource): # print "Looking for " + "datatextureÀ¯ÀúÀÎÅÍÆäÀ̽ºitem" + resource + ".bmp" if (database.MetaGrf.GetEntry("datatextureÀ¯ÀúÀÎÅÍÆäÀ̽ºitem" + resource + ".bmp") == None): return False if (database.MetaGrf.GetEntry("datatextureÀ¯ÀúÀÎÅÍÆäÀ̽ºcollection" + resource + ".bmp") == None): return False return Trueselection.Clear();for tuple in client_items: if (is_in_grf(tuple["id_resource_name"]) == False): selection.Add(tuple) elif (is_in_grf(tuple["un_resource_name"]) == False): selection.Add(tuple)# Press Ctrl-R to only show the selected items in the list.# To remove the Ctrl-R restriction, go in search options and clear the "Range field".
DEghNI0.png


 
Last edited by a moderator:
@@Tokeiburu

-------------- Message --------------Object reference not set to an instance of an object.-------------- Stack trace -------------- at GrfToWpfBridge.Application.DefaultErrorHandler._reportAnyManagedExceptions(String message, Exception exception, ErrorLevel errorLevel) at GrfToWpfBridge.Application.DefaultErrorHandler.Handle(Exception exception, ErrorLevel errorLevel) at SDE.Tools.DatabaseEditor.Generic.DbLoaders.DbLoaderMethods.SaveAsLua(SdeDatabase gdb, String path) at SDE.Tools.DatabaseEditor.Generic.DbLoaders.DbLoaderMethods.DbClientWrite(DbDebugItem`1 debug, AbstractDb`1 db, String path, Nullable`1 typeOverride) at SDE.Tools.DatabaseEditor.Generic.DbLoaders.DbLoaderMethods.DbClientWrite(DbDebugItem`1 debug, AbstractDb`1 db) at SDE.Tools.DatabaseEditor.Generic.Core.DbClientItems.WriteDb(String dbPath, String subPath, ServerType serverType, FileType fileType) at SDE.Tools.DatabaseEditor.Engines.DatabaseEngine.SdeDatabase.Save(AsyncOperation ap, IProgress progress) at SDE.Tools.DatabaseEditor.SdeEditor._save() at GRF.Threading.GrfThread.<Start>b__3() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart()-------------- Exception --------------System.NullReferenceException: Object reference not set to an instance of an object. at SDE.Tools.DatabaseEditor.Generic.DbLoaders.DbLoaderMethods._saveFile(SdeDatabase gdb, String filename, String output, DbAttribute attribute, RequiredCondition`1 condition, Boolean allowReturns) at SDE.Tools.DatabaseEditor.Generic.DbLoaders.DbLoaderMethods.SaveAsLua(SdeDatabase gdb, String path)
What does it means ?

 
@@Tokeiburu ok thanks alot. no. all ok. nothing red.

all my changes revert to before edited. 

default_angry.png


there problem happen because, I delete something it client items. then I not save first. I add new client item. 
default_sad.png


huwarghhhhhhh tired add 21 new item, need to make back. huuhuhu

 
@@Tokeiburu

Thanks again for showing me the Python ways, it helped me a tonn with bunch editing, finding which items exist in my db but don't exist in client files and vice versa.

While doing all this I've thought of few things that might be useful for other people as well:

1) Import fields from file for selected/empty items only. I'd assume people who use this tool might have their own items added, and god forbid you to have your own items that cross with newest client items, since then you either lose ability to autoupdate them from newest released files, or you have to backup and reinsert your description/collection each time. Ouch.

2) Is there a chance we can modify key bindings? I didn't quite find ctrl+alt+E a good choice for creating items in client part, maybe it's just me, but it'd still be a nice feature to have :3

3) Is there a possibility to make non-repeating bindings to work inside item(whatever) editing window? For example, if I filed a new item in item_db I'd have to manually switch over (with either mouse or tabs) to list to use ctrl+alt+E and ctrl+E.

4) This one is concerning mob tab. Can mob_avail be considered somehow? It's not much and of low to none priority, but it at least helps check if you used the right IDs instead of checking it manually on server.

And sorry >.< Thank you for your great work.

 
@@Tokeiburu

Thanks again for showing me the Python ways, it helped me a tonn with bunch editing, finding which items exist in my db but don't exist in client files and vice versa.

While doing all this I've thought of few things that might be useful for other people as well:

1) Import fields from file for selected/empty items only. I'd assume people who use this tool might have their own items added, and god forbid you to have your own items that cross with newest client items, since then you either lose ability to autoupdate them from newest released files, or you have to backup and reinsert your description/collection each time. Ouch.

2) Is there a chance we can modify key bindings? I didn't quite find ctrl+alt+E a good choice for creating items in client part, maybe it's just me, but it'd still be a nice feature to have :3

3) Is there a possibility to make non-repeating bindings to work inside item(whatever) editing window? For example, if I filed a new item in item_db I'd have to manually switch over (with either mouse or tabs) to list to use ctrl+alt+E and ctrl+E.

4) This one is concerning mob tab. Can mob_avail be considered somehow? It's not much and of low to none priority, but it at least helps check if you used the right IDs instead of checking it manually on server.

And sorry >.< Thank you for your great work.
Updated to 1.1.5.22

Heya,

1) This would only apply for client items, right? You could use the following script then :

loadedDb = database.LoadTable("C:itemInfo.lua")for tuple in loadedDb: if (client_items.ContainsKey(tuple.Key) == False): client_items[tuple.Key] = tupleif (selected_db != client_items): script.exit() for tuple in selection: if (loadedDb.ContainsKey(tuple.Key)): client_items[tuple.Key] = loadedDb[tuple.Key]
You can expect a good ~30 seconds lag if there are many changes. This task is too specific to be added directly in the editor though; I'll think about it...! You can already import fields from file with Tools > Import fields from... but it overwrites all entries.

2) Agreed, some shortcuts are really awkward. You can now set the shortcuts via Tools > Settings > Shortcuts. Click the shortcut you want to edit and then enter the new combo. Some strings might not get updated (menus for instance) but they'll be fixed once you restart the application.

3) I can increase the key binding range of custom shortcuts to the tab instead of the list view, this should solve most of your issues. The new ranges are now as follow :

ListView : Copy/Paste/Cut

Tab : AdvancedPaste/Select/Autocomplete/AdvancedCopy

Global : Save/SaveAll/Delete/everything else

If you cannot find a shortcut, let me know. (You must load the tables for all shortcuts to appear.)

4) mob_avail is already taken into account; the field for it is named "Sprite ID" (in the Mob tabs). If you meant something else, you'll have to clarify ;].

 
Updated to 1.1.5.22

Heya,

1) This would only apply for client items, right? You could use the following script then :

loadedDb = database.LoadTable("C:itemInfo.lua")for tuple in loadedDb: if (client_items.ContainsKey(tuple.Key) == False): client_items[tuple.Key] = tupleif (selected_db != client_items): script.exit() for tuple in selection: if (loadedDb.ContainsKey(tuple.Key)): client_items[tuple.Key] = loadedDb[tuple.Key]
You can expect a good ~30 seconds lag if there are many changes. This task is too specific to be added directly in the editor though; I'll think about it...! You can already import fields from file with Tools > Import fields from... but it overwrites all entries.

4) mob_avail is already taken into account; the field for it is named "Sprite ID" (in the Mob tabs). If you meant something else, you'll have to clarify ;].
1) That's what I actually meant, a somewhat extension to already existing option of importing things with ability to limit furter which fields you'll overwrite. For example, extra option "only add info to empty fields" or "only affect selected items".

4) Sorry, I missed that one, I filled my mob_avail with wrong ID, didn't see anything new in window after reload and assumed it's not showed anywhere >.< My bad.

 
@@Tokeiburu How to make this editable ? 

I need to change the view id. huhu
That would be because you have checked "Automatically manage view IDs" in the settings tab. This field will be updated if you change the sprite in the Client Items tab (after you save).

 
Last edited by a moderator:
@@Tokeiburu

Sorry to bother you once again, but is there a way to load txt files as tables like luas? Or at least load them in *some* way? I mean idnum2 files and so on. I'd guess there is, but I'd need some help with finding it >.< Any chance there's a doc hidden somewhere that I missed not to bug you for such things? D:

 
@@Tokeiburu i got this message when try to change load .lub files. why ? thanks for the information. I try to untick manage view id and its work
default_smile.png


Code:
--------------          Message          --------------Invalid table file (lua/lub).--------------        Stack trace        --------------   at GrfToWpfBridge.Application.DefaultErrorHandler._reportAnyManagedExceptions(String message, Exception exception, ErrorLevel errorLevel)   at GrfToWpfBridge.Application.DefaultErrorHandler.Handle(Exception exception, ErrorLevel errorLevel)   at SDE.Tools.DatabaseEditor.WPF.ViewIdPreviewDialog._tupleUpdate(Boolean bypass)   at SDE.Tools.DatabaseEditor.WPF.ViewIdPreviewDialog..ctor(SdeEditor editor, GDbTab tab)   at SDE.Tools.DatabaseEditor.Generic.UI.FormatConverters.CustomHeadgearSprite2Property._button_Click3(Object sender, RoutedEventArgs e)   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)   at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)   at System.Windows.Controls.Primitives.ButtonBase.OnClick()   at System.Windows.Controls.Button.OnClick()   at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)   at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)   at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)   at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)   at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)   at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)   at System.Windows.Input.InputManager.ProcessStagingArea()   at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)   at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)   at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)   at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)   at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)   at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)   at System.Windows.Threading.Dispatcher.Run()   at System.Windows.Application.RunDispatcher(Object ignore)   at System.Windows.Application.RunInternal(Window window)   at System.Windows.Application.Run(Window window)   at SDE.GRFEditorMain.Main(String[] args)--------------         Exception         --------------System.Exception: Invalid table file (lua/lub).   at SDE.Tools.DatabaseEditor.Engines.LuaEngine.LuaHelper.GetLuaTable(LuaParser parser, String tId)   at SDE.Tools.DatabaseEditor.Engines.LuaEngine.LuaHelper.GetIdToSpriteTable(AbstractDb`1 db, ViewIdTypes type, Dictionary`2& outputIdsToSprites, String& error)   at SDE.Tools.DatabaseEditor.Engines.LuaEngine.LuaHelper.GetSpriteFromViewId(Int32 viewIdToFind, ViewIdTypes type, AbstractDb`1 db, ReadableTuple`1 tuple)   at SDE.Tools.DatabaseEditor.Engines.PreviewEngine.HeadgearPreview.Read(ReadableTuple`1 tuple, PreviewHelper helper, List`1 jobs)   at SDE.Tools.DatabaseEditor.Engines.PreviewEngine.PreviewHelper.Read(ReadableTuple`1 tuple, GDbTab tab)   at SDE.Tools.DatabaseEditor.WPF.ViewIdPreviewDialog._tupleUpdate(Boolean bypass)
 
Last edited by a moderator:
-------------- Message --------------Object reference not set to an instance of an object.-------------- Stack trace -------------- at GrfToWpfBridge.Application.DefaultErrorHandler._reportAnyManagedExceptions(String message, Exception exception, ErrorLevel errorLevel) at GrfToWpfBridge.Application.DefaultErrorHandler.Handle(Exception exception, ErrorLevel errorLevel) at SDE.Tools.DatabaseEditor.WPF.AccEditDialog.<>c__DisplayClass15.<_save>b__10() at GRF.Threading.GrfThread.<Start>b__3() at System.Threading.ThreadHelper.ThreadStart_Context(Object state) at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) at System.Threading.ThreadHelper.ThreadStart()-------------- Exception --------------System.NullReferenceException: Object reference not set to an instance of an object. at Utilities.Services.EncodingService.FromAnyToDisplayEncoding(String fullPath, Boolean expand) at SDE.Tools.DatabaseEditor.WPF.AccEditDialog._writeAccName(String path, Encoding encoding) at SDE.Tools.DatabaseEditor.WPF.AccEditDialog.<>c__DisplayClass15.<_save>b__10()
@@Tokeiburu I try to add new view ID. This happen when I want to save. why? 

 
Dear @Tokeiburi, version 1.1.5.22 have very crytical bug when saving files to grf, you lost your files in GRF

OWy0qhK.png


How reproduce: 

rAthena + client 2010

1.) create new item in item_db2

2.) add this item to the client (right click on created item -> add to client files)

3.) Edit item, change description

4.) Press ctrl+s

Check in game, you will see this item.

Do the same things for the another item.

Click several times ctrl + s

->> Voila ->> The idnum table removed.... ((((

 
@@Tokeiburu i got this message when try to change load .lub files. why ? thanks for the information. I try to untick manage view id and its work
default_smile.png
The error is somewhat vague. The parser failed to load either the ACCESSORY_IDs table or the AccNameTable table. Make sure the lua/lub file you've set are correct and that they contain these tables inside each one of them.

As for the second error, one of your texture name is not set (I'll make the error more obvious on the next release).

On a side note, I see people are still having trouble using the view ID feature. I'll review this entire feature to prevent future bugs, it should be more stable on the next release.

@@Tokeiburu

Sorry to bother you once again, but is there a way to load txt files as tables like luas? Or at least load them in *some* way? I mean idnum2 files and so on. I'd guess there is, but I'd need some help with finding it >.< Any chance there's a doc hidden somewhere that I missed not to bug you for such things? D:
Not sure what you mean. In the Settings tab, you can uncheck the "Use lua files" to load the text based tables instead.

Dear @Tokeiburi, version 1.1.5.22 have very crytical bug when saving files to grf, you lost your files in GRF

How reproduce: 

rAthena + client 2010

1.) create new item in item_db2

2.) add this item to the client (right click on created item -> add to client files)

3.) Edit item, change description

4.) Press ctrl+s

Check in game, you will see this item.

Do the same things for the another item.

Click several times ctrl + s

->> Voila ->> The idnum table removed.... ((((
I'll have a look into it (I'll send you a pm if I can't reproduce it). For now though, I'd recommend you to put your text files outside of the GRF instead (this will speed up your saving process and avoid this bug you're having). You can always recover your idnum table file from the backup manager if you lost many of your previous edits.

 
Last edited by a moderator:
@@Tokeiburu Thanks alot for you response. I want to report again. If we tick manage view ID automatically (headgear) some of the item (at accname and accesorry id) will become UNREGISTERED. 
default_ohmy.png


why ?

 
@@Tokeiburu i got this message when try to change load .lub files. why ? thanks for the information. I try to untick manage view id and its work
default_smile.png
The error is somewhat vague. The parser failed to load either the ACCESSORY_IDs table or the AccNameTable table. Make sure the lua/lub file you've set are correct and that they contain these tables inside each one of them.

As for the second error, one of your texture name is not set (I'll make the error more obvious on the next release).

On a side note, I see people are still having trouble using the view ID feature. I'll review this entire feature to prevent future bugs, it should be more stable on the next release.

>@@Tokeiburu

Sorry to bother you once again, but is there a way to load txt files as tables like luas? Or at least load them in *some* way? I mean idnum2 files and so on. I'd guess there is, but I'd need some help with finding it >.< Any chance there's a doc hidden somewhere that I missed not to bug you for such things? D:
Not sure what you mean. In the Settings tab, you can uncheck the "Use lua files" to load the text based tables instead.

Dear @Tokeiburi, version 1.1.5.22 have very crytical bug when saving files to grf, you lost your files in GRF

How reproduce: 

rAthena + client 2010

1.) create new item in item_db2

2.) add this item to the client (right click on created item -> add to client files)

3.) Edit item, change description

4.) Press ctrl+s

Check in game, you will see this item.

Do the same things for the another item.

Click several times ctrl + s

->> Voila ->> The idnum table removed.... ((((
I'll have a look into it (I'll send you a pm if I can't reproduce it). For now though, I'd recommend you to put your text files outside of the GRF instead (this will speed up your saving process and avoid this bug you're having). You can always recover your idnum table file from the backup manager if you lost many of your previous edits.
I found this is very funny. Because i do not lose files. LOL. I just start to hurry up to report about this to you, i was check grf there were no files. But, when i reopen again server database editor & SourceTree, i was found files which removed frm GRF at GRF & at client/ folder in the emulator folder. For now anything works fine, but if i will have this problem one more time, i will report to you for sure about that. (sorry for my english)

 
Maybe I misunderstood ... sorry.

I found this is very funny. Because i do not lose files. LOL. I just start to hurry up to report about this to you, i was check grf there were no files. But, when i reopen again server database editor & SourceTree, i was found files which removed frm GRF at GRF & at client/ folder in the emulator folder. For now anything works fine, but if i will have this problem one more time, i will report to you for sure about that. (sorry for my english)
LOL .. what did I just see over here ? is that somekind of threaten ?
 
You're the one who said this ...
 
 
Dear @Tokeiburi, version 1.1.5.22 have very crytical bug when saving files to grf, you lost your files in GRF
How reproduce:
rAthena + client 2010
1.) create new item in item_db2
2.) add this item to the client (right click on created item -> add to client files)
3.) Edit item, change description
4.) Press ctrl+s
 
Check in game, you will see this item.
Do the same things for the another item.
Click several times ctrl + s
->> Voila ->> The idnum table removed.... ((((
 

I found this is very funny. Because i do not lose files. LOL. I just start to hurry up to report about this to you, i was check grf there were no files. But, when i reopen again server database editor & SourceTree, i was found files which removed frm GRF at GRF & at client/ folder in the emulator folder. For now anything works fine, but if i will have this problem one more time, i will report to you for sure about that. (sorry for my english)
now ... which statement is true ?
 
and Tokeiburu suggested an alternative way for you to temporary avoid the problems while he try to figure out what have happened ...
then you come back saying that "but if i will have this problem one more time, i will report to you for sure about that."
Seriously?
 
You should be appreciate that Tokeiburu share his great work with us and not threatening him!
 
Last edited by a moderator:
Back
Top