Grand Roleplay Inspired Dialog
Description
This NUI handles 2 pressed interactions, Y AND N, For developer usage you can read the code but in case you are bored you simply export the function on the resource you want with the function returning true or false based on what the client pressed!
The NUI Comes down nicely with an animation , while also notifying the user with a sound!
Exports
-
OpenDialog(msg)
-
DeleteDialog()
Usage Example
local question = exports['fDialog']:OpenDialog('This is a test dialog that can be used for multiple interactions');
if question then
print('Client pressed Y returning ',question);
else
print('Client pressed N returning ',question)
end
Download
fDialog.rar (326.7 KB)
Github Link
4 Likes
Yea i just noticed i have typed Agree instead of accept and i have fixed that
I appreciate this! This is a nice tool!
This is actually really good but i have a question as im not the brightest with lua,
If i wanted to replace dpemotes Shared animation request with this would it be possible and if so how would i go about doing so?
Hello. so i checked how dp emotes work, its pretty bad for what you wanna do xD!, What you have to do is trigger a client event that sends your request to the target client and only then start checking for his inputs via my resource, another solution is working with the way this guys has by exporting my dialog only when the variable request smth is changed! I Hope i helped!
BTW Use ‘ClientEmoteRequestReceive’’ for your loop <3
1 Like