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.

Code Snippets / Create new dbpro syntax

Author
Message
Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 24th Nov 2006 13:28 Edited at: 24th Nov 2006 15:13
This is in a way a continuation from my 'programming language'

I was experimenting again, and I figured that obviously I wasn't going to make anything better than db (suprise suprise), but I have made this.

Basically, I hate the DBC/DBPro syntax (no offence), so I made a thing that makes it look how I like.

For example, this is some code that I would type in a text editor:


You will notice that the commands can be split up and stuff (though they don't have to be). The semicolons ( are needed for every command, because what it actually does, is get every line in the code (unless it's preceded be //, a remark), and put it into one big line. It then splits it up into each individual command, and the way it does that, is by obviously checking for semicolons. If you dont put one there, then the to commands will be merged into one.

What that above code would output, is something like this:


Of course, the commands I made there are very similar to DBs, but one I get it to read text files for commands, rather than having to program each one individually into arrays, it will be easy to make substitutes for DBs commands. Right, now I program every single command in, hahaha!


Here's the code so far:


indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 24th Nov 2006 15:09
sounds like extra work, major headaches next build, but your idea has merit so kudos for trying.

Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 24th Nov 2006 15:11
Well it's not like anyone would use it. But I think it's good for just practice, heheh.

Code Dragon
18
Years of Service
User Offline
Joined: 21st Aug 2006
Location: Everywhere
Posted: 24th Nov 2006 20:34
That would be good for someone who is switching to Dark SDK in C++, but I think a reverse translator would be better. DBP is easier than C++, so DBP code could be translated to code in Dark SDK for C++ and compiled for a huge performance gain. I never understood why DBP is so much slower than C++, but there's another way to speed things up.

x1b
20
Years of Service
User Offline
Joined: 19th Sep 2004
Location:
Posted: 25th Nov 2006 02:46
here's mine.



I havent worked out all the bugs yet, but im getting there.

Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 25th Nov 2006 14:11
That's one damn awesome game x1b, I look forwad to trying it..

david w
18
Years of Service
User Offline
Joined: 18th Dec 2005
Location: U.S.A. Michigan
Posted: 25th Nov 2006 18:45
actually zotoaster your ideas are really good, I never thought about this before. Maybe I will try to expand on this, as it sounds very neat. Too bad codesurge is so good, or else we could possibly write up another editor for this. It actually almost seems easier to use than the dbp commands. I like the idea about making it able to port code into dksdk. Now thats a good idea.
Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 25th Nov 2006 20:05
You could use it with codesurge. Just make it export code

Login to post a reply

Server time is: 2024-11-22 23:52:14
Your offset time is: 2024-11-22 23:52:14