Author Topic: How to use DSOs  (Read 1483 times)

I've figured out how to make them without buying a $100 licence, but when i try to execute it in the console it gives me a popup saying
"Your copy of blockland seems to be Damaged. Please reinstall Blockland or contact support."
and then closes.

All i put inside the .dso was literally this:
Code: [Select]
DSOWin();
function DSOWin()
{
    echo("Success!");
}
Why is this happening, and can it be fixed?

1. DSO files are compiled scripts, you can't just take a script, shove it in a DSO file, and except it to work
2. Blockland's DSOs are further obfuscated so you can't read some things like function names. You can't use a DSO from another TGE game and expect it to work.
3. Why do you want to use DSOs anyways? Even if you could make it work, anything you release with them would be failed.
4. The exec function only allows .cs, .mis, or .gui files. How are you getting around this?
« Last Edit: December 01, 2011, 12:15:01 AM by Headcrab Zombie »

That's not how .dso's work. DSO's are "used for compiled (uneditable, unreadable) script files."

When you execute a .cs file, it creates a .dso file too.

Blockland runs on a modified engine. One of the modifications is that it is impossible to create a compatible DSO file. It probably has a system so that if any DSO file is missing, modified, or not one of the default ones, then it gives a generic error and quits early.

One of the original intents of not executing non-default DSO files was that in the past, people would use them in attempt to hide dangerous code. I believe I remember several times Badspot had gone through DSO files of others and could at most assume that the snips of text shown indicated it was the culprit of a given problem. Of course now, the code is so obfuscated that you can't read any of it, but only the default DSO files execute, so you're safe.

I believe Badspot changed how his DSOs are compiled.

On top of that your script wouldn't even work.

On top of that your script wouldn't even work.

Further explanation: Because you are calling the function before it exists.

Quote from: Headcrab Zombie
1. DSO files are compiled scripts, you can't just take a script, shove it in a DSO file, and except it to work
I compiled it using a Real Compiler, there is nothing wrong with the compiled file.
Quote from: Headcrab Zombie
2. Blockland's DSOs are further obfuscated so you can't read some things like function names. You can't use a DSO from another TGE game and expect it to work.
I'm not trying to read DSO's, im trying to exec one and use the functions inside it.
Quote from: Headcrab Zombie
3. Why do you want to use DSOs anyways? Even if you could make it work, anything you release with them would be failed.
Why not?
Quote from: Headcrab Zombie
4. The exec function only allows .cs, .mis, or .gui files. How are you getting around this?
Torque reads .dso files as .cs files.
Try to exec one of the default .cs.dso files, but dont type in .dso, just .cs. It will say
"Loading compiled script".

Further explanation: Because you are calling the function before it exists.
Answer:
I have tryed several different codes
Like:
Code: [Select]
echo("Success!");and
Code: [Select]
function bloo()
{
    echo("Win!");
}
And the list goes on.
They always give me that same error message.

That's not how .dso's work. DSO's are "used for compiled (uneditable, unreadable) script files."
That has nothing to do with this.
I'm Creating a DSO file using a Real, valid compiler, and Torque can read .dso files.
When you execute a .cs file, it creates a .dso file too.
Not for any non-default code.
If you dont belive me, put a .cs file (you can even name it the same as one of the default files) into one of the main script areas and start it up, then exec it. It won't create a .dso.
« Last Edit: December 01, 2011, 12:52:26 PM by Ipquarx »

Badspot has personalized Blockland's DSO encryption. You can not use any old compiler to make a file functional with the game. Besides that, he prevents the game from loading anything but the default DSO files to prevent any hidden, damaging code from being used without ease of assurance. Just because he mentions that Badspot obfuscated the code further to prevent reading doesn't mean he was saying "You're trying to read it." It's just an explanation of one up front and obvious display of how the game's DSO encryption has been changed. He explained why not in the same part you quoted - DSO files are not allowed, and if you're really that protective of your code, don't release it.

So basically, this:
You can't use your own DSO's,
Okay.

Locking topic.