Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


Tokei last won the day on September 5

Tokei had the most liked content!

Profile Information

  • Gender
  • Location

Recent Profile Visitors

21,876 profile views

Tokei's Achievements

  1. Heya, Well, the first step would be converting your SQL database to CSV/text format. You can do that by querying the following: // for db/re/item_db.txt select `id`, `name_english`, `name_japanese`, `type`, `price_buy`, `price_sell`, `weight`, `atk:matk`, `defence`, `range`, `slots`, `equip_jobs`, `equip_upper`, `equip_genders`, `equip_locations`, `weapon_level`, `equip_level`, `refineable`, `view`, CONCAT('{', IFNULL(`script`, ''), '}'), CONCAT('{', IFNULL(`equip_script`, ''), '}'), CONCAT('{', IFNULL(`unequip_script`, ''), '}') from `item_db_re` I'm using HeidiSQL, but from there... right-click a row > Export grid rows > - Output format: Delimited text - Row selection: Complete - Options: - Uncheck "Include column names" - Field separator: "," - NULL value: "" (leave empty) Then you should have a normal item_db.txt output. Paste the output to your item_db.txt file in the db folder, do the same for the import folder using the other SQL table. From there, you can run the csv2yaml tool (just make sure there is no item_db.yml files, otherwise it won't actually attempt to do the conversion).
  2. Finally got around to do some upgrades: Fixed a bunch of missing shortcuts. Fixed issues with the bias values not being saved. Added bezier curves (Edit > Add/Delete bezier curve). Added detection for bezier curves for str files. This feature also impact the time a file takes to load as there are many calculations required for this. If you're having issues, you can always disable this option via File > Settings > Attempt to recover lost str information. To move a single control point of the bezier curve, hold the Ctrl key down. It will now draw the entire path of the layer instead of only the current interpolation path. You can now navigate through the nodes in the path by clicking on the red-ish dot. You can now change the origin of the layer by moving the cyan dot in the image above. You can reset the origin from Edit > Center origin. Added a scaling option for ease of use, via Edit > Scale. For scaling down by 80%, use 0.2; likewise, for scaling up by 250%, use 2.5. Fixed a bug with the zoom selection when using the mouse wheel and not being able to select a predefined value. Added a visibility option to the layers. There are more options when right-clicking the layer. Added a gif saving option from File > Save as Gif. The feature is far from perfect, but it can help some. Added specific paste options. After copying a keyframe with Ctrl-C, you'll be able to paste which property you are looking for: As with any shortcut, these can be changed from File > Settings > Shortcuts. The texture paste currently only copies the index, not the actual texture. Will fix some other day... Fixed a bug where closing a popup window wouldn't focus the main window afterwards. Fixed a bug when saving a file with texture animations mixed with bias/bezier. Not entirely sure what you mean there. If the issue isn't fixed in this version, please explain it again.
  3. Well, you're mixing up || and &&. You must have all items, so you need: if (countitem(7830) > 0 && countitem(7831) > 0 && countitem(6151) > 0 && countitem(969) > 999 && countitem(60003) > 199) { (Also the "next;" below that line shouldn't be there.)
  4. Never knew this one existed, thank you Emistry! This is much simpler.
  5. Heya, You should use a function instead for items calling script code. So your script would become: function script F_AtBonus { mes "Kitsune Fox Blessings"; mes "..."; next; switch(select("...")) { } end; } - script atcmd_bonus -1,{ end; OnInit: bindatcmd "bonus", strnpcinfo(0) + "::OnCommand"; end; OnCommand: callfunc("F_AtBonus"); end; } And your item script would be: { specialeffect2 549; soundeffectall "moonlight_move.wav",0; callfunc("F_AtBonus"); } Alternatively, you can use doevent directly. So your code would be: { specialeffect2 549; soundeffectall "moonlight_move.wav",0; doevent "bonus_atcmd::OnCommand";} Though... doevent is a tricky script command and usually isn't something I'd recommend using if you can avoid it. But, it will work in your case.
  6. Long story short, you need to restart your server. As for why... that is due to how SQL data is used on the map-server. When the map-server starts, it reads all the variables in the mapreg table and loads them into memory. This way, when you want to access the variable in-game (when you use @set $variable), the value is easily accessible without having to look it up with your SQL server. This is done for various other features, like your character inventory, quests, achievements, player stats, etc. In either case, when you edit or delete the entry in SQL while it is still being loaded in memory, it will not have any impact in-game because that is not where the data is being read from. Doing so can actually cause issues as well if you're not careful. So you need to close your server, truncate the table, and then restart your server.
  7. Hmm, it's hard to phrase it differently. Your events, OnPCDieEvent and OnPCKillEvent, are on a NPC (Deathmatch PvP Warper) which is duplicated. As a result of duplicating your NPCs, the events trigger for each one of those NPCs as well. You've probably figured this out already if you've looked at the error messages. Your duplicated NPCs in your case are: moscovia,213,182,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#mos 823 morocc,170,87,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#moc 823 comodo,180,150,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#com 823 mid_camp,216,280,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#mid 823 prontera,43,210,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#prt2 823 lighthalzen,166,93,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#lhz 823 prontera,263,209,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#prt02 823 rachel,121,112,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#rac3 823 dicastes01,188,188,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#dic 823 mora,44,147,6 duplicate(Deathmatch PvP Warper) DM PvP Warper#mora 823 malangdo,146,119,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#mal 823 ayothaya,157,111,3 duplicate(Deathmatch PvP Warper) DM PvP Warper#ayo 823 So when someone dies, the first event is queued: Deathmatch PvP Warper::OnPCDieEvent But since the NPC is duplicated, these events are also queued and will trigger: DM PvP Warper#mos::OnPCDieEvent DM PvP Warper#moc::OnPCDieEvent DM PvP Warper#com::OnPCDieEvent etc... Now obviously that's not what you wanted and that's causing you issues. You can easily fix the problem by moving the events to another NPC that is not duplicated. So simply create a new NPC, add your events to this one instead, and that's it. So something like this: - script do_not_duplicate -1,{ end; OnPCDieEvent: // ... end; OnPCKillEvent: // ... end; } (And remove the event labels from Deathmatch PvP Warper as well, of course.)
  8. Yes, you... repeated what I said. Therefore, move the events to a NPC that is not duplicated.
  9. Heya, You should only have a single copy of OnPCKillEvent and OnPCDieEvent in all your scripts, in a single NPC that is not duplicated. Right now, you placed the event on your warper NPC, which is duplicated numerous times and that is your problem. The event is being triggered as many times as you have copies of said NPC.
  10. The error you received, "Server received crash signal! Attempting to save all online characters!", is a generic error that means absolutely nothing besides "your server crashed". You will always get this same error. You most likely have two unrelated crashes there. As cook1e said above, you want to run your server with gdb (there is a link provided in his post that explains how to use it). Gdb is a debugging tool that will give you a stack trace. You will get the crash reason, followed by the line in your source code that crashed the server, followed by the functions that called your code step by step. To print the stack trace, you will want to use "bt full" after the crash. You should also always run your server with gdb as you can't predict when a crash will happen. Once you have the stack trace, you can share it here and people can tell you how to fix your code. Or they'll ask you to provide the code surrouding the crash. Or, if the error is obvious, you might be able to fix it yourself. But either way, we can't help you without a gdb stack trace. Goodluck!
  11. Well, JT_MD_Airboat_Poring JT_MD_AIRBOAT_PORING are not the same. If anything, you can also just set it directly: [jobtbl.JT_MD_AIRBOAT_PORING] = 1.2, or [20887] = 1.2,
  12. Heya, Don't use SDE to connect to your server via SFTP. I'll be removing the feature as it's bad practice to do that in the first place. Use a git service like github or gitlab and then use SDE locally if you want.
  13. No on all questions. Full disclosure, I forgot this feature even existed and I'm really tempted to simply nuke it. I'd say it's not a good practice to generate patches using this tool.
  14. Heya, If you are following the recommended setup, then the only required files are main.sql and logs.sql. The item_cash SQL file is the alternative to db/(pre-)re/item_cash_db.txt. Seeing are you're using the text/yaml version of the databases, you don't need it. As for roulette_default_data.sql, that's optional. If you plan on setting your own values in it, then you don't need the default values from the file. If you want pre-made values for it, then yes, use the file. The roulette system has not been converted to a text/yaml version for some reason. That seems like a forgotten feature. The other SQL files are not meant for performance. You will most likely be using them for your website though, since it will want to know your item/mob data from somewhere.
  15. Heya, That's intended, surprisingly. When you are editing the hat sprite, you are viewing the world from the perspective of the hat. So if you set all the XY offsets the same, from... the perspective of the hat, nothing seems to be moving. That makes sense. But that doesn't work in-game because the body sprite has anchors points, which decides where the hat will be drawn. This position moves depending of the body's orientation. To "recreate" this, you'd have to use Anchors > Use body as base (this essentially attaches the current sprite to the body instead). In other words, this will set the perspective from the body. Though, in the end, that's not really that helpful to you because you'd have to set the offsets one by one. Plus, that's not possible to fully match those offsets, it will never work. Instead, do the following: Align all the hat's anchors points with the base body. Set all the offsets to a fixed value. This is not really possible by hand, so the following should do the trick (it uses the default body as reference, but it should be good enough): // Change to ref_body_f.act for the female anchor points var body = new Act(ApplicationManager.GetResource("ref_body_m.act")); for (int aid = 0; aid < act.Actions.Count; aid++) { var action = act[aid]; for (int fid = 0; fid < action.Frames.Count; fid++) { var frame = action[fid]; var frameReference = body.TryGetFrame(aid, fid); if (frameReference != null) { frame.Anchors[0].OffsetX = frameReference.Anchors[0].OffsetX; frame.Anchors[0].OffsetY = frameReference.Anchors[0].OffsetY; } } } // Uncomment below if you want to set the same offsets for all your layers //foreach(var action in act.Actions) { // foreach(var frame in action.Frames) { // foreach(var layer in frame.Layers) { // layer.OffsetY = -38; // layer.OffsetX = 0; // } // } //} This will achieve what you're looking for. And yes, anchors points are quite confusing. Without using a script, this could also be done via Anchors > Set anchors > Set from file... > Select a base body sprite for reference.
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.