Jump to content

Alphoccio

Members
  • Content Count

    21
  • Joined

  • Last visited


Reputation Activity

  1. Upvote
    Alphoccio reacted to AnnieRuru in Advance SQL commands   
    As usual, I only write advance guides
    This guide is a compilation of SQL commands that I have used, or Questions answered on the forum
    every single subject here are related to Hercules/Ragnarok Online in some ways, so you won't feel bored reading them XD
    Table of Content
    1. When to use *escape_sql script command
    2. How to build a case-sensitive table
    3. Choose a table type, MyISAM or InnoDB ?
    3a. How to index a table properly
    3b. Why you shouldn't use `char_reg_num_db` table
    4. AUTO_INCREMENT
    5. How to do IF-ELSE in SQL query ?
    5a. How to update multiple rows on different conditions in a single query
    6. How to show the current rank of the player
    7. INSERT INTO ... SELECT ...
    8. Table JOIN vs AS
    9. What is the maximum string limit for *query_sql
    9a. UNION
    This topic is now open to Suggestions, Ideas, Improvements, and Questions ~
    I'm sure many of you have some questions since the creation of this topic
    You may also post up your tricks if you want to share with us
  2. Upvote
    Alphoccio reacted to evilpuncker in Take more damage from a skill when item is equipped   
    that would be a nice suggestion to be implemented in default hercules xD
  3. Upvote
    Alphoccio reacted to jaBote in Fused Cards   
    Didn't test but should work:
     
    prontera,150,150,4 script Fused Cards seller 60,{ mes "Wanna get a fused card?"; mes "For that, I need:"; mes "1x Red Potion"; // Item ID: 501 mes "1x Blue Potion"; // Item ID: 505 mes "1x Yellow Potion"; // Item ID: 503 mes "1x White Potion"; // Item ID: 504 next; if (select("Yes:No")==2){ // No mes "Get out of here!"; close; } if (countitem(501) && countitem(503) && countitem(504) && countitem(505)){ delitem 501,1; delitem 503,1; delitem 504,1; delitem 505,1; if (rand(100) >= 90) { getitem YOUR_CARD_ID,1; mes "Success! There you go!"; } else { mes "LOL FAIL!"; } } else { mes "You're missing items!"; } close;}  

     
  4. Upvote
    Alphoccio reacted to zackdreaver in PC Repair Site, Groups?   
    how about changing from SATA to AHCI or AHCI to SATA in bios setup?
  5. Upvote
    Alphoccio reacted to Garr in PC Repair Site, Groups?   
    It seems like default videocard driver is failing. If you install from the USB, I'd check for corruted files on it, and try to rerun the installation process. Or if you can enter things in Safe Mode, I'd try to install the actual videocard driver that your notebook is using.
  6. Upvote
    Alphoccio reacted to jaBote in Q>Monster   
    Not currently and I doubt it could be easily implemented. All mobs on a map server exist only in RAM and are destroyed when the server is closed. I guess it's not a good idea to try saving tens of thousands of mobs every time the server closes.
     
    For the server, main difference for spawning whether a player or a monster is that the player gets loaded from permanent memory (SQL engine) and the mobs are spawned by scripts.
  7. Upvote
    Alphoccio reacted to malufett in Fire Wall Skill   
    this is the whole code..
     
    skill->firewall_unit_pos = pos;for (i=0;i<8;i++) {  if (i&1) { skill->unit_layout[pos].count = 5; if (i&0x2) {   int dx[] = {-1,-1, 0, 0, 1};   int dy[] = { 1, 0, 0,-1,-1};   memcpy(skill->unit_layout[pos].dx,dx,sizeof(dx));   memcpy(skill->unit_layout[pos].dy,dy,sizeof(dy)); } else {   int dx[] = { 1, 1 ,0, 0,-1};   int dy[] = { 1, 0, 0,-1,-1};   memcpy(skill->unit_layout[pos].dx,dx,sizeof(dx));   memcpy(skill->unit_layout[pos].dy,dy,sizeof(dy)); }  } else { skill->unit_layout[pos].count = 3; if (i%4==0) {   int dx[] = {-1, 0, 1};   int dy[] = { 0, 0, 0};   memcpy(skill->unit_layout[pos].dx,dx,sizeof(dx));   memcpy(skill->unit_layout[pos].dy,dy,sizeof(dy)); } else {   int dx[] = { 0, 0, 0};   int dy[] = {-1, 0, 1};   memcpy(skill->unit_layout[pos].dx,dx,sizeof(dx));   memcpy(skill->unit_layout[pos].dy,dy,sizeof(dy)); }  }  pos++;}  ok those coordinates are patterns..
    and as I said before you need to plot it,... into a Cartesian plane you can see the pattern..
    for example

     
    I hope after seeing this you will get the idea...
    Word of the day: A good programmer is a good mathematician...
     
     

  8. Upvote
    Alphoccio reacted to Neo-Mind in [Release] Custom Job & Custom Shield Patches   
    Well a few people know i have been working on these. So here goes.
     
    Did I hear right?
     
    1. Yes it is what you are thinking. The Custom Job patch allow you to modify the existing jobs and add new jobs      in a fashion similar to HeliumRO's Xray Clients (and some extra stuff u will see below) but using lua files.   2. Similarly Custom Shield Patch allows you to throw the existing 4 shield limit out the door and modify existing as well as     add more shield equipment types to your liking using lua files.   3. For now I have tested them out on a set of clients (for others the logic followed were the same     so I didn't bother with the rest). Ofcourse if any bug comes up I will work on fixing them.     4. Patches were made with existing patches in mind and therefore will not affect any and existing diffs present    in a client you use. Infact you are supposed to use these last only.   5. Custom Job Patch has also an override for Class names based on gender. For it to work Langtype Korean Jobname Fix    is expected to be enabled (for xDiff patches it is a part of Translate to English patch)  
      6. So is there a limit ? yes for now i have limited them as max shields to 10 and max job id to 4300.   So how does it work ?   1. Get the xdiff file for your client version (from the link below)   2. Get the lua files (also from the link below)   3. Modify/Add entries to the lua files (Format is specified below)   4. Load your client and xdiff file in xDiffPatcher   5. Let it Rip!... i mean Patch!!   6. And last but not least place the lua files in their proper locations.   Lua File Formats - Custom Job Patch Custom Job Patch makes use of 7 lua files (similar to the various txt files Xray client had).They need to be present in the luafiles514/lua files/admin path.   1) PCIdentity.lua:   This file is already present in the official GRF but we are going to use a modified version of that one.   All Job Sprites have a corresponding Job ID (including costumes and Job Mounts). This file defines all of them   and their relationships to each other.   This is done with the help of 3 tables =>   i) pcJobTbl (mandatory):  This is where the job id value is defined and mapped to a string for identification JT_KAGEROU = 4211, -- 4211 is the job id for kagerou class     ii) Halter_Map : This is where you specify which job id is the job mount of which class. Ofcourse if you dont  plan to add a mount sprite for a class you can ignore this one. [pcJobTbl.JT_KAGEROU] = pcJobTbl.JH_KAGEROU, -- maps kagerou job to his frog mounted sprite   iii) Shrink_Tbl : This is list of job IDs that need to be ... shrunk i.e. specify all Baby Jobs here. pcJobTbl.JT_SWORDSMAN_B, -- will include Baby Swordsman in the list    2) PCPaths.lua:    Lua equivalent of class_tab.txt . Defines the prefix string used for each class to get its sprite & act file path.    i.e. prefix in => /data/sprite/Àΰ£Á·/¸öÅë/<gender>/<prefix>_<gender>.spr (& act as well).    This is done with the help of two tables (only one of which needs to be filled for a class).        i)  PCStitchTbl :      If your job uses a completely new sprite with a new filename then you can assign it in this table. [pcJobTbl.JT_SWORDMAN] = "°Ë»ç" -- Prefix for Swordsman    ii) PCStitchInheritTbl :      If your job is sharing an existing sprite path already used by a job specified in PCStitchTBl then you can simply connect them in this table (target job id inherits from source job id). [pcJobTbl.JT_SWORDMAN_H] = pcJobTbl.JT_SWORDMAN, --JT_SWORDMAN_H is High Swordsman which uses --same sprite as Swordsman 
      All of the remaining lua files follow a similar pattern with one table for direct assignment and the other one for inheriting value from another job id 3) PCImfs.lua: Lua equivalent of imf_tab.txt . Defines the prefix string for imf files of each class. i)  PCImfTbl : [pcJobTbl.JT_KNIGHT] = "±â»ç", -- Prefix for Knight ii) PCImfInheritTbl : [pcJobTbl.JT_KNIGHT_H] = pcJobTbl.JT_KNIGHT, -- JT_KNIGHT_H is Lord Knight and has the same -- imf as Knight class.
    4) PCHands.lua: Lua equivalent of reality_dir_tab.txt. Defines the prefix strings used for Weapons and Shields of each class i) PCHandsTbl : [pcJobTbl.JT_ASSASSIN] = "¾î¼¼½Å¾î¼¼½Å", -- Prefix for Assassin   ii) PCHandsInheritTbl : [pcJobTbl.JT_GUILLOTINE_CROSS] = pcJobTbl.JT_ASSASSIN, -- Guillotine Cross picks up --weapons/shields from the same path as Assassin class.
    5) PCPals.lua   Lua equivalent of reality_tab.txt. Defines the prefix strings for the body palettes. i) PCPalTbl: [pcJobTbl.JT_MAGICIAN] = "¸¶¹ý»ç", -- prefix for Mage                           ii) PCPalInheritTbl: [pcJobTbl.JT_MAGICIAN_H] = pcJobTbl.JT_MAGICIAN, -- High Mage uses same prefix as Mage class.  
    6) PCNames.lua   Lua equivalent of monstrosity_tab.txt (in part since mobs are defined by jobname.lua) . As the file name says this is where you define all your class names. Reason i saved this for last is because this file is slightly different from the previous 4. Here you can define the class name seperately for both genders. For male classes => i) PCJobNameTbl : [pcJobTbl.JT_WARLOCK] = "Warlock", -- Kind of obvious right? ii) PCJobNameInheritTbl : [pcJobTbl.JT_WARLOCK_H] = pcJobTbl.JT_WARLOCK, -- JT_WARLOCK_H is Transcendent version of -- warlock class and ofcourse it will have same name For female classes => iii) PCJobNameTbl_F : [pcJobTbl.JT_WARLOCK] = "Witch", -- Now the female Warlock will be called Witch
    iv) PCJobNameInheritTbl_F : [pcJobTbl.JT_WARLOCK_H] = pcJobTbl.JT_WARLOCK, -- Same for Transcendent warlock   By default if your gender is female and there is no names defined using either iii) or iv) above then it checks in the tables for male gender. 7) PCFuncs.lua Contains Necessary functions used by the client - DO NOT TOUCH THIS FILE unless you know what you are doing!!!   Lua File Formats - Custom Shield Patch Custom Shield Patch makes use of 2 lua files as specified below. They need to be present in luafiles514/lua files/datainfo folder.   1) ShieldTable.lua : This lua file is the only one you need to configure. It contains 3 tables and is similar in format to WeaponTable.lua i) Shield_IDs : Defines a list of IDs which includes both Shield Types & Item IDs used by shield items in item_db.txt. Shield Items can only start from item id 2101 onwards so anything lesser than that will be considered as a shield type id. To distinguish between them we use the ST (Shield Type) and SI (Shield Item) prefixes. ST_MSHIELD = 4, -- Mirror Shield TypeSI_Platinum_Shield = 2122, -- Platinum Shield's Item ID   ii) ShieldNameTable : Here we assign suffix strings for Shield Types i.e. shield suffix in => /data/sprite/¹æÆÐ/<hand prefix>_<gender>_<shield suffix>.spr [Shield_IDs.ST_MSHIELD] = "_¹Ì·¯½¯µå", --Suffix for Mirror shield  iii) ShieldMapTable : Here we specify which Shield Type is used by each of the Shield Items. [Shield_IDs.SI_Platinum_Shield] = Shield_IDs.ST_MSHIELD, -- Platinum Shield uses -- Mirror Shield sprite.
    2) ShieldTable_F.lua : Contains Necessary functions used by the client - DO NOT TOUCH THIS FILE unless you know what you are doing!!!     Ok.. So Where do i get the files? Download link     Final Note If you have any issues or doubts about the xDiff files or Lua files (I expect some in this department) let me know. So Enjoy
  9. Upvote
    Alphoccio reacted to Alexandria in Basic Complete Renewal Data English Folder   
    This data folder is a fresh and clean data folder. It does not have items custom or other modifications (Only I added some kafra cutins).

    Based upon CalciumKid's folder, OnNplay's folder, Megasantos's folder, Michieru and dastgirpojee.
    [*]Basic kRO Fonts [*]Basic Translated Textures [*]Official Hairstyles (Only if your rdata.grf has been updated) [*]553 Clothes Dyes / 251 Hair Dyes Pack [*]Kafra anime style (you can remove them if you want textureÀ¯ÀúÀÎÅÍÆäÀ̽ºillust)

     
    Data Version 4.0
    ! NOTE: This version is for 2012 and 2013 clients.
     
    Download: [Dropbox] [Mega] [4shared] [Gamefront] [Rapidgator] [Uploaded] [Putlocker] [Turbobit]
    ChangeLog:
    Fixed: Palletes are working properly.
    Added: More sprites
    Added: More textures translated
    !Merge with Client Translation Project rev. #31
     
    MD5 Hash: 10cb8c6819acc00978417dbbedfa5638
     
    ==========================================================
     
    Data Version 3.0
    ! NOTE: This version is for 2012-04-10 or older.
     
    Download: [Dropbox] [Mega] [4shared] [Gamefront] [Rapidgator] [Uploaded] [Putlocker] [Turbobit]
    ChangeLog:
    Delete all those files for pre-renewal.
    Updated idnum2itemdisplaynametable.txt by Ziu
    Updated msgstringtable.txt by TrueNoir
    Added: Dewata Quest Translated Lua v1.1 by Dastgir Pojee
     
    MD5 Hash: e3806675a03529a154d644e565bd33aa
     
    ==========================================================
     
    Data Version 2.0
    ! NOTE: This is a PRE-RENEWAL version, only for 2010 or older.
     
    Download: [Dropbox] [Mega] [4share] [Gamefront] [Rapidgator] [Uploaded] [Putlocker] [Turbobit]
    ChangeLog:
    Added: More sprites (Latest)
    Added: Official Hairstyles
    Added: More NPC sprites

    MD5 Hash: 220ae49fc6dc50ef7b8df3c49e007939
     
    ==========================================================

    Data Version 1.0
     
    Download: [Dropbox] [Mega] [4share] [Gamefront] [Rapidgator] [Uploaded] [Putlocker] [Turbobit]
    ChangeLog:
    -Initial release-
     
    MD5 Hash: 72a16ec1e3854727cf853d13d6cdbf6f
     
    ==========================================================
     
    Let me know if you have any problems
  10. Upvote
    Alphoccio reacted to iCORE in Need help. Getting Started   
    for the client you can visit Here
    * i recommend that you use full 20131223 by oissis
    -LINK
     
    for the full data folder visit Here
    * it includes clientinfo,xml
     
     
    just post your problem and we'll try to solve it
×
×
  • Create New...

Important Information

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