Actions

Difference between revisions of "Fangame How-to:SonicGDK/From installation to game deployment"

From Sonic Retro

(1st SonicGDK tutorial (WIP))
 
Line 1: Line 1:
 +
{{GuideBy|Xaklse}}
 
{{WIP}}A version of UDK must be downloaded and installed. Then, a [[SonicGDK]] script project needs to be downloaded and added to the engine. In order to develop and test your fangame, code must be compiled at least once. After development is finished, the final step is the creation of an installer file for distribution of your fangame.
 
{{WIP}}A version of UDK must be downloaded and installed. Then, a [[SonicGDK]] script project needs to be downloaded and added to the engine. In order to develop and test your fangame, code must be compiled at least once. After development is finished, the final step is the creation of an installer file for distribution of your fangame.
  
Line 6: Line 7:
 
In order to add Sonic gameplay elements and items to UDK, UnrealScripts defining these elements must be added. A new UnrealScript project must be created which consists of a separate package which contains the new scripts, making sure the engine knows to include those when compiling and using the editor.
 
In order to add Sonic gameplay elements and items to UDK, UnrealScripts defining these elements must be added. A new UnrealScript project must be created which consists of a separate package which contains the new scripts, making sure the engine knows to include those when compiling and using the editor.
  
SonicGDK consists of an UnrealScript project and a pack of custom visual assets. {{LinkRetro|topic=19492|title=Get it}}, uncompress it and copy the SonicGDK's folders Development and UDKGame and the .bat file to the UDK directory. Run the Unreal Frontend tool application (found in the Binaries folder of your UDK directory), click on the "Script" button and choose the "Full recompile" option from the list. If errors appear, make sure the UDK Editor is closed and retry.
+
SonicGDK consists of an UnrealScript project, a test map and a pack of custom visual assets. {{LinkRetro|topic=19492|title=Get it}}, uncompress it and copy the SonicGDK's folders Development and UDKGame and the .bat file to the UDK directory. Run the Unreal Frontend tool application (found in the Binaries folder of your UDK directory), click on the "Script" button and choose the "Full recompile" option from the list. If errors appear, make sure the UDK Editor is closed and retry.
  
 
Installation is complete; just a note: the first time that you open the test map, it will compile all the material shaders and take a really long time.
 
Installation is complete; just a note: the first time that you open the test map, it will compile all the material shaders and take a really long time.
  
==Running/editing a map==
+
==Running a map==
Coming soon...
+
To test the game using a map named "MapName", you have to run the game executable with a special option like "MapName?game=CodePackage.GameInfoClass"; you usually do that with a shortcut. Examples with real maps and SonicGDK:
 +
  (UDK dir)\Binaries\Win32\UDK.exe SonicGDKTestMap?game=SonicGDK.SGDKGameInfo
 +
  (UDK dir)\Binaries\Win32\UDK.exe DM-Deck?game=SonicGDK.SGDKGameInfo
 +
  (UDK dir)\Binaries\Win32\UDK.exe VCTF-Necropolis?game=SonicGDK.SGDKGameInfo
 +
  (UDK dir)\Binaries\Win32\UDK.exe FoliageMap?game=SonicGDK.SGDKGameInfo
 +
Alternatively, you can run a map if you open it with the editor, but you'll get worse performance.
  
 
==Project setup==
 
==Project setup==
Coming soon...
+
If you want to program a new code package (called "MyGame") to use your own assets properly, follow these instructions:
 +
# Close the editor if it's opened.
 +
# Open the '''DefaultEngine.ini''' file of ''UDKdir''\UDKGame\Config folder, add a new line "+EditPackages=MyGame" after "+EditPackages=SonicGDK".
 +
# Add or modify files of the ''UDKdir''\Development\Src\MyGame\Classes folder.
 +
# Compile; run the Unreal Frontend tool (''UDKdir''\Binaries\UnrealFrontend.exe), click on the "Script" button and choose the "Compile scripts" option from the list.
 +
 
 +
 
 +
You can then run a map with your custom code and assets. Example with SonicGDK test map:
 +
  (UDK dir)\Binaries\Win32\UDK.exe SonicGDKTestMap?game=MyGame.MyGameInfo
  
 
==Game deployment==
 
==Game deployment==

Revision as of 11:33, 8 September 2011

(Original guide by Xaklse)

Exclamation.svg This article is a work in progress.
Its content and location may change completely and frequently until this notice is removed.
A version of UDK must be downloaded and installed. Then, a SonicGDK script project needs to be downloaded and added to the engine. In order to develop and test your fangame, code must be compiled at least once. After development is finished, the final step is the creation of an installer file for distribution of your fangame.

Engine setup

Unreal Development Kit (UDK) is the free edition of Unreal Engine 3, a binary-only version used to create games on the PC. Acquiring UDK is simple; head over to the UDK download page and download the "June 2011 UDK Beta" release. Execute the downloaded .exe file and follow the instructions. After the installation process, close the UDK Editor if it's opened.

In order to add Sonic gameplay elements and items to UDK, UnrealScripts defining these elements must be added. A new UnrealScript project must be created which consists of a separate package which contains the new scripts, making sure the engine knows to include those when compiling and using the editor.

SonicGDK consists of an UnrealScript project, a test map and a pack of custom visual assets.
Sonic Retro
Get it
, uncompress it and copy the SonicGDK's folders Development and UDKGame and the .bat file to the UDK directory. Run the Unreal Frontend tool application (found in the Binaries folder of your UDK directory), click on the "Script" button and choose the "Full recompile" option from the list. If errors appear, make sure the UDK Editor is closed and retry.

Installation is complete; just a note: the first time that you open the test map, it will compile all the material shaders and take a really long time.

Running a map

To test the game using a map named "MapName", you have to run the game executable with a special option like "MapName?game=CodePackage.GameInfoClass"; you usually do that with a shortcut. Examples with real maps and SonicGDK:

 (UDK dir)\Binaries\Win32\UDK.exe SonicGDKTestMap?game=SonicGDK.SGDKGameInfo
 (UDK dir)\Binaries\Win32\UDK.exe DM-Deck?game=SonicGDK.SGDKGameInfo
 (UDK dir)\Binaries\Win32\UDK.exe VCTF-Necropolis?game=SonicGDK.SGDKGameInfo
 (UDK dir)\Binaries\Win32\UDK.exe FoliageMap?game=SonicGDK.SGDKGameInfo

Alternatively, you can run a map if you open it with the editor, but you'll get worse performance.

Project setup

If you want to program a new code package (called "MyGame") to use your own assets properly, follow these instructions:

  1. Close the editor if it's opened.
  2. Open the DefaultEngine.ini file of UDKdir\UDKGame\Config folder, add a new line "+EditPackages=MyGame" after "+EditPackages=SonicGDK".
  3. Add or modify files of the UDKdir\Development\Src\MyGame\Classes folder.
  4. Compile; run the Unreal Frontend tool (UDKdir\Binaries\UnrealFrontend.exe), click on the "Script" button and choose the "Compile scripts" option from the list.


You can then run a map with your custom code and assets. Example with SonicGDK test map:

 (UDK dir)\Binaries\Win32\UDK.exe SonicGDKTestMap?game=MyGame.MyGameInfo

Game deployment

Coming soon...