False, I already tried doing that and it STILL fires. The character model is still unachored even though the player is sitting on a seat.
I tried doing that too and the events did not fire. As I said, I believe the results are unreliable, not constant. Also, I never said that the character parts were anchored, I simply said they were not-moving. This is probably because the character is welded to the seat (which is anchored).
Edit: Also wrong
As a video of evidence:
BTW, you are all amazing!! Thank you for the help so far. Carefully reading xendatros post now and will try to test.
If the part is travelling at high speed, then most likely the Touched
event will not fire. I would suggest you to use raycast and raycast only a few studs rapidly in order to detect parts when the part is flying in a fast velocity.
I ran some more tests. It seems like @ItzMeZeus_IGotHacked is correct, it is firing, my output was focused on the wrong messages so I did not see the print statements. Disregard everything I’ve said.
Though, I’m still confused as to why your event is not firing.
Also, using raycast is a brilliant solution.
Yes, the Lava part is the Primary Part of my Yellow ring Group. I move this with Tween Service.
Its actually moving quite slow, see above video in earlier post.
@xendatro I liked what you said before that you deleted, so I cant re read. I think you were on to something about the 2 anchored parts.
Yeah, my apologies. I should not have deleted all of it. Some of it was correct.
However, @ItzMeZeus_IGotHacked basically summarized all of what I said earlier.
Edit:
Scratch that I just learned that you can revive posts.
I wouldn’t exactly use TweenService to move the fireball, but if you do, I would recommend just use raycast as a way to detect touching objects. Since it is far more accurate.
@ notzeussz Thank you so much for this help!!
What do you recommend instead of tween service to move fire ring? Anything is good. I only use tween because I am a new programmer and that is what I know.
Also, I’ve never used Raycast!! I’ll need to learn it. Do you have any general tips for setting this up? I’m also going to look into Raytcasting in youtube.
Yeah, it’s TweenService. That’s the culprit. I ran yet another experiment and the event did not fire.
That will require some physics instance… I would normally just use BodyForce which applies a force on a part to a specified direction.
TweenService does not prevent a part from being registered as Touched. It just changes a given property periodically.
OP try this:
local safeSeats = {workspace.Seat, workspace.Seat2} -- Add your seat instances here, or you can tag them using CollectionService and doing CollectService:GetTagged("TagName")
local damage = 25
script.Parent.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
if not table.find(safeSeats, hit.Parent.Humanoid.SeatPart) then
local plr = game:GetService("Players"):GetPlayerFromCharacter(hit.Parent)
if plr and not plr:GetAttribute("LavaDebounce") then
plr:SetAttribute("LavaDebounce", true)
hit.Parent.Humanoid:TakeDamage(damage)
wait(2)
plr:SetAttribute("LavaDebounce", false)
end
end
end
end)
No, it’s because both parts are anchored, I believe. We’ve established that repositioning anchored parts into each other do not fire the touched event.
As long as the CanTouch property is enabled, that wouldn’t matter.
Edit: Anchored parts, sure. But the player isn’t anchored.
Its past bedtime in my time zone, so I need to log out for the night.
THANK YOU everyone for the help so far!!
My next steps in the morning will be:
@ SovereignFrost, thank you for the code (updated) I will try it!!
@notxeussz, I will try to learn how to use BodyForce, incase tweenservice is the problem.
@xendatro, Thank you, both parts anchored makes sense to me, I will experiment with this by trying BodyForce.
THANK YOU ALL AGAIN!!! I’ll report the progress in under 12 hours.
Based on the fact that anchored parts do not fire the touched event when its position property is changed (which is true, you can try it) and the fact that TweenService merely changes a property over a certain time, that would imply that the event should not fire.
The lava is detecting a touched event from the player, which is unanchored. It isn’t checking against the seat. Check this file, it does exactly what the OP wants using TweenService.
LavaMove.rbxl (34.7 KB)