When comparing Duality vs PureBasic, the Slant community recommends Duality for most people. In the question“What are the best 2D game engines?” Duality is ranked 30th while PureBasic is ranked 40th. The most important reason people chose Duality is:
The full source code is available on GitHub, where the framework is actively developed. All of the editor, core and plugin code is written in C#.
Specs
Ranked in these QuestionsQuestion Ranking
Pros

Pro Open source
The full source code is available on GitHub, where the framework is actively developed. All of the editor, core and plugin code is written in C#.

Pro Great editor
Duality includes a powerful visual editing system that can be used for previewing, integrating, editing and testing game content.

Pro Live reload of code and assets

Pro Very extensible
Because both Core and Editor are completely plugin-based, Duality not only incorporates a clean and modular design, but is also very extensible - even if it wasn't Open Source. In fact, most of the standard editing capabilities comes in form of Editor plugins.

Pro Built-in physics and lighting

Pro Friendly to version control systems
It can be configured to serialize all data in a text-based format, which has been structurally optimized for version control systems.

Pro Used in commercial projects
It has been used in a production environment without burning the place to the ground. Supposedly artist-proof editor workflow with an API for tailoring the system to fit your team.
Pro Standalone executables
Can create single file executables without the need to install other libraries, run time environments, etc.
Pro The syntax is very beginner-friendly
Pro Same code on Windows, OS X and Linux
Same code can be compiled natively, without any interpreter for OS X, Windows or Linux, using the native GUI toolkit of the OS
Pro Many integrated features
Many libraries available without additional installations : 2D & 3D, database, network, sound, xml, JSON, http...
Pro Allows to program at a lower level than most alternatives
Pro Lifetime license
Pay once, use forever.
Pro Constantly updated
Pro Supports ARM in addition to x86, AMD64 and others
Pro Can compile to plain C code
Pro Grest user community / forums with the developer very active
Cons
Con Visual Studio required
To have possibility for scripting you have to download entire Visual Studio and spend 10 GB of free space
Con Requires windows for development
Con Limited free version
Free version is limited to 800 lines and can not create DLL's.
Con Some bugs are present on the Linux platform
Con Slightly bogged syntax
Sometimes the syntax bogs down, just a little with long procedure names and such. A truly minor issue.
Con Not RAD
Not a RAD environment.
