(SOLVED)Orb spawning help

Hello developers!

I am trying to create an ability that summons orbs around the player and spawn a ray. However none of the orbs are spawning or appearing at all, and how should i make it spawn around the player? Thank you!

Code:

local TS = game:GetService("TweenService")
script.Parent.OnServerEvent:Connect(function(plr)
	
	local orbs = game.ReplicatedStorage.Orb:Clone()
	orbs.Parent = plr.Character.Head
	local laser = script.Parent.Parent.Parent.Parent.laser
	
	wait(0.5)
	orbs.A1.A.RoughSwishThing.Rate = 4
	wait(0.1)
	orbs.B1.A.RoughSwishThing.Rate = 4
	wait(0.1)
	orbs.C1.A.RoughSwishThing.Rate = 4
	wait(0.1)
	orbs.D.A.RoughSwishThing.Rate = 4
	wait(0.1)
	orbs.E.A.RoughSwishThing.Rate = 4
	wait(0.1)
	
end)
3 Likes

So is this orb a particle or a part?
if it is a part then you should set its position to the player first ( and weld it the player if you want those orbs follow player)

2 Likes

Its a part that has an attachment in it with a particle emitter. Like the first one with orbs, A1 is the part name, A is the attachment name and RoughSwishThing is the particle emitter

1 Like

Are there any error messages in output? And where is your code located? Local script or script?

1 Like

This is a serverscript, and no, no errors either

Send me screenshot ReplicatedStorage and all childs of orbs

Why are you making the Rate 4? Why not set it at 4 manually in each of the ParticleEmitter Properties and just make Enable = true or false

And as @tienke said, you can’t just make the Orb Part parented to the head, you have to Weld it.
If you go into test mode search the Orb in the Explorer window inside the Player in the workspace. If you don’t Weld it to the head it’ll just drop through the baseplate (assuming it’s CanCollide off).

I just realized that was an option lol, i am new to particles. Thanks!

image
Here is the image of rep

Do

wait(0.5)
orbs.A1.A.RoughSwishThing.Rate = 4
orbs.A1.Parent = plr.Charecter.Head
wait(0.1)
orbs.B1.A.RoughSwishThing.Rate = 4
orbs.B1.Parent = plr.Charecter.Head

etc

So parts will be spawn i think

1 Like

They don’t seem to be attaching to the character, It does spawn now though, Thanks!

U can read here. This will help you attach the parts.

1 Like

Ok thank you so much, i will check it out

Flag the post that solved the problem if the problem is solved

1 Like

Well it kinda works, it is now hovering above me like a halo lol idk how to set the pos of each orb

1 Like

Do you want them set around your head, or inside your head?
Welds have a Part0 and a Part1, but they also have a C0 and a C1, which are the offsets.

I’ve seen other posts about having Pets that orbit around a player. If you’d like to see how they do it search those posts.

Its not supposed to be just the head, its supposed to go around the entire character, however it doesnt matter as it just goes above my character like a halo and not around it like a semi circle.

1 Like

So as I said, if the part is welded to your head then set the Weld.C0 and Weld.C1 properties to create the offset.
It may just be better to weld them to your HumanoidRootPart instead.

And please reply to the person you are posting to.
Since you replied to yourself I didn’t get a notification about it.

I have tried that, and it isnt working, im using C0 and C1 to change the rotation and position, and its not doing a thing(maybe because im new to this and i dont know how this works).
Is this the correct usage of C0 and C1?

	weld.C0 = CFrame.Angles(90,0,0)*CFrame.new(5,0,0)
	weld.C1 = CFrame.Angles(90,0,0)*CFrame.new(5,0,0)

Yes, but instead of changing them both to the same spot they need to be offset. The way you are doing it makes the weld at a different spot, but the same in relation to both Parts.
Try leaving out setting the weld.C0 line and just put the second line in.
Then change the CFRame angles and values to position the Part where you need it.