Upgrading a large, poorly coded game to Unity 5....

I’m upgrading my game, The Barbarian, to Unity 5.

I want to have it available on the Apple TV, so Unity 5 is required. Plus I’ll likely benefit from things like easy analytics and heat maps and all that.

HOWEVER. There were 966 “Errors”. I’m down to about 885. Mostly to do with replacing things like audio. to GetComponent.(). etc

Slow going.

Each time I make an update, I have to wait a few minutes for Unity to compile and show me the latest errors, and often it takes a few tries to get the new code right.

That’s it. :slight_smile:

did it not auto convert it for you?

usually does.

2 Likes

It did some – crashed 5 times during it all, then finally opened up.

A lot of the errors say “(Unity Upgradable)”, but it’s not prompting, so I’m assuming there’s something else that’s keeping it from running that process.

bugger!

Can you do a find/replace on the more common wording to cut back on searching/typing for the more common combinations?

For the most part – I’m basically making fixes, a lot of them, and then saving all the files at once, to avoid having to wait for each fix. I’m down to 650 now. Most are the same ones.

If I had been smarter before, this would have been much more simple :slight_smile:

Unfortunately I just realized I was replacing PlayClipAtPoint (and removing the position) with PlayOneShot … I’ll have to go back and fix a lot of those later.

Did you try doing a “replace all”

That’s what I do, mostly, per script. Basically just double click the error, and almost all are the same type, so I just replace all for most. Some, I’ve found, I can’t – like if my variable is playeraudio then I can’t do replace audio. with GetComponent.(). because I mess up more things.

Fortunately the errors mostly come in pairs – so with 250 left, there’s really just 125 left.

SWEET. Kind of.

It’s all working, no errors… Now I just need to figure out why my menu screen isn’t clickable. New canvas buttons are, but this one isn’t.

And it doesn’t work w/ the gamepad anymore. Got to figure that out too I guess.

Last time I did a big upgrade like this (old network to UNet) it ended up being easier to do a rip and replace.

Yeah. I’m going to either not upgrade at all or have to start from near scratch. It’s a pretty big game though, so I think it may not be worth it. Only cause I don’t have any idea at all how long it’ll take.