PDA

View Full Version : Use Visual Studio 2008 with nFringe and UDK



SneakyToB
11-11-2009, 03:01 PM
The tutorial at the beginning of this thread is currently completely wrong for nFringe 1.1.10+. I've posted a much simpler set of instructions on our wiki:

http://wiki.pixelminegames.com/index.php?title=Tools:nFringe:UnrealScript:UdkProj ects

I removed the old tutorial since it was for earlier versions of the UDK and nFringe and seemed to be causing confusion. Hopefully that link will stay current for new versions of nFringe and UDK since I haven't been keeping up to date with it lately.

wildicv
11-11-2009, 03:29 PM
Thanks for this i was having some issues using nfringe.

elmuerte
11-11-2009, 04:16 PM
Interesting, that's pretty much the same as I was writing for an UDN document, except that I got stuck with nFringe at "create project".

Here's last night's version of the document I was working on: http://udn.epicgames.com/Three/DevelopmentKitFirstScriptProject.html

SneakyToB
11-11-2009, 04:30 PM
Cool, that UDN document was exactly the type of information I was looking for a few days ago. I couldn't find very much so I just tried to figure it out using what I could find and lots of trial and error. Please, feel free to add anything I wrote here to that UDN doc to make it more complete.

Also, if visual studio won't create a project make sure the folder you are trying to create the project in does NOT already exist.

Death4Hire
11-11-2009, 08:33 PM
Why Visual Studio?
Using Visual Studio with nFringe makes coding unrealscript much easier, mostly because of getting a "Go to definition" link by right clicking in the code, syntax highlighting, and intellisense which shows what functions can be called from various objects.

Background
This will explain how I got it working because it wasn't very straight forward, at least not to me.

