Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Is it possible to send a friend request w/ a custom Player List? [SOLVED]

Asked by 4 years ago
Edited by DeceptiveCaster 4 years ago

Okay so I have a custom leader board in which I have incorporated a drop down menu with buttons including: Send Friend Request, follow and report. I have been looking far and wide for some sort of a function or service that will allow players to send a friend request from my custom leaderboard.

I found a service called FriendService but theres no documentation of a function to send a friend request.

Is this a core script only functionality?

2 answers

Log in to vote
1
Answered by
cegberry 432 Moderation Voter
4 years ago

It is impossible to make a report user button, as Roblox uses :ReportAbuse method from Players service, this method can only be used in the command bar, and will error if used in scripts or localscripts, there is currently no known method to send friend request/follow someone with custom leaderboards, FriendService is only used with Roblox's Core scripts as described here:

https://developer.roblox.com/api-reference/class/FriendService

A service which is used to send, cancel, accept and decline friend requests in-game. It is primarily used by the PlayerListScript to send friend requests with the leaderboard.

Ad
Log in to vote
0
Answered by 4 years ago

I figured it out. You can use Roblox's SetCore function nto prompt a friend request.

It can be used like so:

game.StarterGui:SetCore("PromptSendFriendRequest", player)

Answered my own question

0
Nice! just put '[Solved]' in the title so people know that you solved your issue. Fad99 286 — 4y

Answer this question