[Question] how to change max inventory pet size in _RefObjChar ?

11/13/2023 18:24 Judgelemental#16
Quote:
Originally Posted by JohnDornel^ View Post
Create this table

Code:
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

CREATE TABLE [dbo].[_COS_Exceptions](
	[ID] [int] NOT NULL,
 CONSTRAINT [PK__COS_Exceptions] PRIMARY KEY CLUSTERED 
(
	[ID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY]

GO
And put these IDs inside

Code:
7493
9264
10369
10370
22865
23228
23229
23309
23857
23858
29534
36634
41760
(COS_% ids for default grab pets, you can add additional ones here if you have custom made)

Go to SRO_VT_SHARD > Programmability > Stored Procedures > _AddNewCOS > Right Click and Modify.

At the end, before "commit tran" add this


if ((SELECT COUNT(*) FROM _COS_Exceptions with (NOLOCK) where ID=@RefObjID) <> 0)
BEGIN
declare @[Only registered and activated users can see links. Click Here To Register...]64 bigint
DECLARE @[Only registered and activated users can see links. Click Here To Register...] int
set @[Only registered and activated users can see links. Click Here To Register...]= DATEDIFF(s, '1970-01-01 00:00:00', GETUTCDATE()) --get curent timestamp
set @[Only registered and activated users can see links. Click Here To Register...] @[Only registered and activated users can see links. Click Here To Register...]+28*24*440000
select @[Only registered and activated users can see links. Click Here To Register...]64 = Serial64 from _Items where Data = @[Only registered and activated users can see links. Click Here To Register...]_ID
IF(NOT EXISTS(SELECT * FROM _TimedJobForPet WHERE CharID = @[Only registered and activated users can see links. Click Here To Register...]_ID))
BEGIN
exec _AddTimedJobForPet @[Only registered and activated users can see links. Click Here To Register...]_ID,5,22926 @[Only registered and activated users can see links. Click Here To Register...],1111708465,1,28,0,0,0,0,0 @[Only registered and activated users can see links. Click Here To Register...]64
END
end
enD

To modify the amount of slots there is a "28" on the "exec _AddTimedJobForPet..." line, you can edit it there. Just multiplay pages * slotsPerPage and use that number. That should be all.
Thank you for the quick response!

I could manage to unlock 7 pages, however as soon as I place an item on the 6th or 7th page I get a disconnect followed by:

[Only registered and activated users can see links. Click Here To Register...]
11/14/2023 10:43 JohnDornel^#17
Quote:
Originally Posted by Judgelemental View Post
Thank you for the quick response!

I could manage to unlock 7 pages, however as soon as I place an item on the 6th or 7th page I get a disconnect followed by:

[Only registered and activated users can see links. Click Here To Register...]
I really don't have the ability to test it right now myself, but the procedure seems to fail when placing the item. I'd assume the _InvCOS table is missing the lines for these slots. The _AddNewCOS procedure, takes the InventorySize from _RefObjChar, so try to increase that for each grab pet to 7 pages value and spawn a new pet, to build new data for _InvCOS and try again.
11/14/2023 11:52 Judgelemental#18
Quote:
Originally Posted by JohnDornel^ View Post
I really don't have the ability to test it right now myself, but the procedure seems to fail when placing the item. I'd assume the _InvCOS table is missing the lines for these slots. The _AddNewCOS procedure, takes the InventorySize from _RefObjChar, so try to increase that for each grab pet to 7 pages value and spawn a new pet, to build new data for _InvCOS and try again.
It makes sense, however:

The default InventorySize of grab pets in _RefObjChar is 140 (5 pages).
Increasing that to 196 (7 pages) crashes the GS upon loading the module.

If I manually add lines in _InvCOS then it works:
It seems like the lines are created automatically up to '139'

[Only registered and activated users can see links. Click Here To Register...]
11/14/2023 12:26 JohnDornel^#19
Quote:
Originally Posted by Judgelemental View Post
It makes sense, however:

The default InventorySize of grab pets in _RefObjChar is 140 (5 pages).
Increasing that to 196 (7 pages) crashes the GS upon loading the module.

If I manually add lines in _InvCOS then it works:
It seems like the lines are created automatically up to '139'

[Only registered and activated users can see links. Click Here To Register...]
Likely there is a check somewhere in the gameserver for it, but if what you did works.. you can just edit the _AddNewCOS procedure, inside the loop replace "< char.InventorySize" with the max amount of slots and it should do the job.
11/14/2023 12:48 Judgelemental#20
Quote:
Originally Posted by JohnDornel^ View Post
Likely there is a check somewhere in the gameserver for it, but if what you did works.. you can just edit the _AddNewCOS procedure, inside the loop replace "< char.InventorySize" with the max amount of slots and it should do the job.

Doing that allowed me to store the items in the 6th/7th tab, however upon re-logging the GS crashes.
Unfortunately that does not work...I think I'll just give up :(
01/20/2024 20:45 kaka20315#21
Can any one help me with guide to up me pick pet to 2 page instead of 1 page ?