PDA

View Full Version : How to clean up the UDK files?



decko
11-09-2009, 05:58 AM
One great thing about the UDK is that mod developers are finally able to separate their mods completely from UT3, and that's great! However, when installing UDK you get UT specific files that you might never use. As far as I can see it's impossible to strip away UTGame.u and other UT specific .u files, as this causes the engine to crash.

If you remove stuff from the Content folder, the editor crashes as the content is being referred to from the .u files. The idea of creating games separated from UT3 fades a bit when you get 800MB of UT3 along with your game. Is there really no way to prevent this? My guess is that there obviously is, as I don't think the UE3 licensees gets the extra files.

Angel_Mapper
11-09-2009, 06:04 AM
When you package your game up, only the content that is needed by the maps and code is put into the final exe. Anything not used is ignored. My clean UDK install is a little over 1GB in size for example, but the packaged Prometheus is only about 330MB.

decko
11-09-2009, 06:56 AM
I know some of it is getting stripped away. But what about stuff like Maps? These are usually not referred to from uscript, so how would it know which maps to include and which to exclude? This problem is obviously easily solvable by removing the contents of the Maps folder, but I am guessing that this case is true for other files as well?

Angel_Mapper
11-09-2009, 07:11 AM
Only maps that are cooked with the UnrealFrontEnd are packaged up, and only assets which they need are packaged up with them.

twoflyingpigs
11-09-2009, 07:14 AM
I stripped down my udk installation to about 180M by removing all the unnecessary maps/packages. Just to save some hd space :)

decko
11-09-2009, 07:47 AM
Only maps that are cooked with the UnrealFrontEnd are packaged up, and only assets which they need are packaged up with them.

Aha, this was the information I was looking for. Thanks :)

Daniel Vogel
11-09-2009, 08:49 AM
There is a way to get rid of all the UT3 content (including ones referenced by UTGame*.u). You need to rename your content folder to Content-Old, add a new Content folder and then do a "udk make -full". This will strip it all and generate a lot of warnings, but they are just warnings and you won't see them again unless you touch UTGame *.uc files.

Next up is fiddling with the .inis to make sure they don't reference content no longer present. E.g. startup packages, maps to always cook, UI scenes and some other things.

We'll get this documented if it isn't already, but it shouldn't take long to figure out. I was able to create an empty mod that is around 100 MByte this way, most of which is UE3Redist.exe, which is something we're working on optimizing as well.

decko
11-09-2009, 09:39 AM
There is a way to get rid of all the UT3 content (including ones referenced by UTGame*.u). You need to rename your content folder to Content-Old, add a new Content folder and then do a "udk make -full". This will strip it all and generate a lot of warnings, but they are just warnings and you won't see them again unless you touch UTGame *.uc files.

Next up is fiddling with the .inis to make sure they don't reference content no longer present. E.g. startup packages, maps to always cook, UI scenes and some other things.

We'll get this documented if it isn't already, but it shouldn't take long to figure out. I was able to create an empty mod that is around 100 MByte this way, most of which is UE3Redist.exe, which is something we're working on optimizing as well.

I'm already using the base ini files from Engine/Config so that shouldn't take long to try. Thanks for the info, and thanks for trying to make it even lighter as well :).

Daniel Vogel
11-09-2009, 09:45 AM
Good point - that's definitely going to be the leanest and meanest. I suggest diffing it as the base version might have some things unmapped we expect all games to set and you might miss some things causing subtle issues.

Daniel Vogel
11-09-2009, 09:47 AM
Just thought of this though ahven't actually tried it - you could simply delete Development/Src/UTGameContent after removing it from the list of packages script is compiled for and delete all non-native classes in UTGame. Native ones are still required. That should cut it down a bit more and make things cleaner if you want to do your own little game that is a total conversion.

Masakari
11-09-2009, 10:26 AM
There is a way to get rid of all the UT3 content (including ones referenced by UTGame*.u). You need to rename your content folder to Content-Old, add a new Content folder and then do a "udk make -full". This will strip it all and generate a lot of warnings, but they are just warnings and you won't see them again unless you touch UTGame *.uc files.

Next up is fiddling with the .inis to make sure they don't reference content no longer present. E.g. startup packages, maps to always cook, UI scenes and some other things.

We'll get this documented if it isn't already, but it shouldn't take long to figure out. I was able to create an empty mod that is around 100 MByte this way, most of which is UE3Redist.exe, which is something we're working on optimizing as well.

That would be helpful Vogel. Presently, a lot of people are sorta confused about the current work and directory structure.

I've seen the facts and all, from UDN and several posts here, i know only required content would get cooked, setting up multiple projects, etc, but imo the UDK documentation didn't make this very clear - a simple "game setup" tutorial would suffice with some instructions like you just described.

aeonflame
11-09-2009, 10:48 AM
We'll get this documented if it isn't already, but it shouldn't take long to figure out. I was able to create an empty mod that is around 100 MByte this way, most of which is UE3Redist.exe, which is something we're working on optimizing as well.

Some very useful information in this thread, thanks. However as you mention some proper documentation on what is, and isn't required would be hugely useful. I'm sure a large proportion of people using UDK are planning on developing total conversions, so getting the development environment down to the absolute minimum necessary to run would be very useful.

SynaGl0w
11-09-2009, 11:11 AM
Some very useful information in this thread, thanks. However as you mention some proper documentation on what is, and isn't required would be hugely useful. I'm sure a large proportion of people using UDK are planning on developing total conversions, so getting the development environment down to the absolute minimum necessary to run would be very useful.

Just a thought: It could be nice to have an option for that on UDK installation. Something like a full install and minimal install option.

twoflyingpigs
11-09-2009, 11:24 AM
Just thought of this though ahven't actually tried it - you could simply delete Development/Src/UTGameContent after removing it from the list of packages script is compiled for and delete all non-native classes in UTGame...
Thanks, vogel.
How to tel a native class from non-native class? Are the clases begin with UT* non-native classes?

twoflyingpigs
11-09-2009, 11:49 AM
I have to retain Textures and UI in the Content folder, otherwise, the editor won't start. ( I've deleted UT*.ini, commented out all the editor startup packages, maps to always cook in the default*.ini, and regenerated all UT*.ini ) Can't figure out why Textures/UI is still being referenced.

meri
11-09-2009, 12:17 PM
Empty textured corridor and default character with default gun took around 150mb.

Daniel Vogel
11-09-2009, 12:57 PM
Native classes use the "native" keyword in the .uc file.

decko
11-09-2009, 02:42 PM
How would I go about preventing UTGame.u from being loaded? The editor seems to load everything from the script folder, and removing it is obviously bad :). It generates a lot of errors as it is referencing to non-existing files, and cooking doesn't work either.

Exal
11-09-2009, 03:34 PM
Just a thought: It could be nice to have an option for that on UDK installation. Something like a full install and minimal install option.

I second this.
It would be a much better solution than manually removing content, unused classes, etc.

insomnia3d
11-10-2009, 12:26 PM
i need simple video tutorial

decko
11-10-2009, 01:18 PM
i need simple video tutorial
The unreal engine is not simple :\

insomnia3d
11-10-2009, 01:23 PM
you realy funny. i need only clean up tutorial

decko
11-11-2009, 04:47 AM
you realy funny. i need only clean up tutorial

http://forums.epicgames.com/showthread.php?t=707128

goober
11-11-2009, 05:56 PM
Are we allowed to use the UT3 resources included in the UDK for standalone games?

decko
11-12-2009, 06:55 AM
Are we allowed to use the UT3 resources included in the UDK for standalone games?
I'm pretty sure, but not for commercial games. For commercial games, you are only allowed to use the UT3 code, not the actual textures and models etc.