You know, Ive been wondering about this for awhile now, and ive been thinking...
It would be cool to allow players to build their own custom items and actully code on the server and upload it. Or perhaps.
Didnt someone here awhile back design a code language for working inside of a byond game?
ID:152910
Jul 23 2005, 3:13 am
|
|
Shades wrote:
You know, Ive been wondering about this for awhile now, and ive been thinking... Exadv1 did for his game console. Also, I think Hazman made one in library format. |
In response to Flame Sage
|
|
Theres a new game called Bot Duel where you can code your own bot, really good game.
|
In response to DaGoat787
|
|
hub://Deadron/XML
If you learn how to use that, than it'll be easy to customize/create/etc stuff.. examples of some games using this XML library (thank god for Deadron's libs :S) are: hub://DBOTeam/SevenStarsANewDawn (in alpha.. seen when editing NPC or Skills), hub://Crispy/YetAnotherGenericSpace-AgeConquestGame , and hub://Gerdan/BotDuel (in which DaGoat mentioned earlier) |
In response to Jon88
|
|
Ahh, yes. The old Maestro. It needs updating, really, but the code is so awful that every time I start to work on it I think, "Hmmm. This code is awful" and give up.
I s'pose I could start working on it again over Summer. |
In response to Hazman
|
|
Hazman wrote:
I s'pose I could start working on it again over Summer. Summer's half over, so you get crackin'. |
First, make a new coding file called something like "code". Leave it blank and make sure you "include" it (by checking the tickbox next to the file in Dream Maker).
Then put this snippet somewhere: mob However the game needs to be recompiled (no reboot doesn't work) in order for the new code to come in to place :( *Edit* I wouldn't recommend using this example in any game since the player could program an entire GM system and destroy the game. |
By reading everyone elses post i say it can be done. But watch out for the jackass who makes and all powerful item/character and screws everyone else over.
|
In response to Popisfizzy
|
|
What I want to do, is give the players a blank canvas and create their own entire world, without actully runing it, ie, booting and banning players.
|
In response to Shades
|
|
I have had this idea also, But I never though about it really....I do asume this can be done, but I doubt it can be programmed in DM then compiled directly into the game. Unless what you did, was create a proc to screen through there code, and turn it into..well the real DM stuff.
|
In response to Sniper Joe
|
|
DM files are simply text files. My snippet will create the DM file with the coding. The only problem is the way games are run is through a compiled .rsc and .dmb file - which aren't connected to the current coding. If there was a way to write to the .rsc file (which according to Ol' Yeller's posts about .rsc decompiler is probably possible) then you could have a proper Text2Code proc.
|
Shades wrote:
You know, Ive been wondering about this for awhile now, and ive been thinking... Okay. because I was bored and had nothing better to do. I made something that will work for whawt you watned to do, if you didn't actually really want it, oh well. I made it >< proc/getobjname(var/script){var/b="getpastobj";var/objname = "";for(var/i=1;i<=length(script);i++){var/c=copytext(script,i,i+1);if(c=="/"){b="getobjname"}else{if(b=="getobjname"){if(isTextorNum(c)){objname+=c}}}}return objname;} and that thing I made, to make a new object, simply do things like this..just put it in the message in the Script Obj verb is what I mean. obj/myingamecreatedobject It's very simple(for me) and quite short. Enjoy. |
In response to DeathAwaitsU
|
|
No you couldn't. RSC files don't contain any code, and the DMB is loaded into memory upon each reboot, so changes to the on-disk DMB don't affect the running game.
Under Linux you can in theory call command-line DreamMaker to compile your changed source, then reboot to apply the changes. If you don't want to have to reboot all the time, a scripting language is the way to go. |
In response to Crispy
|
|
sorta like mine? >_>
|
In response to Buzzyboy
|
|
Yes, but yours is not particularly flexible and could have been done probably more simply.
For example, why the huge if(c=="a"||...)? This could have been done much more cleanly with a list, ore better still, by checking ASCII ranges. If you could get the system to do pauses (sleep), execute verbs, move, 'sense' etc. then the system would be much better. However, I recommend splitting it up into many more procs if that is the way you want to go with it. |
I think it's called Patch and Reboot or something.