Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

One line of keycode enter (very easy) not even working?

game.ContextActionService:BindAction("keyPressenter", onKeyPress, false, Enum.KeyCode.Enter);

What is it expecting?

The error msg:

16:33:28.983 - Players.Player1.PlayerGui.Chat.Chatbar.Input.Chat:19: ')' expected near ';'

2 comments

0

Obviously a typo in the context

0

I don't know what the proper syntax to use this should be. Can you give me the corrrected version by any chance?

1 answer

I think that you may be thinking of Java or another programming language that ends statements with semicolons ";". Lua doesn't use semicolons like some other programming languages do to signify the end of a line of code. Taking out the ";" at the end of your line should fix it.

This discussion is preserved as it was. New answers, comments, and votes are closed.