Auto Completion Cocos Creator 1.7

Auto Completion Cocos Creator 1.7
0.0 0

#1

Hi, i’m using vscode 1.18.1 for creator editor. unfortunately, auto completion not working properly as I type in editor. I’ve installed vs code workflow. And this is extension in my vscode:



tried open js-test sample but it’s the same. am i missing something ?


Use VSCode to debug cocos2d-x JSB programs
#2

@jare could you please take a look?


#3

or auto completion is basicly the same setting with debugging in this link Use VSCode to debug cocos2d-x JSB programs ?
in this video http://www.bilibili.com/video/av9612124/ it seems the guy success to manage it. but i dont have any idea.
i tried run debugging the result always:


#4

i find out somehow, i recreated project, the problem is i broke the launch json. it’s work now.


#5

Glad to hear that you resolved it. Auto completion is different from debugging, it is another plugin to do it.


#6

yes, but some of code like node or prefab type is lack of auto completion. like this.node.x or this.node.position, information about x and position is not available.


is there any plan for better version auto completion in vscode ?


#7

I forwarded the issue to my co-workers.


#8

thanks for response, I greatly appreciate it


#9


Hi im using newest cocos creator v1.9, my vscode still dont show up auto completion, i wonder is it because i leave js engine blank ?
because auto completion only show for cc.component, like cc.RotateBy, cc.Moveby, etc but not for node object like label property or x/y position, etc. Sorry for noob question im trying to move from -x to creator.


#10

Did you click on all 5 entries?


#11

i did, i simply click update update vs code api and install vs code ext. the problem is when i type like this.node.rotationX , auto completion for rotationX did not show up. Or that feature do not exist yet ?


#12

I have no problems with autocompletion for that.

You should try to click on all 5 entries in the menu.


#13


not working on my vscode, can i see your cocos creator preference on native develop section?


#14

I only use it for web based stuff.


#15

i mean, did u linked javascript engine to your cocos creator ? i’ve clicked all entries, but still no working.


#16

It’s not something you have to do for the web version as far as I know. I have several colleagues that all run 1.9 with VS code with no problems.

Maybe try a fresh install of VS Code?


#17

yes,i think i should reinstalled my vs code. I don’t know how to set it up correctly, is this tutorial enough http://www.cocos2d-x.org/docs/creator/manual/en/getting-started/coding-setup.html ? or any else ?


#18

There’s not really much you have to do. With every project I start I make sure to click all 5 entries in the “VS Code Workflow” and it just works from there. That’s why I think that your VS Code may be borked or there is something installed that overrides the CC configs.


#19

after re-install and delete all of code data, its still not working. the weird thing is when i created new blank js file and tried to type cc and hit “.” it’s type “CSSConditionRule”. what should i do ? it’s look like cc not detected. auto-completion for typescript is working, but not for js file.
this is my project link. i don’t have any idea why it’s not work on my machine :expressionless: