-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue with Auto Complete adding extra words and characters #8
Comments
hey, thanks for the input.
this is a limitation of Sublime Text's auto-completions, as I've explained here.
that is how the auto-completions work in Sublime Text. but it kinda makes sense. the highlighted area is the function parameter (name and type) which should be replaced by your argument. yes, 99% of the time you'd want to pass KeyCode.X to GetKeyUp, but that is only right for GetKeyUp and other functions that receive an enum value.
you're right. I'll change it so it doesn't add a semicolon. I cannot tell how the function call is used (condition of if statement or nor) so I'll just change it so it never adds the semicolon. |
Your welcome, I have never written a plugin like this. However, I know in snippets you can specify where you want the cursor to be placed. for example as a snippet I would do something like Input.GetKeyUp(KeyCode.${1:A}) |
I think you're right about the technical side. but how should I determine that GetKeyUp's argument begins with "KeyCode."? |
Ah very true, good point I had not thought of the other GetKeyUp options. |
I've removed the semicolons. |
In Mono and using unityvs for Visual Studio when you go to auto complete a line such as Input.GetkeyU and hit tab it just fills in to the end which allows you to continue working
This is the result of doing it in Visual Studio
if(Input.GetKeyUp)
The cursor is possitioned right after the p so I can add in my (KeyCode.X)
In Sublime Unity Completions there are several issues
What I get is this
if(Input.Input.GetKeyUp(KeyCode key);)
It is adding an additional Input command at the top
It Higghlights the entire KeyCode key area where it should just place a cursor after KeyCode. as that will be the useage of this command 99% of the time
Also it adds a comma at the end not detecting that it is in an if statement
The text was updated successfully, but these errors were encountered: