To put it simply, I made a script that gives a player (client2) an invite to a duel fight (ScreenGui) from another player (client). I am using a RemoteEvent to get client2's answer to the invitation (it will be a true/false value, true = yes and false = no). (the original script is 44 lines long, but it has a lot of unnecessary info for my question, so here is a script that simulates what Im saying better and shorter)
local client = *player sending the invite*
local client2 = *player receiving the invite*
*the invite gui*.Parent = client2.PlayerGui
*RemoteEvent*.OnServerEvent:Connect(function(plr, answer) -- "answer" is a BoolValue to the invite (true = player accepts fight request, false = player declines fight request)
if client2 == plr then
if answer == true then
*bunch of stuff that makes a fight between the players happen*
end
end
end)
I really don't like using this method to get the player's answer to the invite. I'm currently trying to find a way to make it where a ModuleScript can be used to get the player's answers.
Please help me with this. Thank you.

2 comments
try if client2 == plr and answer == true then?
Thats what I had, but info would always bug out. I would like a better way to recieve the player's answer.