Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Sublime 3 Editor Package/Support

Author
Message
punkyb
7
Years of Service
User Offline
Joined: 8th Sep 2016
Playing: PC and Android Games
Posted: 11th Oct 2016 00:15
I have read somewhere that you can use Sublime Text Editor with DBPro. Tried searching it in the forums and google but cannot find any links.

Is this still available? I like the default editor but I got used to working with Sublime 3. would be nice to have this option, thanks.
Phaelax
DBPro Master
21
Years of Service
User Offline
Joined: 16th Apr 2003
Location: Metropia
Posted: 12th Oct 2016 15:58
I could only find references of sublime with AGK. But, I do have a list of alternative DBP editors.

http://dbcc.zimnox.com/?page=resources

"I like offending people, because I think people who get offended should be offended." - Linus Torvalds
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 13th Oct 2016 03:46
Yes, I use Sublime Text 3 for my DBpro coding. Really you can use any text editor you want. I've previously used Notepad++ for DBpro as well.

To compile from outside of the IDE, just pass the .dbpro file as an argument to the compiler (you can either manually create the .dbpro file, or use the default editor to create it initially). You can probably set this up as a build system within Sublime, or just make a .bat file:

"c:\my darkbasic professional online directory\compiler\dbpcompiler.exe" c:\pathToMyProject\main.dbpro

You need to have the IDE/default editor closed to call it from the command line like this or it will throw an error.

Be sure that you are passing the .dbpro 'project' file, which contains configuration data, not the .dba 'source' file which contains your code.

I've written a more robust build manager that I am using, and I'll post it up in a separate thread with details.

Here are the language and theme files (attached) that I use for DBpro in Sublime. As mentioned in another thread, the language file mostly provides syntax highlighting for control commands and does not define the majority of the language commands. these could be added, but I like the clean minimalist look.





A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.

Attachments

Login to view attachments
punkyb
7
Years of Service
User Offline
Joined: 8th Sep 2016
Playing: PC and Android Games
Posted: 13th Oct 2016 05:48
Thanks Phalaex and Ortu!

@Ortu

So you probably need to convert the Keywords INI file to sublime format/syntax if you like to add those plugins, right?



Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 13th Oct 2016 06:17
yeah, You'd add them to the DBpro language.tm file. DBpro commands can be fiddly to match due to the inclusion of spaces in them, but Sublime uses regex to match syntax for highlighting, so it should be doable if you want to put in the effort. Should also be able to add parameter hinting and the like.


A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.
punkyb
7
Years of Service
User Offline
Joined: 8th Sep 2016
Playing: PC and Android Games
Posted: 13th Oct 2016 07:48
Great. I'll settle with your version at the moment to keep it simple, awesome package thanks again for sharing!
Phaelax
DBPro Master
21
Years of Service
User Offline
Joined: 16th Apr 2003
Location: Metropia
Posted: 16th Oct 2016 21:58
When you used Notepad++, did you make a plugin to add a compile link to the editor?

"I like offending people, because I think people who get offended should be offended." - Linus Torvalds
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 18th Oct 2016 03:54
I didn't sorry


A single player RPG featuring a branching, player driven storyline of meaningful choices and multiple endings alongside challenging active combat and intelligent AI.

Login to post a reply

Server time is: 2024-04-19 07:36:51
Your offset time is: 2024-04-19 07:36:51