SimpleCast - An Alternative to FastCast

Thanks. I’ll be sure to send some videos and link some games when I get some substantial work done!

A repository on GitHub would be fantastic. Unfortunately I don’t have many suggestions - just stumbled across this and I’m just playing about with it right now, but one could be to have trails built-in - not sure how this could be achieved but I could try prototyping my implementation then send it to you?

I’m a bit of a noob when it comes to stuff like this - I can script but I’m not an expert :sweat_smile:. What is a SharedCache?

2 Likes

So when I say Cache I am referring to “Object Pooling Design Pattern”.

If we go back to FastCast you have to create a new instance of your bullet every time you fire. (Unless you implement PartCache then you can avoid that) I decided that SimpleCast will have its Cache built in so you can pass it your bullet instance and it will create them for you and pool them.

My idea for a SharedCache is, “what if we have more then one caster that uses the same bullet instance?”. Currently, if you set up two casters with the same instance you would have two caches. The main reason I have not added it yet is because the big question of, “will this really improve performance?” is still bugging me. I need to do some testing to find out if it would be helpful.

1 Like

That sounds really interesting. If you don’t end up doing it, would you mind if I implemented this concept into my edit?

Sure I do not mind at all. Good luck on your project.

1 Like

idk how to use it bwuh maybe pls halp nvm aisle do it mysalf

I dont’ know about anyone else, but I’m having an error:


Can anyone please help?

1 Like

So I accidently saved a change to the demo place. I was messing with Parallel Lua. Sorry about that lol. Just regrab the module from the demo place or model.

Lol thanks no problem
Good module broski

1 Like

Hi, do you have an weapons you could add to the demo place to check out?

Thanks

Right now, I made it so can collide and everything is on. But, after a few short seconds it phases through the ground. how can I fix this?

1 Like

Can you show me a video/show your code. You can DM me.

Also a quick check after it collides do you terminate the cast?

I have messaged you privately.

-coolguyweir

1 Like

I can create some simple ones. I will upload them to a second demo place.

Cool, thanks. What is the link to the second demo place?

how exactly did u go about benchmarking this?

As a noob with no games under my belt should I use this I can’t really understand the example code if someone could explain it more easily that would be nice. Or example / template

1 Like

Hello, I would recommend taking a few steps back and go back to the basics.

Here are some great sources:

https://create.roblox.com/docs

I can provide some more sources if needed. Learning the basics is really important. It takes some time but, once you have a good foundation understanding what I am doing in the demo place because 100% easier.

If your still in school I also recommend maybe trying to get into a class that deals with programming.

Good Luck! :slight_smile:

1 Like

I know how to code just dident make games yet

This is pretty neat. Works great and runs a fair amount faster than my own projectile system.

it’s worth noting that it seems to cause major lag spikes when the pathfinding service is involved.

It’s probably due to the bullets being cached in such a faraway spot, causing the pathfinder to make some crazy estimates at first. It’s easily fixable by simply putting moving the spot much closer, say just under the map.

2 Likes

Is this simple? Reading through this it kind of feels like reading Spanish. (Which I don’t speak)
Something about it, it’s just written in a really unusual way that doesn’t bode well for readability I feel.

Doesn’t “feel” like most Roblox Lua code I’ve looked at and made, per say. Finely written but just hard to absorb.

1 Like