Polydes - Open Source Toolset Extensions

Justin

  • *
  • Posts: 4716
I've made all of my Toolset Extensions open source at GitHub. Right now, this includes the Dialog Extension, the Data Structures Extension, the Extras Manager Extension, and the Scene Link Extension.

I still have a good deal of refactoring, organizing, and cleaning of code and documents, but anybody is free to grab the extensions. I think all four of them require Stencyl 3.2, but even if you don't have 3.2 you can browse them for reference.

I can't guarantee the code to be robust, clean, maintainable, conventional, or anything really. These extensions have all served a secondary purpose of being a testbed for experiments and learning to program. If others pick them up and treat them as such I would be delighted.

Everybody is welcome to:
- Keep your eye on the repository for the latest version of each extension.
- Create a local clone and mess with the code to learn how to make extensions. Ask me if you have any questions, I'd be happy to help!
- Fork the extensions, make them your own.
- Contribute source code, submit bug reports and feature requests, or help create documentation and examples.
- Do anything you want!

Going forward, I'd like to view these extensions as the community's extensions. That's why I packaged them all under the name Polydes, instead of using my own name. The name Polydes is a throwback to "Polyhedron Designs", a semi-official Stencyl game production group from 2007. It was composed of maybe around 20 people. A community effort. Unfortunately, while we had a number of impressive Nintendo title knock-offs and original titles lines up, I don't recall that we ever ended up releasing any games.

--
Right now the Data Structures and Dialog extensions are undergoing a good deal of change, so they're both effectively broken. Don't build from source and overwrite a saved game that uses either of the two.
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

SadiQ

  • Posts: 1795
'Wow Justin. It's great to have the source for such an impressive arsenal of extensions as it will definitely help others in their attempts to make their own extensions or even adding more features to the ones you already created. Thanks for releasing them to the world :)
Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

Justin

  • *
  • Posts: 4716
Added a simple paint extension to the mix. Feel free to play with it.



= = =

Oh yeah, and the extensions I mentioned above are no longer broken. Apart from the Paint Extension (still experimental stages), all the extensions should be in good shape now.

===

The latest stable version of each extension can be found on the polydes repository.

https://www.youtube.com/watch?v=WeFR-VRKFE0

« Last Edit: November 17, 2015, 05:05:12 pm by Justin »
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716
I cleaned up the build files a bit so everything will be much easier to set up on a different computer. For each project, it's nice and simple like this.

Code: [Select]
<!--
+==========================================================================
| Data Structures Extension
+==========================================================================
-->

<project name="stencyl" basedir="." default="dist">

<property name="name" value="DataStructuresExtension" />
<property name="pkg" value="stencyl/ext/polydes/datastruct" />

<include file="../Common/build.xml" as="common" />

<target name="dist">

<var name="srcpath" value="${srcpath}:./target/generated-sources" />
<var name="usinglibs" value="true" />

<antcall>

<target name="common.compile" />

<target name="common.copy-common-resources" />
<target name="common.copy-resources" />

<target name="common.makejar" />
<target name="common.copyjar" />

</antcall>

</target>

</project>

Everything is implemented just once in a common buildfile, from which each project inherits, basically. In the common buildfile are a few settings to change, and then all of the extensions should build fine.

Code: [Select]
<!-- Set these properties to match your own setup -->

<property name="swjar" value="C:/Common/Eclipse Workspace Windows/Stencyl/dist/sw.jar" />
<property name="swworkdir" value="J:/Cloud/Dropbox/stencylworks" />

<!-- If this is removed, blank out the copyjar task below -->
<property name="copytodir" value="J:/Cloud/Dropbox/Public/Extensions" />

<!-- /properties to set -->
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

captaincomic

  • *
  • Posts: 6108
Great job on the extensions! And I like your decision of open-sourcing them ;)

Justin

  • *
  • Posts: 4716
I'm hosting Jenkins and setting it up so that when contributions are made to the extensions on GitHub, they're rebuilt automatically.

Eventually, I'd like to create an extension manager for Stencyl that can check for updates to currently used extensions and download them.
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716
For now, I've made it so that github contributions automatically upload the up-to-date extensions to my site so that I don't personally need to rebuild anything when people contribute. This will be especially useful if, for example, captaincomic made some changes to Stencyl and it caused the extensions to break, and then committed the fixes to github. All would be well even if I wasn't around, or had completely broke my Java workspace somehow.

I've updated the links in my topics to point to these build server releases.

I guess I should probably just remember to set aside a version whenever a Stencyl release happens, so we don't end up having nothing but subscriber-only extensions online.
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716

« Last Edit: October 24, 2015, 03:47:34 am by Justin »
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716
The latest private build offers full support for external extension repositories.

To use it, go to "Extensions > Get Extensions", enable the use of repositories, and then add the repository "http://www.polydes.com/repo". Then you can download the latest version of all the extensions from within Stencyl.
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716
Also, an update on building these extensions.

I moved the location of user-specific files out of the main build.xml file. Now the location of the sw.jar file and where you want extensions built to are in polydes/Common/build-helper.properties. That file needs to be created after cloning because it's not part of the git repo. Here's an example.
Code: [Select]
swjar=/home/justin/stencyl/dist/sw.jar
buildpath=/home/justin/stencylworks/extensions
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Justin

  • *
  • Posts: 4716
I've been further building up the common framework that the polydes extensions share, and one of the cool things I put together recently was a system for easily creating properties sheets.

For example, this is the layer settings popup in Stencyl's scene designer.



It looks really simple, but all those fields require quite a bit of annoying boilerplate code. But why shouldn't it be as simple to code a custom properties sheet as it seems? So here's some code using the new properties sheet framework I wrote.



And here's what it generates. Just as simple as it seems. :)

For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Hectate

  • *
  • Posts: 4643
Ah yes, I remember having to hack the Imgur extension to get the options menu to display everything I wanted. I had to combine the easy objects that Jon had created with somewhat more complex Swing objects to get everything I needed.
If I dig into that toolset extension I mentioned yesterday (another polydes contribution, of course), something like this with more types would be great.
:
:
Patience is a Virtue,
But Haste is my Life.
Proud member of the League of Idiotic Stencylers; doing things in Stencyl that probably shouldn't be done.

Justin

  • *
  • Posts: 4716
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)

Hectate

  • *
  • Posts: 4643
I'll take a look. Have any of the extensions been update to use these so I can glance at some code examples?
:
:
Patience is a Virtue,
But Haste is my Life.
Proud member of the League of Idiotic Stencylers; doing things in Stencyl that probably shouldn't be done.

Justin

  • *
  • Posts: 4716
Absolutely. Each of these images links to a code sample.








This one is split up into two classes. One takes care of the top half, and another adds extra fields at the bottom depending on the type of data. Here's the code for the base fields.

String


Int


Set
For Live Support: Join our discord server and ping me @justin.
I'm most often available between 10am and 10pm Japan time. (GMT+9)