To begin, this tutorial will assume you have already installed Visual Studio 2008 (this should work in the free Express edition but I have not tried it). You also need to have installed nFringe (http://wiki.pixelminegames.com/index.php?title=Tools:nFringe) by following the instructions. Obviously, you need to have installed UDK as well and make sure you run the UDK game demo at least once before following this tutorial so the config files get generated.

Next, this tutorial expands on the UDK Programming Tutorial (http://udn.epicgames.com/Three/DevelopmentKitProgramming.html) but sets it up to work with Visual Studio. So be sure to download the SuperFunGame.uc (http://udn.epicgames.com/Three/rsrc/Three/DevelopmentKitProgramming/superfungame.uc) sample source code.

Setup
1. Create the project in Visual Studio

Create a new project of type "UnrealScript" and select "UnrealEngine 3 Licensee Project"
Name: enter "SuperFunProject" or whatever you would like the package to be called.
Location: pick C:\UDK\UDK-2009-11\Development\Src
Uncheck "Create Directory for solution"
On the solution drop down leave it on "Create new Solution"
Finally, click OK to create the project

2. Configure the project

Right click on the project in the Solution Explorer and click Properties
Under General -> Game -> Target Game pick “UnrealEngine 3 Mod” from the drop down menu (this is needed because you can’t set the “Reference Source Path” when using the “UnrealEngine 3 Licensee Project” type.
Under General -> Script Compiler -> UCC Path pick: C:\UDK\UDK-2009-11\Binaries\Win32\UDK.exe
Under General -> Script Compiler -> Reference Source Path pick: C:\UDK\UDK-2009-11\Development\Src
Under Build -> Script Outputs check “Manual set UCC output directory” and set the path to C:\UDK\UDK-2009-11\UTGame\Script
Under Debug -> Start Action -> Start Game Executable set the path to C:\UDK\UDK-2009-11\Binaries\Win32\UDK.exe
Check “Enable unpublished mods”
With the project selected in Solution Explorer, right click, and select Add -> New Folder. Type “Classes” and hit enter. Now any new classes you make should be added under the Classes folder. To follow this tutorial, add "SuperFunGame.uc" which you downloaded above. Right click on "Classes" and select "Add existing item" (make sure you copied it to your Classes folder first in Explorer) then select "SuperFunGame.uc"
Finally, close the solution (MUST exit Visual Studio) and then reopen it. This adds all the Reference Source files which is the UDK source code. It also allows Intellisense to work correctly.

3. Build the project

Add an existing file (as a link) to your project from C:\UDK\UDK-2009-11\UTGame\Config\UTEngine.ini. Click the arrow to the right of Add and select "Add as a link". This way it won't copy the file to your project directory.
Edit the file and search for “ModEditPackages=” and make sure your mod name package is included there. Add a line: "ModEditPackages=SuperFunGame" if you are following this tutorial (now save and close UTEngine.ini).
Make sure the Output window is open in Visual Studio. Now you should be able to build using Visual Studio (press F6) or pick Build -> Build Solution from the menu. You will probably get an error about not being able to find the .NET Framework SDK but you can just ignore it.
Check your C:\UDK\UDK-2009-11\UTGame\Script folder for the output of the .u file for the package you just compiled. In this case, there should be a SuperFunGame.u file at that location.
Finally, if you see the .u file in there for the package you just build, then you are ready to test it out.

4. Run the project

Under the project properties -> Debug -> Start Action, check “Load map at startup” and type "dm-deck" or whatever map is available
Check “Start with specified game type” and type the "ModPackage.Class" such as "SuperFunGame.SuperFunGame"
Check “Enable unpublished mods”
Check “Open log window at position” and position it wherever
Run your project by pressing F5 inside Visual Studio
Visual Studio will pop up an information bubble saying that pixel mine doesn’t allow the free non-commercial nFringe to attach to UE3. But it can still be used to run the code and/or look at the log console or output.


There are corrections on this.

The quickest way to get this right is instead of naming your project as SuperFunProject as indicated in step 1, name it SuperFunGame. Otherwise, you have to do these corrections:
Step 3.2: ModEditPackages=SuperFunGame should be ModEditPackages=SuperFunProject
Step 4.2: SuperFunGame.SuperFunGame should be SuperFunProject.SuperFunGame

I hope this helps.

SneakyToB
11-11-2009, 10:34 PM
Thank you, Death4Hire. I just edited my post above in step 1 to say create a project named "SuperFunGame" instead of "SuperFunProject".

elmuerte
11-12-2009, 01:44 AM
Also, if visual studio won't create a project make sure the folder you are trying to create the project in does NOT already exist.

I was doing that, but I keep getting an error message that it can not copy the project file from a temp directory. Anyway, I have yet to bother Pixel Mine about this.

twoflyingpigs
11-12-2009, 01:47 AM
Can you debug/Step through unrealscript code with nFringe?
I'm using WOTgreal now, it works great but a bit slow when edit large script file, and lack of any debugger integration with UDK.

Sir_Brizz
11-12-2009, 02:27 AM
Then it's not far behind nFringe :) Debugging doesn't work in UDK, it was purposely locked to UT3.

fallingbrickwork
11-13-2009, 09:41 AM
Well I have VS2008 and nFringe setup and my project is compiling fine, so many thanks for this thread!

My question is... Is there anyway of working on scripts within VS2008 at the same time as working in UDK?

I mean, when I compile the solution within VS2008 I get a build error when the core compiles as the UDK is open. When coding I do tend to build and test constantly which means closing and opening UDK every few minutes.

Maybe I've missed something obvious or am a total noon!

Regards,
Matt.

SneakyToB
11-13-2009, 04:11 PM
I'm glad this thread was useful for you, fallingbrickwork.

To answer your question it doesn't look like what you are trying to do is possible even if you compile using the UDK make system and bypass Visual Studio. To recompile the scripts it has to overwrite the existing ones (.u files), which it can't do because they are currently in-use and opened by the UDK editor (if you are running it). So, it looks like the only way around this is to close the UDK editor every time you compile the scripts.

LordsWarrior
11-17-2009, 04:44 AM
Hi

So got every thing going with nFring up to the pointto do the build solution.
Im using the new beta2 BTw.

For some reason it is not generating the .u file.

Ive down all the above as the tutorial (following this TUT:
http://www.dl.deathtouchstudios.com/videotutorials/UnrealScriptSeries/US01-SettingUpBuildEnvironment/

THe build says its successful and displays this:
MyGame -> D:\UDK\UDK-2009-11-2\Development\Src\MyGame\MyGame\Unpublished\Cooked PC\Script\MyGame.u

(Note the double MyGame\Mygame ...strange?)

However the MyGame.u never gets made or copied to the UTgame\scripts folder I had specified:
D:\UDK\UDK-2009-11-2\UTGame\Script

Any ideas? Any one tried with beta2?

Its not because IM using a "non-commercial" version of nFringe is it? I'd imagine most people use that?

Thanks heaps

-LW

roychr
11-17-2009, 11:22 AM
Anybody knows how to step in into unrealscript and debug with VS ? I know it was advertised somewhere for UDK.

schizoslayer
11-17-2009, 11:39 AM
Anybody knows how to step in into unrealscript and debug with VS ? I know it was advertised somewhere for UDK.

At the moment you can't without a commercial nFringe licence.

hide
11-17-2009, 12:45 PM
For some reason it is not generating the .u file.
...


Same, I did a search in my whole UDK folder No superfunproject.u file anywhere.

The build output anounce that :

SuperFunProject -> L:\UDK\Development\Src\SuperFunProject\Unpublished \CookedPC\Script\SuperFunProject.u

I specified that in the build setup :

L:\UDK\UTGame\Script
(note : I installed udk without the "\udk-2009-11-2\")

roychr
11-17-2009, 02:17 PM
At the moment you can't without a commercial nFringe licence.

Is it me or the nFringe minimum 3500$ for the software is maximum overkill for UDK ? considering that Visual Studio pro is about 600$, they could at least give a version that support debugging and if you release something you have to pay them. I understand they must get paid for this tool, but even T3D + Unity + UDK together does'nt amount to that...

shame, considering UDK advertised debugging as stock in the engine...

schizoslayer
11-17-2009, 03:46 PM
Is it me or the nFringe minimum 3500$ for the software is maximum overkill for UDK ? considering that Visual Studio pro is about 600$, they could at least give a version that support debugging and if you release something you have to pay them. I understand they must get paid for this tool, but even T3D + Unity + UDK together does'nt amount to that...

shame, considering UDK advertised debugging as stock in the engine...

Unfortunately nFringe is developed by a company unrelated to Epic so they are allowed to charge whatever they want and Licensees are quite willing to pay the large pricetag of a commercial licence.

It should be possible to get WoTgreal to work with UDK as UDK is intended to work the same way as the older UT games and not use the odd UT3 mod structure.

youkai
11-17-2009, 04:01 PM
It compiles fine but I cannot find my *.u file in the script-folder. I cannot find it anywhere. What's wrong? And on starting it claims, that my scripts where outdated and asks me to rebuild...

Edit: Okay I fixed it. You have to create your solution to the development/src folder.

Blade[UG]
11-17-2009, 07:56 PM
schizo: actually WOT works fine, but it doesn't understand the INI or log files. I haven't heard from Harmon in at least a year and a half now, since the last development update, so I don't think he has any interest in going there. Maybe he hasn't heard about UDK, though.

net968
12-02-2009, 03:45 AM
It compiles fine but I cannot find my *.u file in the script-folder!!!

Help!!!!!!!!!!!SOS

SpartanDonut
12-04-2009, 05:25 PM
I am having the same issue as many of the other people here. It claims to create the file at ..\Development\Src\SuperFunProject\Unpublished \CookedPC\Script\SuperFunProject.u

However, SuperFunProject.u file is MIA - not to be found in the above location or the UTGame/Script folder I specified.

Running Windows 7 Pro - 64bit with UAC Disabled (Read this somewhere saying it may help but no go)

Any thoughts?? =(

RuBenKlunZ
12-05-2009, 05:54 AM
When i'm in the properties of visual studio i don't have the build tab, it gives me weird error, anyone know how i can manually change the build path

SpartanDonut
12-05-2009, 06:00 PM
Fixed my issue. Turns out I was just being stupid. My UTEngine.ini file had "Packages=MyMod" instead of "ModEditPackages=MyMod"

Changed it and problem solved.

Sainoob
12-19-2009, 05:59 PM
Hey for me it says 'Warning - paths may not be valid' in the log. I've triple checked everything, tried with UDK, the second version of it, reinstalled each about 3 times, but it still says that. Anyway I can fix this??

andresch
12-20-2009, 05:15 PM
Just in case it helps anyone, at one point I had added the file extention ".uc" to VS2008 to get C++ color coding when viewing scripts. This was then interfering with trying to get things working with nFringe, so if you have problems check for that...

SpoinkX12
12-21-2009, 04:14 AM
I have solved the not generating the .u file in the UTGame\Script folder issue. To fix this issue I took the following steps:

..\Development\Src\SuperFunProject\Unpublished \CookedPC\Script\SuperFunProject.u

Make sure the path it is saving looks like that, chances are it probably doesn't. More than likely it looks like this:

..\Development\Src\SuperFunProject\SuperFunProject \Unpublished \CookedPC\Script\SuperFunProject.u

You need to remove that duplicate path. Just move all the files so there is only one instance of the \SuperFunProject path. After you've done this, head back into UDK and it should tell you your scripts are not up to date. Let them rebuild, and in should generate your SuperFunProject.u file. Now technically, you can go back to Visual Studio and begin editing, but you may have a dead link to your UTEngine.ini file in your project. Just remove and readd the Existing Item link to the UTEngine.ini file, just like you did it in OPs tutorial.

I know thats not very thorough, go ahead and ask if you are having any problems with this solution.

BZB
01-13-2010, 01:14 AM
^^ that wasn't my problem I checked the paths and they were set correctly. Still cannot see the .u file after building (even though it says the build succeeded). After I put your .uc file in my classes directory and add it to my project should I see anything change on my solution explorer?? That was one thing I thought was odd was that I didn't see the .uc file after I added it.

I've tried to search through the UDK folder and I don't see SuperFunGame.u anywhere. I ran the unreal frontend make-->full recomplie and that made the .u file correctly.... but I don't get why it wouldn't make it in VS.

SuperFunGame's root folder is in the dev/src folder like you asked it to be, I edited the .ini file to 'ModEditPackages=SuperFunGame' also. I read though other people's problems not generating the .u but they dont seem to apply to me... suggestions?

UPDATE:
So I was really wondering why my classes folder wasn't showing anything... I tried to add a new class (called SuperFunGame and copy/paste your code into it... which made it appear under classes... however now when I build it'll say the "Ucc" task failed unexpectedly).
http://dl.dropbox.com/u/322696/Error.jpg

Also I noticed even when there were no classes it tried to make a .u file (which is prolly why I never saw the .u file). But I dont get what I did wrong now =/

280Z28
01-13-2010, 10:58 AM
As should be clear by this point in the thread, I haven't had the chance yet to experiment with UDK and thus clean up the cooperation between it and nFringe. The code editing features should work with it currently, but building and debugging scripts won't.

nFringe, like UnrealEngine itself, is free for non-commercial use and paid ("expensive" to some) for commercial use. However, we were careful to keep the cost completely practical for commercial development teams and as low as possible yet still have a reasonable expectation of covering the costs of our 2-year development effort in a niche market.

Before UDK came around, it was easy to rely on Epic's strict mod licensing policy to separate non-commercial use (UT3 mods) from commercial use (anything else). The new policies (pricing and licensing) makes it harder to distinguish between uses with UDK, so before we can offer debugging support under UDK we'll have to resolve the new licensing concerns it brings. While I'd like to say this will be solved by the end of the coming Summer, I think we'll have to just see how it goes. :)

If the lack of script debugging under UDK is hindering your development efforts, it can't hurt to let Epic know. :)

BZB
01-13-2010, 05:55 PM
ne1 have any ideas why I get that UCC error?

UPDATE:
Sigh** I figured it out, I set my UCC path to the UDK.exe.config instead of just UDK.exe ... didn't notice

I mean when I set the path I clicked on the UDK.exe (which is really the .exe.config).

Also if you just see that it made the .u file but not giving you an error... make sure you actually have some code in there it can look at... because it'll say that it made a .u file even if there is no code (and thus no .u file will be made).

roychr
01-13-2010, 11:01 PM
280Z28

Any contact information for contacting Epic ? Nice job for nFringe, and nice to know Epic and you are trying to get the debugger available, I must say that the ability to debug is one of the thing I hate about Unity3d. Torque3d is complicated for a C++ engine, compared to Ogre3d and that leaves you to make a difference, the only thing that is still a turn off for UDK is the browser gaming being non available.

Wraiyth
02-18-2010, 07:12 AM
Man, I can't even get my files to add to my solution if I use add existing item, it just doesnt appear at all. This is really frustating :(

Loginus
02-19-2010, 06:36 AM
I installed nfringe and I can create unreal script projects, but I dont see an option for debugging unreal script. I saw it at my university under debug menu, but i dont know how to configure my installation of VS 2008 to have the same functionality. Can someone give me a hint how to enable different debugging modes in VS? Thanks in advance ;)

Spithaz
02-23-2010, 08:43 PM
i can't Debug it cause my debug choices are greyed out ^^
what should i do ?

roychr
02-23-2010, 08:53 PM
Debugging is not supported yet by nfringe

Mr.CG
04-25-2010, 02:27 PM
Maybe I am being stupid or blind, but there is no UTGame folder in my UDK directory!

http://img213.imageshack.us/img213/8012/problemk.png

I am using the 04.2010 version. I would be very grateful if anyone of you guys helped me to solve this problem.

UPD: Haha, problem solved. It turned out that Epic renamed "UTGame" into "UDKGame"!

# Renamed to UDKGame

* All the tools now refer to this game as 'UDKGame'
* UDK content directory is now named UDKGame, not UTGame.

The tutorial must be updated soon, so no one else is confused. =)

Mastershadow
05-08-2010, 01:36 PM
Ok, so everything builds fine, however I'm not getting my .u file anywhere. This is the error message that I get in the output window.

------ Build started: Project: MageWarTD, Configuration: Debug Win32 ------
Could not locate the .NET Framework SDK. The task is looking for the path to the .NET Framework SDK at the location specified in the SDKInstallRootv2.0 value of the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramewor k. You may be able to solve the problem by doing one of the following: 1.) Install the .NET Framework SDK. 2.) Manually set the above registry key to the correct location.
MageWarTD -> C:\UDK\UDK-2010-04\Development\Src\MageWarTD\Unpublished\CookedPC\ Script\MageWarTD.u
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========




