#Code being kind of finnicky
1 messages · Page 1 of 1 (latest)
are you unable to use 'debounce' instead of a value for can/cant interact? im trying to understand lol
?
the caninteract variable is used for some other scripts
oki and is this what the remote event triggers..?
the remote event triggers the dialogue itself
and the function is called when it's over
alrighty i think i have a better idea of what you're doing..? and i wanted to ask, if 'activator' is the player then you might be able to just access your folder through that insead of through Players and player.name, which is what I did in my recreation;
prox.Triggered:Connect(function(activator)
-- for me, activatoris the player, and I was able to access my folder like:
local MyFolder = actv:WaitForChild("Folder")
-- then my bool object
local isInteracting = MyFolder:WaitForChild("InteractingBool").Value
-- i just did the bool value for my example btw lol..
if not isInteracting then -- aka , if interacting is false then...
isInteracting = true -- now, we are marked as interacting (true)
-- now the remote event cant be fired unless it's changed back to false!
print("Interacting =",isInteracting,
"----------------------------"
)
startDialogueRE:FireClient(activator)
end
end)
(i tried to replicate the code to understand, sorry if my questions seemed silly)
i dont think that has anything to do with your issue though 🫠
im still looking
oh right are you trying to change the bool & string values via local script when the dialogue has finished? this only changes that on the local side, so when you detect on the server side it has not changed for the server, when the dialogue finishes, use a server sided script to update your values
local and server side can be confusing
i would do this, but i dont know a way to get the name of the player who the dialogue is supposed to end for
** You are now Level 12! **
i named this block "super cool block" [first image, server side]
then when triggering a local script it will rename it to "super lame block" [second image, my local side]
on the server, it will still be super cool block, but for me its lame, local scripts will see it as lame, and server scripts will see it as cool
if the dialogie is a local script, you can send the username of the player from the local to the server which the server will update the values as well, if im getting this right lol
i had that example backwards.. but yeah
pretty sure, yes 🤔 if the endDialogue is a local script then you can get the player the basic ol' game.Players.LocalPlayer way
you can pass any value you want really in remote events, rather is be string, bool, wtv
thanks!