Hercules icon indicating copy to clipboard operation
Hercules copied to clipboard

Hercules Ultimate Storage System

Open dastgirp opened this issue 4 years ago • 22 comments

Pull Request Prelude

Changes Proposed

Design

Implementation of the Hercules Ultimate Storage System Storages can now be created through a configuration file that describes their attributes. Example storage configuration:

{
        Id: (int)                              (required|unique) Unique Identifier
        Name: (string)                         (required) Name of the storage sent to the client.
        Capacity: (int)                        (required) Maximum capacity of the storage.
}

Additional storages are handled with dynamic arrays that will save a tonne of memory when created, as opposed to a design in which they were implemented using fixed length arrays. In simple terms, a storage of 600 items would approximately cost the same amount of memory as 600 storages with 1 item each. They are saved in the same storage database (SQL) as the original separating them by a storage identifier. An infinite number of storages can be created, there are no limits. The current design implementation only allow saving/loading of approximately 1600 items per storage due to packet size limits.

PS. Make sure you apply SQL upgrades for this patch!

Access Modes

Storage access modes can be set through the openstorage builtin command.

	STORAGE_ACCESS_VIEW     // View storage only
	STORAGE_ACCESS_GET      // Allow getting items from storage.
	STORAGE_ACCESS_PUT      // Allow putting items to storage.
	STORAGE_ACCESS_ALL      // Allow all actions.

Default storage mode : STORAGE_ACCESS_ALL

Script Commands

Changed: openstorage(<storage_id>{, <storage_mode>})

Issues addressed:

  • [x] https://github.com/HerculesWS/Hercules/pull/1763

dastgirp avatar May 16 '20 18:05 dastgirp

from ci, look like shadow variable i

4144 avatar May 16 '20 19:05 4144

Windows compile fine for now, will be checking linux warnings and errors soon.

dastgirp avatar May 16 '20 19:05 dastgirp

In my opinion the Xcode upgrade should not be part of this PR since it's not required.

Kenpachi2k13 avatar May 23 '20 17:05 Kenpachi2k13

In my opinion the Xcode upgrade should not be part of this PR since it's not required.

Ok, will remove it, I had just migrated it from old code to new code

dastgirp avatar May 24 '20 05:05 dastgirp

@4144 @Kenpachi2k13 can you review again?

dastgirp avatar May 24 '20 06:05 dastgirp

nice bro

bWolfie avatar Jun 08 '20 08:06 bWolfie

Anyone currently using this on their server?

bWolfie avatar Jun 09 '20 13:06 bWolfie

@dastgirp you can complete this?

4144 avatar Jul 26 '20 02:07 4144

dreams come true :D?

Vaans avatar Oct 28 '20 19:10 Vaans

@dastgirp something about that?

SombraRO avatar Nov 19 '20 14:11 SombraRO

@Kenpachi2k13 updated to latest commit and made all changes that were mentioned by you.

dastgirp avatar Nov 28 '20 13:11 dastgirp

look like compilation errors in all or most jobs

4144 avatar Nov 28 '20 14:11 4144

look like compilation errors in all or most jobs

was problem with scope, fixed it.

dastgirp avatar Nov 28 '20 17:11 dastgirp

@dastgirp Can you complete this? Seems to be having conflicts again... =(

pazkero avatar Feb 15 '21 21:02 pazkero

@dastgirp Can you complete this? Seems to be having conflicts again... =(

It was already completed but for some reason not merged, If it is going to be merged in next cycle, I can fix the conflicts again, but without confirmation, it would just keep on conflicting with every new release, so, I won't be fixing conflict as of now until confirmation is received or some changes are requested.

dastgirp avatar Feb 16 '21 04:02 dastgirp

By the way, quick question, is there a particular reason why you began storage IDs at 1 instead of 0 and did not made a default storage ID? (ie. When no storage ID is specified, default to 0 and open the basic storage)?Just curious, no need to rewrite anything on my account 😅As for milestones and etc I don't know, GitHub said it was waiting for @Kenpachi2k13 to review but I don't know if that's true or not =/But it might be related to why the PR has no tags and wasn't merged already?

pazkero avatar Feb 16 '21 07:02 pazkero

Does anyone have any news about?

sgsilva avatar Jul 01 '21 15:07 sgsilva

 It was already completed but for some reason not merged, If it is going to be merged in next cycle, I can fix the conflicts again, but without confirmation, it would just keep on conflicting with every new release, so, I won't be fixing conflict as of now until confirmation is received or some changes are requested.

It's officially on hold, I believe.

-- Sent from Yandex.Mail for mobile

12:10, July 1, 2021, Bruno Silva @.***>: Does anyone have any news about?

—You are receiving this because you commented.Reply to this email directly, view it on GitHub, or unsubscribe.

pazkero avatar Jul 01 '21 15:07 pazkero

Any news about this?

waken22 avatar Nov 05 '21 04:11 waken22

One day it will become a reality. Lol.

bWolfie avatar Nov 12 '21 02:11 bWolfie

@dastgirp @MishimaHaruna can we have a definitive merging window and finish this?

csnv avatar Sep 19 '23 22:09 csnv

Four years already :'(

Vaans avatar Feb 16 '24 14:02 Vaans