EDIT: On a side note I do have .NET Framework 4.0 installed.

280Z28
05-08-2010, 01:52 PM
Ok, so everything builds fine, however I'm not getting my .u file anywhere. This is the error message that I get in the output window.

Try again with the latest preview release:
http://wiki.pixelminegames.com/index.php?title=Tools:nFringe:Releases#Latest_Prev iew_Release

Follow the steps under Building Scripts here:
http://wiki.pixelminegames.com/index.php?title=Tools:nFringe:UnrealScript:UdkProj ects

waterxyro
05-08-2010, 05:40 PM
Ok, so everything builds fine, however I'm not getting my .u file anywhere. This is the error message that I get in the output window.

------ Build started: Project: MageWarTD, Configuration: Debug Win32 ------
Could not locate the .NET Framework SDK. The task is looking for the path to the .NET Framework SDK at the location specified in the SDKInstallRootv2.0 value of the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\.NETFramewor k. You may be able to solve the problem by doing one of the following: 1.) Install the .NET Framework SDK. 2.) Manually set the above registry key to the correct location.
MageWarTD -> C:\UDK\UDK-2010-04\Development\Src\MageWarTD\Unpublished\CookedPC\ Script\MageWarTD.u
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========




EDIT: On a side note I do have .NET Framework 4.0 installed.

