Javascript SDK template - r141 update

For developers using the Construct 2 Javascript SDK

Post » Thu Aug 15, 2013 4:28 pm

Hi all,

The Javascript SDK has been updated for r141. It includes new functions to let your plugins and behaviors take advantage of the debugger. Download it here:

http://www.scirra.com/downloads/javascript-sdk-template.zip

Changes
- Fixed a typo in the behavior SDK that stopped it working out of the box
- Code between a /**BEGIN-PREVIEWONLY**/ comment and /**END-PREVIEWONLY**/ comment on their own lines is now removed entirely on export. This is used to ensure code relating to the debugger does not get exported.
- Plugin and behavior templates now include the functions getDebuggerValues(propsections) and onDebugValueEdited(header, name, value). By implementing these functions you can get your plugin or behavior to display custom data in the debugger, and also handle edits when the user enters new values for them. See the template comments and example to get going with this.
Scirra Founder
B
398
S
236
G
88
Posts: 24,441
Reputation: 194,671

Post » Sat Aug 24, 2013 9:29 pm

Is there any way to change the visibility of actions/conditions in the c2 IDE? For example, if I had a true/false property in a plugin could I set some actions invisible?

If my property = true set my action visible true
Else set my action invisible?

That sort of thing

I am looking to just clean up the options in a plugin so only actions a user wants are visible for choosing.

Thanks for your help,

Lance
www.h1k3.tech

We are here for you!
B
87
S
22
G
16
Posts: 715
Reputation: 16,785

Post » Sun Aug 25, 2013 1:42 pm

No, that's not possible at the moment. You should just document (or use the action descriptions) that a certain mode is necessary to use them.
Scirra Founder
B
398
S
236
G
88
Posts: 24,441
Reputation: 194,671

Post » Mon Aug 26, 2013 6:04 am

[QUOTE=Ashley]
Changes
- Fixed a typo in the behavior SDK that stopped it working out of the box
[/QUOTE]

THANK YOU! I started working on my first plugin and couldn't figure out if I had messed something up or whether it was a bug in the SDK template haha.
B
52
S
13
G
7
Posts: 146
Reputation: 6,798


Return to Javascript SDK

Who is online

Users browsing this forum: No registered users and 1 guest