Rocks Module - Useful for Anime Games Skill Effects

I made this a while ago after GPO String showcase launched and decided to release it to the public.
It uses Part Cache to reduce a bit of the lag it may cause.

GPO STRING SHOWCASE

ROCKS SHOWCASE

Tutorial:

  1. Require the module in the client, for example: require(game.ReplicatedStorage.Modules.RocksModule)
  2. Use the “Ground” function of the module with the following arguments:

Arguments: {Position, Distance, PartSize, RaycastFilter, AmountOfRocks, IceEffect, DespawnTime}

  • Position: The target’s position, needs to be a Vector3;
  • Distance: The distance of the rocks from the center;
  • PartSize: The base size of the part, needs to be a Vector3;
  • RaycastFilter: A table of instances that won’t be affected by the raycast, it can be nil;
  • AmountOfRocks: The desired amount of rocks;
  • IceEffect: If you’d like it to have a ice/snow effect on it, it can be either false or true;
  • DespawnTime: The duration of the effect.

Example: RocksModule.Ground(player:GetMouse().Hit.Position + Vector3.new(0, 1, 0), 35, Vector3.new(6, 4.5, 6), nil, 20, false, 3)

IMPORTANT

  • Don’t use this on server side, it will throw an error and even though it can be easily solved in the module script, you still should not use visual effects on the server;
  • Sadly, this module only works over parts, meshparts and unions. If I ever find a decent solution for it, I’ll be updating this;
  • Currently this works only on ground;

Result of the example script:
image

Thanks for your attention!

CLICK HERE TO GET THE MODEL

71 Likes

Looks interesting, what does this effect do over water or terrain? Or, does it just work over parts?

3 Likes

Hi, thanks for pointing that out, I tested it here and sadly it doesn’t work with any kind of terrain, so it can only work over parts.
I’ll add this information in the post, thanks!

Can rocks be created in the wall?

1 Like

Nope, sadly.
As I didn’t personally need it to be in the walls, I didn’t try it.
I may take a look at this functionality in the future.

do i need to put some script on skill effect

What do you mean? To use it, you only need to require it and use the function like in the example I presented.
You don’t have to change anything inside the module itself if you don’t want to, it does all the cleanup for you too.
If you need anything else, please send me a direct message here or in discord so it doesn’t fill the reply section. Thanks!

Oh now i get it now btw thank you

1 Like

this module is great, however when creating this it seems that the creation is “instant”, and not have some sort of animation, is there a way i can work my way out of it?

I used to have a tween on it, but it caused it to sometimes not create the roof part and the looking weird. There probably is a way, but I can’t really do anything currently due to my limited time.

A really great module! Being able to use this module to make linear rocks effect instead of just 1 circular rocks effect would be really awesome, but other than that, this is really good!

1 Like

helpful cuz idk how to do maths

I keep on getting an error, on line 26.

attempt to perform arithmetic (div) on number and nil 
local humanoidHeightScale = Hum.BodyHeightScale.Value
local scaleY = 3 * humanoidHeightScale

local charPos = HumRp.Position
local changeY = Vector3.new(0, scaleY, 0)
local charFloorPos = charPos - changeY + Vector3.new(0, 1, 0)

print(charFloorPos)
RocksModule:Ground(charFloorPos + Vector3.new(0, 1, 0), 35, Vector3.new(6, 4.5, 6), nil, 20, false, 3)
1 Like

Is there any way to make this server sided?

Why would you make this server sided? It would just cause more lag and delay.

Cloud assume its only working for one client at the moment?
Try using fire all clients so everyone can see it if that is the case.

I have an idea but idk if it can work with meshes, but maybe you can draw a sphere on the surface you want the crater on, and put the rocks wherever the sphere intersects the surface?

Everytime a fix an error with this module it just creates a new one.

Same thing is happening for me, I tried going into the module to see if I could improve any variables but I get new errors. In the end I reversed my edits, now I’m just stumped.

I recommend you NOT to use it at its current state, I’m working on a new module that has a way better execution of the code and a proper utilization of the PartCache.
It will also contain some other effects that can come useful for some people.

1 Like