Don't mind the SDK warning. I get the same thing and I have 3.5 installed. As for the .u file not showing up. If you followed the tutorial correctly, it should be in the C:\UDK\UDKGame\Script folder if you are using April Beta UDK or C:\UDK\UTGame\Script folder if you are using March Beta.

280Z28
05-08-2010, 05:44 PM
If you followed the tutorial correctly

The tutorial at the beginning of this thread is currently completely wrong for nFringe 1.1.10+. I've posted a much simpler set of instructions on our wiki:

http://wiki.pixelminegames.com/index.php?title=Tools:nFringe:UnrealScript:UdkProj ects

Saishy
05-08-2010, 10:23 PM
I can't change the folder for my solution, I changed all the configurations but the solution is still being build on the march build, instead of april.

D:

Edit: Actually, it's not being build anywhere!
o.o?

Does it need to be at the development/src folder?

Edit2:

Ok, bunch of errors:

I installed a new fresh UDK, the april build.
I did a new solution at development/src named UdkProject
The Classes folder was being created at development/src instead of development/src/UdkProject
Every time I tried testing, it game me the warning "there is no *.u files at development/src/UdkProject/Classes" but the folder is not even there
Now I removed the line #+EditPackages=UdkProject from DefaultEngine.ini, but when I try to debug I get the hovering game controller, instead of the default UI and player.

Edit3: Forget that, moved the visual studio files to inside UdkProject folder, changed to unreal 3 mod and defined Reference Source and everything is working now :D

AzadMamedov
12-19-2011, 07:41 AM
hi guys.who have facebook ?(http://www.facebook.com/profile.php?id=100000859057353)
I want to create my game in UDK+nFringe+visual.please help me
I have a problem _Error: specified start executable does not exist._
give me link to visual studio which you use...my visual 2008 team suite but watch to this link http://www.boxca.com/manroxc8emlt/azadmemmedov.rar.html


azad.mamedov777@gmail.com