add a new wdl to a published project

Posted By: ChildeHarold

add a new wdl to a published project - 12/04/07 14:05

I would like to extend the functionality of a published project (which communicates basically with a wdl).

Therefore I use wdl mainly to declare new functions.
But how is it possible to do that?

I tried add_resource (which works fine for models etc), but not for wdl files.
I tried add_buffer - and it did not work either.
Posted By: EpsiloN

Re: add a new wdl to a published project - 12/04/07 15:40

Try using as 'include <script>' a text file or some other format , and call your new include <script> in that text file.
Some time ago it worked for me
Posted By: ChildeHarold

Re: add a new wdl to a published project - 12/04/07 16:11

That would have been a wonderful solution, but unfortunatley - it does not work.
The program does not reconizes the newly added wdl.

There must must be a solution though. Otherwise a project, once published, would be totally frozen in it's functionality - which is hardly what I may imagine.
Posted By: Xarthor

Re: add a new wdl to a published project - 12/04/07 16:54

It is frozen in its functionality.

Just add the file in the source code and re-publish the project.
Posted By: ChildeHarold

Re: add a new wdl to a published project - 12/04/07 18:26

hmm... are you sure? That seeems pretty absurd to me. Why should I be able to add resources, models etc. etc. - and never ever a new function?

This would mean that a Gamestudio project could never be upgraded, but would always demand a new published version.
Is this really true?
If so, this would be a serious drawback.

Posted By: EpsiloN

Re: add a new wdl to a published project - 12/04/07 19:47

Almost every application (games or programs) when updating they replace the old executable file. If you replace the current .exe file with the one searching for that particular .wdl code , it should work.

PS.: You tryed to add into a .txt file a new .wdl file. Try including a .txt file in a .txt file included in the main .wdl file...
Posted By: ChildeHarold

Re: add a new wdl to a published project - 12/05/07 07:10

Thanks, Epsilon, your hint with the textfile was really helpful. Actually the definition of a text file seems to be a workaround. I just tested it, included a textfile and added a few functions. In fact these functions are just declarations of dll functions.
So my extension policy bases upon the replacement of a dll.
By this mean you reaaly can change and extend the functionaliy of a game. Just replace als dll (which may have 2 o r 4 MB), which is much more conventient thant recompling hundreds of MBs.

I never understood why Gamestudio is so precious about it's wdl wdl files. Mainly it is text which is read in each time the program starts - like any other cript language. So in fact it is not frozen. - But obviously there is some protection mechanism which prevents from modifying these files. Therefore it does not work. - Taking a textfile instead is a handy trick to circumvent that mechaninism.

Thanks again.
Posted By: Xarthor

Re: add a new wdl to a published project - 12/05/07 11:40

Exactly. The compiled exe only runs with the wdl files it "knows". If you modify them the exe won't start.
But to get a new exe you would have to re-publish anyway.

Using text files which get read in is a work around but the published exe itself is "frozen" and the .wdl files too.

So yes, you can use that work-around if you want
Posted By: Scorpion

Re: add a new wdl to a published project - 12/05/07 13:38

but that "workaround" gives also the problem that a user, who knows c-script, could modify it, too...
Posted By: KojaK

Re: add a new wdl to a published project - 12/05/07 14:29

Which is the very essence of making a mod for a game.
Posted By: ChildeHarold

Re: add a new wdl to a published project - 12/05/07 15:17

a mod - that means modification, I guess?
Just imagine an online game, which shall extend functionality.
If you are rebuilding that over and over again, forcing the user to download a huge data packet, they won't be very grateful, I assume.
Posted By: Xarthor

Re: add a new wdl to a published project - 12/05/07 18:50

Nope the user wouldn't have to download the whole game again.
The patching in 3dgs works if you just provide the new .exe file and all modified files which replace the old files.
That should work too.
Posted By: mpdeveloper_B

Re: add a new wdl to a published project - 12/05/07 21:31

i've been working on a mod system for things like this, you'll have to set the scripts to be added and run them using the execute function. i'll be finishing it soon, so i'll make sure to give you the mod system as well
Posted By: ChildeHarold

Re: add a new wdl to a published project - 12/06/07 07:18

thanks, Xarthor, for that hint. - I did not know that, but that might ease my problems definitely. - To take it concrete: This would mean that you just add new *wrs-files with extended functionality, and that's it? Are there any drawbacks and limitations?
© 2024 lite-C Forums