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.

Program Announcements / Criterion Coding System & Dynamic Function Engine

Author
Message
RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 12th Apr 2007 21:37
Introducing the Criterion Coding System and the Dynamic Function Engine.

The Dynamic Function Engine is a powerful function management engine that allows coders to restructure functions during code execution. This has two primary benefits; the first adds a whole new level of flexibility to programming. Code can now restructure itself while running - imagine what you can do with that! The second benefit is to reduce resource usage (resulting in higher FPS) for larger programs. Functions can be added or removed as needed, which could limit the functions being executed only to those that are required at any given moment.

The Criterion Coding System is a utility that sets up the necessary Dark Basic Pro source-code structure for the DFE to work. In addition, we have included modified versions of a few extra Open Source tools developed for the Open MMORPG Project. These tools include 2D Button Functions, Object Button Functions, Infinite State Engine, Keyboard Functions, and an improved Text Parser. These included files all work with the Dynamic Function Engine, making many coding tasks significantly easier. For example; Functions can now be assigned directly to 2D Buttons, Object Buttons, States, and Keys, which makes programming these features easy and flexible.

The attached demo program was created using the Criterion Coding System. Below is all the code I added - nothing more.



To create this demo, only a few simple generic functions were written. The rest of the code was created by the CCS Project Set-up utility. You can also see that there is only one single command needed in the main loop; _Execute_Functions(0). During the first run, the initialize functions all execute, which sets up the demo. These are all then removed and replaced by the active functions.

You may also notice that at any given time, there are about 4 functions that are active (upper left corner of the demo). If you click on the dwarf, you will see that number jump up to 7. That is because more functions are required to turn the dwarf. When you are no longer clicking on the dwarf, the number of active functions drops back down to 4 since the other 3 are no longer needed. This demonstrates how the DFE helps save on resources. Think about it multiplied by a hundred dwarfs. Instead of 300+ functions all running all the time, only 4 to 7 functions are needed at any given time. This more than compensates for the background functions that make up the DFE.

The DFE's flexibility will also support advanced AI concepts, such as learning and adaptation. You will notice that functions are assigned using string values. This means that the function calls are no longer hard coded, but can be changed by manipulating the string values.

The DFE also supports scripting functions, so functions can be called directly from a text file. So, if you can write a function, it can now be scripted for unlimited scripting capability.

Included in the Criterion Coding System:

Project Set Up: Creates a project file, and all source files needed to start a DFE project.

DFE Scripting: Creates a unique source code file that works with your project to complete the DFE Functionality.
-->Also creates a keyword file that turns all your project's function names into keywords and includes useful information about the functions.

Support Files: Open various help files, demos, and tutorials (not included with beta-test versions as these files are being developed during beta-testing).

Image-Text Encryption: Useful for "watermarking" bmp images to identify them as yours, or to hide useful information within bmp images.
-->Text is stored in the image with no visible change to the image.
-->Can store entire books in large images.

Additional features may be added on later.

If you are seriously interested in beta-testing the Criterion Coding System and Dynamic Function Engine, please email me at:
riidii*@*ommorpg*.*vectramedia*.*net (remove the *'s).

The Dynamic Function Engine includes advanced coding concepts, so beta testers should be proficient coders.


Open MMORPG: It's your game!

Attachments

Login to view attachments
RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 12th Apr 2007 21:41 Edited at: 12th Apr 2007 21:43
Here's a screen shot of the CCS.




Open MMORPG: It's your game!

Attachments

Login to view attachments
RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 14th Apr 2007 08:54
Just to put this in a different perspective, since there are no replies as of yet, the DFE is like OOP for functions. Think of it as FOP: Function Oriented Programming.

Here are the first two of many help files. Take a look and let me know what you think. And please post a reply - let me know if this is confusing, if it is cr@p, or what. Thanks.


Open MMORPG: It's your game!

Attachments

Login to view attachments
Super Nova
18
Years of Service
User Offline
Joined: 14th Jun 2005
Location: Earth
Posted: 14th Apr 2007 18:03
I downloaded it and took a long look at it, and this looks really cool. There is quite a bit of code to look through, so maybe thats why no one else has replied. I am still trying to understand the code though, looks pretty complicated to me, but I still have alot to learn. If you don't get some e-mails to beta test I will gladly do what I can.

Justin Cannizzaro
Jerok
18
Years of Service
User Offline
Joined: 7th May 2005
Location: Mars. Wait a sec I\'m on MARS. OMG
Posted: 15th Apr 2007 00:29
This is amazing. I have read through the first help file now and I can see how valuable this resource could be to anyone, especially is a massive project such as the OMMORPG project. Thank you for this wonderful contribution to the community.
dark coder
21
Years of Service
User Offline
Joined: 6th Oct 2002
Location: Japan
Posted: 15th Apr 2007 07:53
It's a cool idea, I like how you can remove the functions from the program if you only want them called once, however it looks like it would run fairly slow for a large project because whenever you call a function it must check through a huge select statement, which in DBP is the same as having lots of if statements with an exit inside of them. Using a hash table of some sort would speed this up. Also when removing functions you are scanning through all of the functions to remove it, this could be slow if you have many functions. Furthermore you seem to use 'If SOMETHING = 1' for boolean value checks quite often, it would be a lot faster to just have 'If SOMETHING' or 'If Not SOMETHING'. The main drawback I see with this is that you must pre-process your functions so they get added into the select statements, I imagine some IDE's don't support dynamically updating source files, so it would be best if this were integrated into the IDE.

RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 15th Apr 2007 08:35
Thanks for the feedback.

Super Nova - thanks for the perspective on why folks may not be responding - it is a lot of code to look through. I was tempted to just post an exe file along with the source code that was added.

Jerok - thanks for the comments. I certainly hope it will be a wonderful contribution.

dark coder - thanks for the advice. A lot of my work was centered around improving performance - so what you are saying means a lot to me. The original main slow-down was with the parser. Once that was resolved, the performance has not been too shabby. But I will certainly be looking to tweak a few more milliseconds out of the code.

As far as the pre-processing; I agree with you that it is a drawback. If it could be integrated with an IDE, that would be cool. But I have no idea how to even start that. So, the pre-processing is handled by the CCS for now.


Open MMORPG: It's your game!
Jerok
18
Years of Service
User Offline
Joined: 7th May 2005
Location: Mars. Wait a sec I\'m on MARS. OMG
Posted: 17th Apr 2007 05:07
I keep getting "Subscript must be integer or dword when referencing to an array at line 7" when I try to run the demo_functions file and when I try and implement it into code of my own. Do I need the CCS file to make it work outside the demo?
RiiDii
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 17th Apr 2007 07:48
Yes. The CCS creates a specialized source file to work with your code. I will send you the beta test CCS.


Open MMORPG: It's your game!

Login to post a reply

Server time is: 2024-05-06 01:53:57
Your offset time is: 2024-05-06 01:53:57