UE3 - UT3 Default Vehicle Code problems

  • Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
I have a vehicle set up, and since it is similar to the way the Goliath works, I used the Goliath Classes as a base for it. The code itself is pretty straightforward, but I'm getting this error on compile...




Error, BEGIN OBJECT: The component name MyLightEnvironment is already used (if you want to override the component, don't specify a class): Begin Object class=DynamicLightEnvironmentComponent name=MyLightEnvironment ObjName=MyLightEnvironment Archetype=DynamicLightEnvironmentComponent'UTGame.Default__UTVehicle:MyLightEnvironment'




Now even at the most basic level, when I just copy the Goliath files and rename the assets to my assets and references to them as well I get this error.
This particular error is occurring in this bit of code... which is in the default properties at the bottom of my UTVehicle_Bulldozer.uc file...

It would seem that all I have to do is not specify a class as it says, but then it just compiles with more serious errors.
What I don't get is it is the same code all the other vehicles have...



Code:
Begin Object class=DynamicLightEnvironmentComponent name=MyLightEnvironment ObjName=MyLightEnvironment Archetype=DynamicLightEnvironmentComponent'UTGame.Default__UTVehicle:MyLightEnvironment'
      ObjectArchetype=DynamicLightEnvironmentComponent'UTGame.Default__UTVehicle:MyLightEnvironment'
End Object
LightEnvironment=MyLightEnvironment


EDIT: For those who viewed this previously I didn't format this correctly and had the wrong info... it is now fixed and the above info is correct...
 
Last edited:

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
Making progress...

K, here's the latest after I've been messing with it some more...

If I take the UTVehicle_Goliath, UTVehicleFactory_Goliath, and UTVehicle_Goliath_Content class files and put them in a new folder in my Src directory and compile them... I get this error still, without changing a single thing, not even the filename...

This leads me to believe there is some kind've dependency that I'm not aware of...

The other idea I had was to put my files into the UTGame and UTGameContent folders with all the other source code files and then compile.... and BINGO it worked.

Leading to my final assumption if anyone would be so obliged to reaffirm this or correct me if I'm wrong...

I had previously assumed it was ok to create a new vehicle with all the classes as a separate compiled folder, but apparently the classes need to be in their respective folders just like all the other vehicles in the game?

I just realized it didn't actually work, it just decided there were no files to rebuild and ignored the new files I added to the other folders (UTGame and UTGame_Content) so it didn't actually build anything... Anybody know how to force scripts to rebuild? I'm sure it's some simple, stupid flag or argument I need to pass when I run the make...

Thanks ahead of time
 
Last edited:

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
k, so I'm working through this.

I found and used the command line help commandlet for UT3...
Discovered by typing "UT3 help make" it gave me all the build options.

Long story short "UT3 make -full" will rebuild everything.

The only thing I have left to figure out is where/how I can get it to actually build a .u file that I can open in UnrealEd, the inherent problem is that if I put my class files into UTGame or UTGameContent and then full build it doesn't create any kind of .u file for me to load.

Ideas anyone?
 
Last edited:

DannyMeister

UT3 Jailbreak Coder
Dec 11, 2002
1,275
1
38
40
Bolivar, Missouri
First of all, you should always put your files into their own directory. You want your custom vehicle in a separate package than what ships with UT3. Each package you create will have a separate folder, and will result in its own .u file. So you were on the right track when you first started out.

As for the problem with compiling... where did you get the source for the Goliath? If you exported scripts from UnrealEd, it really messes up the default properties. You may want to have the downloaded scripts available from Epic as a reference, even though the latest version of those are from patch 1.2.
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
Thanks for pointing me in the right direction again...

And yep, that was the problem, the code that UnrealEd exports is different in the default properties compared to the UnrealScript Source you can download from Epic.

Thanks a ton.
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
One last one I guess... would there be any code related reason that I can place my vehicle in the editor and it is there and I can see it and edit it's properties, but when I load up the map it isn't there in-game?
 

DannyMeister

UT3 Jailbreak Coder
Dec 11, 2002
1,275
1
38
40
Bolivar, Missouri
You directly placed a vehicle in a map, or did you use a vehicle factory?

I think it is more a problem of not finding your package in game even though the editor can. are you running both the editor and game with -useunpublished?
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
I've just got it fixed...

I was pointing my VehicleFactory to Bulldozer instead of Bulldozer_Content.

So it shows up in game...

Next step is to make heads or tails of how it is actually operating, as I used the Goliath as a base, and it isn't operating at all how I expected...

I thought I read somewhere there was a way to do editactor or some other way to debug vehicles on the fly? That would be what I need right now, so I can see where it thinks the wheels are, and get it driving correctly first...

Once it drives correctly I'll be happy, I don't mind banging my head against a wall over everything else.
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
Sweet, that's pretty cool.

However a lot of the things I want to play with aren't in there...

This means I'll have to go in and override those values as //Editable in my vehicle class?

I'm also using the -useunpublished flag so that I don't have to mess around, I can keep building and running without publishing anything..

BTW that was the most helpful thread I've read yet, thank you.
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
The next wall I'm hitting, is the vehicle is on its side, and I can't seem to figure out how to set it so that it is upright and drives correctly...
I can't get in it when it's on its side either... When it spawns it just pops up into the air and lands on its side.

Is there a way to change default values for a class and then summon an instance of that class so that I can keep testing to see if I can't get it to land upright when it spawns?



It makes using the remote control frustrating because that means I can't drive and test the values I'm tweaking...
It also doesn't steer just goes forward and backward, but I'm sure that's another problem altogether, one thing at a time.


While I'm at it, might as well pose a few more questions, as the answers would be invaluable.
Is there any way to set up a batch file or shortcut with switches that will load a certain map by default, so that I don't have to go through UT3's menu system every time I want to run my test level?

And my other question, is there anyway to turn on drawing of the invisible wheel objects vehicles are using?
 
Last edited:

DannyMeister

UT3 Jailbreak Coder
Dec 11, 2002
1,275
1
38
40
Bolivar, Missouri
I don't know answers to most of those questions off the top of my head. I am exhausted and about to head to bed (or I'd research because I'm curious especially about viewing wheel collision :) ), but I do have a quick answer for loading a certain map. Just specify it's name on the command line. These pages are for setting up servers, but should still be helpful for you, just leave out the "server" switch.

http://utforums.epicgames.com/showthread.php?t=578745
http://midnightgamingservers.com/ut3faq.shtml
 

frost0fractal

Frost0Fractal
Mar 13, 2008
82
0
0
NY
This should almost be a different thread by now.... BUT...

yeah that worked...

Basically create a shortcut to your UT3.exe file and then append this after the target part of your shortcut properties...

DM-Map?numplay=0 -windowed -wxwindows -useunpublished -log

In this case, the map, the number of bots, windowed mode (you can also set -resx=NUM -resy=NUM after that for a specific resolution), then -wxwindows enables the remote control, then use the unpublished folder (easier than cooking stuff), then keep the log window open...

Once I finish the vehicle I'm working on I plan to write a good tutorial on doing vehicles from Maya all the way till it works good in the game...
Although there are 3 vehicle types, so I'll have to do 2 more to truly write a good tut. This time I did a tank, next I'll do a car, then a flying/hovering one after that.
 
Last edited:

DannyMeister

UT3 Jailbreak Coder
Dec 11, 2002
1,275
1
38
40
Bolivar, Missouri
Once I finish the vehicle I'm working on I plan to write a good tutorial on doing vehicles from Maya all the way till it works good in the game...
Although there are 3 vehicle types, so I'll have to do 2 more to truly write a good tut. This time I did a tank, next I'll do a car, then a flying/hovering one after that.

That would be excellent.