Hello
I'd like to share something that I made just for fun, nothing useful about it I think, I had nothing to do at the time, so...
I call this "GM special equipment coupon", you can give this to your GM using /makeitem or _ADD_ITEM_EXTERN Stored procedure
- What it does? It remove everything from your GM inventory and adds all sorts of new power equipment (which you can change yourself in the SP)
- What equipment does it add? Read the item description on the screenshot :P
- Any requirements? Just one, your GM must wear any equipment set and weapon (level 1 or whatever)
- How to use? just right click on it.
- Anything else? BE SURE you change parameters in SETTINGS section part in the Stored procedure to match your database items. (Read about NEW SP below)
Now the boring part:
- Database:
_RefObjCommon
_RefObjItemCode:INSERT INTO _RefObjCommon VALUES (1,46027,'ITEM_GM_GEAR_HA_COUPON','???? ???? ??? (???)','xxx','SN_ITEM_GM_GEAR_HA_COUPON','SN_ITEM_GM_GEAR_COUPON_TT_DESC',1,0,3,3,3,1,180000,3,0,1,1,1,3,0,1,0,0,129,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'xxx','item\etc\drop_mall_scroll.bsr','item\etc\coupon_avatar.ddj','xxx','xxx',46027) INSERT INTO _RefObjCommon VALUES (1,46028,'ITEM_GM_GEAR_LA_COUPON','???? ???? ??? (???)','xxx','SN_ITEM_GM_GEAR_LA_COUPON','SN_ITEM_GM_GEAR_COUPON_TT_DESC',1,0,3,3,3,1,180000,3,0,1,1,1,3,0,1,0,0,129,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'xxx','item\etc\drop_mall_scroll.bsr','item\etc\coupon_avatar.ddj','xxx','xxx',46028) INSERT INTO _RefObjCommon VALUES (1,46029,'ITEM_GM_GEAR_GA_COUPON','???? ???? ??? (???)','xxx','SN_ITEM_GM_GEAR_GA_COUPON','SN_ITEM_GM_GEAR_COUPON_TT_DESC',1,0,3,3,3,1,180000,3,0,1,1,1,3,0,1,0,0,129,0,0,0,0,0,0,0,-1,0,-1,0,-1,0,-1,0,-1,0,0,0,0,0,0,0,100,0,0,0,'xxx','item\etc\drop_mall_scroll.bsr','item\etc\coupon_avatar.ddj','xxx','xxx',46029)
- Stored procedure in [SRO_VT_SHARD] database (NEW): SRO_VT_SHARD - [SP] - _ADD_GM_GEAR.sql.txtCode:INSERT INTO _RefObjItem VALUES (46027,1,2,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5000,'????',1,'??????',-1,'RESURRECT',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',0,0,0) INSERT INTO _RefObjItem VALUES (46028,1,2,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5000,'????',1,'??????',-1,'RESURRECT',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',0,0,0) INSERT INTO _RefObjItem VALUES (46029,1,2,0,0,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,5000,'????',1,'??????',-1,'RESURRECT',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',-1,'xxx',0,0,0)
Updates:
- Default value of gear type setting sets to "C_RARE" cause not all degree has "SET" attribute.
- GM level check disabled (you can re-enable if you need it)
- Now automatically adds leading "0" when SP called using single digit degree parameter. (Example: the parse of '7' becomes '07' automatically) (Thanks to P0kemonMast for testing)
- Update to @RefCharID for Euro Char on BR110 db (Thanks to blacksheep25 for information)
Stuff that NEEDED TO BE CHANGED in that NEW SP ("SETTINGS" section):
- Stored procedure in [SRO_VT_LOG] database: (ADD THIS IN YOUR EXISTING _AddLogItem procedure, you can put at the most bottom line if you want)Code:-- @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -- @@@ BEGIN: SETTINGS -- CHANGE THIS! -- CHANGE THIS! -- CHANGE THIS! (if needed) -- (Represent ITEM_CH_BOW_11_SET_B_RARE), change as you need it DECLARE @GearSuffix VARCHAR(16) = 'C_RARE' -- (Represent ITEM_ETC_AVATAR_W_GM_UNIFORM), change as you need it DECLARE @uniSuffix VARCHAR(16) = 'GM_UNIFORM' -- (Represent ITEM_MALL_AVATAR_W_NASRUN_S_BLUE), change as you need it DECLARE @DSSuffix VARCHAR(16) = 'NASRUN_S_BLUE' -- Represent custom title, change as you need it DECLARE @HwanLevel TINYINT = 9 -- Change these if you want DECLARE @Strength INT = 10000 DECLARE @Intellect INT = 10000 DECLARE @RemainGold INT = 1000000000 DECLARE @RemainSkillPoint INT = 15000000 DECLARE @InventorySize INT = 93 -- Gift Silk DECLARE @GiftSilk INT = 1000 -- @@@ END: SETTINGS -- @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
- Media:Code:IF (@Operation = 41) -- scroll is used BEGIN IF (@ItemRefID BETWEEN 46027 AND 46029) -- GM coupon BEGIN DECLARE @CharName VARCHAR(64) = (SELECT CharName16 from [SRO_VT_SHARD].[dbo].[_Char] WHERE CharID = @CharID) DECLARE @GearType VARCHAR(16) = CASE WHEN @ItemRefID = 46027 THEN 'HEAVY' WHEN @ItemRefID = 46028 THEN 'LIGHT' WHEN @ItemRefID = 46029 THEN 'CLOTHES' END -- 11 = Degree, 16 = Da PLUS EXEC [SRO_VT_SHARD].[dbo].[_ADD_GM_GEAR] @CharName, @GearType, 11, 16 END END
itemdata_45000.txt: itemdata_45000.txt
textdata_object.txt: textdata_object.txt
DDJ: (put it in Media\icon\item\etc\coupon_avatar.ddj)
http://openclient.sroinfo.com/op/iSR...pon_avatar.ddj
NOTES:
- You need to make sure that your "_AddLogItem" procedure is working. So If you use Evangelion SR_GameServer, you should set "disableLog = 0" in misc.ini and restart the gameserver.
- And also, you can always utilize the new SP directly from SQL query window if you want, simply by doing: "EXEC [SRO_VT_SHARD].[dbo].[_ADD_GM_GEAR] 'Charnamehere', 'LIGHT', Degree, Plus" (change the LIGHT to HEAVY or CLOTHES)
This scroll supposed to be for GM, but if you want this for normal players, simply remark the GM level check in the SP, like this:
Video:Code:/* PRINT 'Validating GM Level...' SELECT @GMLevel = sec_primary, @AccountName = StrUserID FROM [SRO_VT_ACCOUNT].[dbo].[TB_User] WHERE JID = @UserJID IF (@GMLevel IS NULL OR (@GMLevel > 6 AND @GMLevel < 10)) BEGIN RAISERROR('Account ID associated with this char: %s, does not have GM prvileges. Sequence canceled!', 1, 16, @AccountName) RETURN -3 END */
Spoiler:
Screens:
Spoiler:
Good luck and have fun ;)









Reply With Quote


