ProfileService & Knit (NEW UPDATE)

Hello Developers,

My friend @HeatSquared just made and updated a module name ProfileService & Knit (NEW UPDATE). The model will help you to set up ProfileService faster and handle your experience data more efficiently. The model is very easy to use and set up. You can use this model to help your experience manage data better and prevent data loss from your experience to make your experience more enjoyable when the players visit your experience.

NOTE: If you have any problems with setting up the model. You can contact @HeatSquared with the contact information I provided below!!

~~ Full module credit goes to @HeatSquared!! ~~


UPDATE NOTES:

Update v1.0.0

In this new update, the knit will be able to replicate datas to client. For more information, please install the knit and look for the #README file that was in the folder name “ProfileService (Replica)”

Update V1.0.5

Removal of ReplicaService, Overcomplicated. This package was designed for “newbies” to be able to have easy control over their data, and make it simple for them to add a datastore. Entire recode. This module itself was quite old it has various amounts of just “nonsense” I’ve recoded it and added more features that ProfileService offer. Seperate from Knit. Knit is varies amongs people, some people know it others done. Thats why I have created a seperate module for people to use. If you dont know how to use Knit then you are able to use the module.

Documentation.

Previous one lacked a documentation, so ive added one here!

(If you’re still confused send me a message on discord)

Removal of Bloat.

The packages this service comes with contain over 10+ packages. I’ve removed any unneccary ones this service has come with to remove bloat.

@ Info

If you come across any bugs or issues let me know by messaging me on discord. You may NOT sell this product nor claim it as your own.

@ Methods


:getProfile(player)

  • Returns the profile of the player

  • Data accessed via Profile.Data

  • Example Usage >

local Success, Profile = DataService:getProfile(Player):await()
local Data = Profile.Data

:ViewProfile(UserId)

  • View the players profile, any edits will not be saved.

  • Method of viewing data of a player regardless if they are online or not.

Example Usage:

local Profile = DataService:ViewProfile(150918901)

OR

local Profile = DataService:ViewProfile("150918901")

:WipeProfile(UserId)

  • Wipes the data and profile of a user, compliance with GDPR

Example Usage:

DataService:WipeProfile(150918901)

OR

DataService:WipeProfile("150918901")

:AddGlobalUpdate(UserId, Key, Value, Method)

Current available methods type are “Add”, “Reduce”, “Change” for now. Method “Add” and “Reduce” only works on number values.

  • Changes a certain key of data to a new value specified.

Example Usage:

DataService:AddGlobalUpdate(150918901, "Coins", 50, "Add") -- adds 50 coins to their data
DataService:AddGlobalUpdate(150918901, "Coins", 50, "Reduce") -- removes 50 coins to their data
DataService:AddGlobalUpdate(150918901, "Coins", 50, "Change") -- Sets their coins to 50
DataService:AddGlobalUpdate(150918901, "Banned", true, "Change") -- bans player
DataService:AddGlobalUpdate(150918901, "Banned", false, "Change") -- unbans player

If you would like to see anything new added let me know. This version does not send data to the client, youll have to do that yourself.

(untested but im sure it works yes)


Download link:

Link - ProfileService & Knit (REPLICATE RELEASED)


Contact Information:

Discord @ heatsquared
Roblox @ heatsquared
Email @ inquiries@heatsquared.online

Any requests please send them to my DM’s on discord or my email :slight_smile: - @HeatSquared


Tutorial:

Video - https://www.youtube.com/watch?v=H_-AVyhX7QM


HOW TO USE AND SETUP THE MODEL

Setup:

If you do not know how to use Knit I’d recommend not using this.

  • Install the model
  • Import model into your game
  • Open the folder that says “ProfileService & Knit”
  • Open the sub-folders and drag everything from inside them into the correct place

For example, Open ReplicatedStorage and drag everything inside of it into ReplicatedStorage Do not drag the folder named ReplicatedStorage itself.

How to add data:

To add data open up the module named “DataService” This can be found in ServerScriptService > Services. The data is at the top of the script named “Template” Any extra data you want can be added there.

Changing data via script

To change the player’s data from another script you can use:

Knit.GetService(“DataService”)

Once you have the service, you can run the function “getProfile(player).Data” and change the player’s data from there.

Example:

local Success, Profile = DataService:getProfile(Player):await()
local Data = Profile.Data

The data you change will be saved automatically.

10 Likes

If you have any question, you can ask here and I will try to answer you!

1 Like

Does this also replicate instantly to the client?

Please dm HeatSquared on Discord, he wants you to talk with him!!

I have questions:

  1. How long does it take to send GlobalUpdate?
  2. Will it work with Tables or Multiple values in future.

Contact HeatSquared on discord for more info.

  1. How long does it take to send GlobalUpdate?

GlobalUpdates vary, if you send a update to a offline profile, and they join they will get the update.
After running AddGlobalUpdate() it will take around 30 seconds to actually send
To then reach another server it can take upto 8 minutes? APPROXIMATELY

  1. Will it work with Tables or Multiple values in future.

I think so? Its “Change” that will update a table youll have to use it similar to UpdateAsync
You get the old data, change what you want then send it as a global update

again contact HeatSquared :slight_smile:

1 Like

(I’m heatsquareds friend fyi)

W/O Knit didnt work upon this release, it was updated around 2-5 days ago
Gloabl updates also didnt work ^

It has been updated so it works, please ensure the version is upto date

1 Like

i was just wondering, if it was instant :C
I imagined like, instead of ProfileService making it work on player itself everytime, i was thinking, if it works as “TargetPlayer” it would have let me add item into Inventory of Player2 from Player1

I have a way to make it happen in ProfileService with using another value to detect if that value changed, add it to Player’s Datastore etc.

I mean like

What i have:

  • GiftMoney Value.
  • Player send money to “GiftMoney” of target player.
  • Target player detects whenever GiftMoney changed, add it to his own Value.

What i imagined:

  • Directly sending it to player with ID as target instead of another value.

I mean, you could use message service, check if a player is in game.
If so then update profile via that, else use globalupdate.

Im 99% sure Profile:Save() also updates this instantly (global updates) but im not sure.
ProfileService has a delay between GlobalUpdate check thats why it is a little slow, could dig in source code to see if you can make it faster.
Unsure

1 Like

I searched but didn’t seem anyone that made it happen instantly :C

Contact Heat im sure he will come up with something for a update soon :+1:

1 Like