Jump to content

Tranquility

Members
  • Posts

    118
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by Tranquility

  1. Are we even able to give a flat (physical & magical) n% damage bonus these days? Or do we need to combine the magical & physical attacks to get such an item bonus?

    For the Anel do Capiroto [1] or Devil's Ring [1] I made a start, but it doesn't do what I think it should. The item should give the bonus if you have the str + 1 / str + 2 / str +3 essence compounded on _any_ item and then give the bonus effect, next to giving the default effect of +5% damage increase. This is what I have, perhaps others are able to assist to expand our item_db with these new items.

    28505,Devils_Ring,Devil's Ring,4,,,50,,0,,1,0xFFFFFFFF,63,2,136,,100,0,0,{if (isequippedcnt(4908) >= 1 || isequippedcnt(4909) >= 1 || isequippedcnt(4910) >= 1) {bonus2 bAddRace,RC_All,5; bonus2 bMagicAddRace,RC_All,5;} bonus2 bAddRace,RC_All,5; bonus2 bMagicAddRace,RC_All,5;},{},{}

     

  2. Are you using it for donation purposes?

    That aside, I myself have used a script to take a value from cp_credits (balance) and converted them to donation credits (could be cash points for you).

    This script might help you find what you are looking for:

    switch(@menu) {
    		case 1:
    			query_sql("SELECT `balance` FROM `" + escape_sql(.redeemTable$) + "` WHERE `account_id` = " + getcharid(3) + " LIMIT 0,30", .@credits);
    			if (.@credits > 0){
    			mes "How many Donation Credits do you wish to redeem?";
    			next;
    			mes .npcName$;
    			input .@withdrawCredits,1,.@credits;
    			query_sql("UPDATE `" + escape_sql(.redeemTable$) + "` SET `balance` = `balance` - " + .@withdrawCredits + " WHERE `account_id` = " + getcharid(3) + "");
    			getitem 30017,.@withdrawCredits;
    			mes .@withdrawCredits + "x " + getitemname(30017);
    			} else {
    				mes "My records indicate that there are no rewards awaiting to be redeemed.";
    				mes "My deepest apologies for the misunderstanding.";
    			}
    		break;
    		case 2:
    			query_sql("SELECT `balance` FROM `" + escape_sql(.redeemTable$) + "` WHERE `account_id` = " + getcharid(3) + " LIMIT 0,30", .@credits);
    			mes "You currently have " + .@credits + " donation credits.";
    		break;
    		case 3:
    			mes "I am here to allow for the redemption of donation credits for " + .serverName$ + ".";
    			mes "Donations may be made to the server via the control panel.";
    		break;
    		default:
    			mes "Very well then.";
    			mes "Good day to you.";
    		break;
    	}
    

    This script is a modification of the fluxcp donation NPC and where I have getitem(30017) you should be able to add/change your cashpoints. Whether you do it by writing to another database table or making a script that runs in the background is up to you.

  3. Fixed after copy/pasting the values from the git itself. For some reason that fixed the issue in mysql workbench.

    No clue where it went wrong when pulled/updated from the GIT itself.

     

    The query used is in this spoiler:

    --
    -- Table structure for `db_roulette`
    --
    
    CREATE TABLE `db_roulette` (
      `index` int(11) NOT NULL default '0',
      `level` smallint(5) unsigned NOT NULL,
      `item_id` smallint(5) unsigned NOT NULL,
      `amount` smallint(5) unsigned NOT NULL DEFAULT '1',
      `flag` smallint(5) unsigned NOT NULL DEFAULT '1',
      PRIMARY KEY (`index`)
    ) ENGINE=MyISAM;
    
    -- ----------------------------
    -- Records of db_roulette
    -- ----------------------------
    -- Info: http://ro.gnjoy.com/news/update/View.asp?seq=157&curpage=1
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 0, 1, 675, 1, 1 ); -- Silver_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 1, 1, 671, 1, 0 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 2, 1, 678, 1, 0 ); -- Poison_Bottle
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 3, 1, 604, 1, 0 ); -- Branch_Of_Dead_Tree
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 4, 1, 522, 1, 0 ); -- Fruit_Of_Mastela
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 5, 1, 671, 1, 0 ); -- Old_Ore_Box
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 6, 1, 12523, 1, 0 ); -- E_Inc_Agi_10_Scroll
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 7, 1, 985, 1, 0 ); -- Elunium
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 8, 1, 984, 1, 0 ); -- Oridecon
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 9, 2, 675, 1, 1 ); -- Silver_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 10, 2, 671, 1, 0 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 11, 2, 603, 1, 0 ); -- Old_Blue_Box
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 12, 2, 608, 1, 0 ); -- Seed_Of_Yggdrasil
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 13, 2, 607, 1, 0 ); -- Yggdrasilberry
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 14, 2, 12522, 1, 0 ); -- E_Blessing_10_Scroll
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 15, 2, 6223, 1, 0 ); -- Carnium
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 16, 2, 6224, 1, 0 ); -- Bradium
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 17, 3, 675, 1, 1 ); -- Silver_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 18, 3, 671, 1, 0 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 19, 3, 12108, 1, 0 ); -- Bundle_Of_Magic_Scroll
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 20, 3, 617, 1, 0 ); -- Old_Violet_Box
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 21, 3, 12514, 1, 0 ); -- E_Abrasive
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 22, 3, 7444, 1, 0 ); -- Treasure_Box
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 23, 3, 969, 1, 0 ); -- Gold
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 24, 4, 675, 1, 1 ); -- Silver_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 25, 4, 671, 1, 0 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 26, 4, 616, 1, 0 ); -- Old_Card_Album
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 27, 4, 12516, 1, 0 ); -- E_Small_Life_Potion
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 28, 4, 22777, 1, 0 ); -- Gift_Buff_Set
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 29, 4, 6231, 1, 0 ); -- Guarantee_Weapon_6Up
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 30, 5, 671, 1, 1 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 31, 5, 12246, 1, 0 ); -- Magic_Card_Album
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 32, 5, 12263, 1, 0 ); -- Comp_Battle_Manual
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 33, 5, 671, 1, 0 ); -- Potion_Box
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 34, 5, 6235, 1, 0 ); -- Guarantee_Armor_6Up
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 35, 6, 671, 1, 1 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 36, 6, 12766, 1, 0 ); -- Reward_Job_BM25
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 37, 6, 6234, 1, 0 ); -- Guarantee_Armor_7Up
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 38, 6, 6233, 1, 0 ); -- Guarantee_Armor_8Up
    
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 39, 7, 671, 1, 1 ); -- Gold_Coin
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 40, 7, 6233, 1, 0 ); -- Guarantee_Armor_8Up
    INSERT INTO `db_roulette`(`index`, `level`, `item_id`, `amount`, `flag` ) VALUES ( 41, 7, 6233, 1, 0 ); -- Guarantee_Armor_8Up	// KRO lists this twice
    

    EDIT: Revised and retried on an empty database, was missing a new line after the dashes in the comment section to make it work without errors for me.

  4. Hello,

     

    Upon upgrading the databases, I noticed the addition of the roulette database is proving to be difficult.

    The query from the update:

    --
    -- Table structure for `db_roulette`
    --
    CREATE TABLE IF NOT EXISTS `db_roulette` (
      `index` int(11) NOT NULL default '0',
      `level` smallint(5) unsigned NOT NULL,
      `item_id` smallint(5) unsigned NOT NULL,
      `amount` smallint(5) unsigned NOT NULL DEFAULT '1',
      `flag` smallint(5) unsigned NOT NULL DEFAULT '1',
      PRIMARY KEY (`index`)
    ) ENGINE=MyISAM;
    

    ends up with error 1064. However, I don't see where a mistake in the syntax is made to cause that.

    Running MySQL 5.5, this was tested in MySQL WorkBench with the full error being:

    Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '`index` int(11) NOT NULL default '0',   `level` smallint(5) unsigned NO' at line 1
    

    I've replaced the whole text once and typed it out myself to prevent possible characters being mistaken, but I think that shouldn't throw this error if there was something wrong in that to start with. What can be done to fix this simple issue?

     

    Kind regards,

     

    Tranquility

  5.  

     

    Disable packet obfuscation in /src/config/core.h

    /// Comment to disable the official packet obfuscation support.
    /// When enabled, make sure there is value for 'packet_keys' of used packet version or
    /// defined 'packet_keys_use' in db/[import/]packet_db.txt.
    /// This requires PACKETVER 2011-08-17 or newer.
    //#define PACKET_OBFUSCATION
    
    

    Yeah i already login ingame but it pop-up in my map-serv.sql

     

    [Warning]: Skipping packet version 33.

    [Warning]: The packet_db table only has support up to version 30.

     

    May i ask, is there any conflicts with my Diff Client?

     

    THANK YOU again!

     

    When diffing, make sure you have the "disable packet obfuscation" patch enabled.

    After making all those changes server side, make sure you've recompiled your server.

×
×
  • Create New...