Hi, this module looks extremely interesting. I have a quick question though, would this theoretically be possible to load assets on demand? For example, when someone opens a shop menu it just “knows” and automatically loads those assets, and unloads assets that won’t be needed? I know it’s possible, just very hard but thought this could be something this module could do extremely well.
Yes, it is!
button.MouseButton1Click:Connect(function() require(game.ReplicatedStorage.PreloadService).Load(script.Parent:GetDecendants(), "None", nil require(game.ReplicatedStorage.PreloadService.Completed.OnClientEvent:Connect(function() --In the future, I plan on adding "codes" to it to make it so it only fires when you're loading the menu, but for now this will have to do. If you dont want it that way, just delete the event here. script.Parent.Visible = true end) end)
I did reread your request, and it sounds like it could be an actual feature! I might add it, if I do I will add a credit for you in the Info menu
That’s super cool, thanks for sharing.
PS: Are there any updates on server sided loading? Think that would also help speed-up things. Side note, got a Discord where we can chat?
It’s coming with the Admin Panel, which will be coming soon. I still need to get some code and UI finished.
My discord is Pixlz#4627 if you wanna chat
If I had to guess, only a few more days before 2.0! Thank you all so much for all of the support. It really does mean a lot to me. Expect 2.0 very soon!
Please note that Player Management will not work in studio!
I also decided to make a PS Discord Server!
For if you don’t have DevForum member, and have a feature request or bug.
When 2.0 comes out, I will rewrite the topic again.
About 2 frames left, and a lot of code!
In the meantime, I made this.
PreloadService Theme Sharing Thread - Bulletin Board - DevForum | Roblox
Glad to say that I’m on track for a release tonight!
Making last minute improvements and fixes, stay tuned!
UPDATE: y pc just took a small update for 20 mins straight… may be delayed.
Yep, I updated the module!
Please reread the topic if you have the time, there’s some pretty big changes.
If you have a new bug, feature request, or issue, feel free to reply!
Note: If it says [Disabled] in the Admin Panel section, then it’s intentionally broken as the code isn’t finished.
Thanks everybody for the 1 month wait!
Also, the beta [PS Blue] is moving to request only for the time being. Thank you for undertsanding
I got this error. How do I fix this?
Did you move the module directly into the folder, taking it out of the ServerScript?
The module is on the Serverscript.
So, my fix;
Delete the code you have
Get it again from the library
Put the script that comes out of it in ServerScriptService
Replace like 11 of the ServerScript with this
moduleNotRequire.Parent = game.ReplicatedStorage.Modules --because that's the location specified in the error
Can I see the code that you’re firing the module from? I cant reproduce it, trying to reproduce it from “Game” now
Here is my code
local ReplicatedStorage = game:GetService("ReplicatedStorage") local PreloadService = require(ReplicatedStorage.Assets.Modules:WaitForChild("PreloadService")) PreloadService.Load("Game", "Default", nil) PreloadService.Completed.OnClientEvent:Connect(function(Time) print("The game loaded in "..Time.." seconds!") end)
I was able to reproduce it.
Give me 5ish minutes. Thanks for reporting!
Ok, so it’s being really weird, I cant repo it in my main testing game, but the issue wont go away in a baseplate. Give me a bit more time to track it down.
Sorry for the wait, I found the issue, and patched it
Thank you, the problem is fixed now.
While working on v2.1, I decided to do a mass loading test, and it’s a success!
Now, you can say that the test results show that it’s safe to use for large games!!
2.1 coming soon!