Author Topic: Question about Unity and HuC  (Read 378 times)

soop

  • Hero Member
  • *****
  • Posts: 2828
Question about Unity and HuC
« on: March 01, 2017, 02:00:58 AM »
Just discussing starting a new project with my housemate, and I figured since he needs to learn C# for his new job, we could collaborate on a making game together in C#, probably using Unity as a framework.

Now, I've had a game in mind for years that's super, super easy, and it just struck me that we could knock it out Unity in maybe a week or so.  But since it was originally planned for me to get my feet wet with HuC, it was intended for the PC Engine.

I know I can't simply port the code over, it won't work that way, but before I start, is there anything I can do to make my life easier if I decide to rewrite it in HuC at some point?  I've never used either at this point, and I've barely ever touched C.  I'm guessing it's just going to be a case of "you need to rewrite it completely, but at least you'll have an idea of what needs to go where", and I'm ok with that.  I can probably reuse graphics if I go about it the right way.

elmer

  • Hero Member
  • *****
  • Posts: 2148
Re: Question about Unity and HuC
« Reply #1 on: March 01, 2017, 05:12:30 AM »
I know I can't simply port the code over, it won't work that way, but before I start, is there anything I can do to make my life easier if I decide to rewrite it in HuC at some point?  I've never used either at this point, and I've barely ever touched C.  I'm guessing it's just going to be a case of "you need to rewrite it completely, but at least you'll have an idea of what needs to go where", and I'm ok with that.  I can probably reuse graphics if I go about it the right way.

I suspect that you'll find that you won't get to re-use much of anything.

Unity provides a huge framework and library and, most-importantly, methodology, that just aren't going to be there when you go to HuC.

But you would be able to prototype how you want your game to actually behave, and you'd go through all the stages of game design and game construction that you'd need to do anyway for a PCE game, so that would be good.

I suspect that you might find it incredibly frustrating to go from the gentle fluffy hand-holding of the Unity environment back into the harsh and unforgiving old-skool world of HuC, but I expect that you can do it, if you have the will.

The biggest thing to remember (IMHO), is that in HuC you're going to want to avoid objects and structures as much as possible, and completely avoid recursion and too much (if any) parameter passing (except "fastcall" functions).

Which is pretty-much the opposite of how you code in a modern object-oriented language like C# and in the Unity environment.

Gredler

  • Guest
Re: Question about Unity and HuC
« Reply #2 on: March 01, 2017, 05:30:39 AM »
I worked at a studio that used unity to make their games, we made these while I was there:



While I was there I became very familiar with Unity's image requirements, and C# integration.

I've now been working on a HuC based homebrew for almost as long as I was at that company, and I still have no idea how to modify the code beyond palettes, and can say that the art requirements are completely different.

I would say there is 0 crossover from Unity and C#, to HuC and C. Keep in mind, C# is a much much much higher level language than C++, which is higher level language than C - not all C languages are the same by any means.


I would also say, there are MUCH better 2D engines available that would be faster to prototype games in, Game Maker and Construct 2 (soon 3) are a lot easier to get up and running quickly, and the logic translates better to HuC than unity considering the 2D v 3D hurdles of unity which is a renderer that is forced to orthographic but is basically just forcing 3D stuff to appear in 2D.
« Last Edit: March 01, 2017, 05:33:24 AM by Gredler »

soop

  • Hero Member
  • *****
  • Posts: 2828
Re: Question about Unity and HuC
« Reply #3 on: March 01, 2017, 08:03:56 PM »
Got it, thanks guys :)

I would also say, there are MUCH better 2D engines available that would be faster to prototype games in, Game Maker and Construct 2 (soon 3) are a lot easier to get up and running quickly, and the logic translates better to HuC than unity considering the 2D v 3D hurdles of unity which is a renderer that is forced to orthographic but is basically just forcing 3D stuff to appear in 2D.

I'll check these out, thanks :)

Pokun

  • Full Member
  • ***
  • Posts: 153
Re: Question about Unity and HuC
« Reply #4 on: March 01, 2017, 11:01:09 PM »
Another thing to keep in mind is the sprite, color and resolution limitations of the PC Engine.
If you make a CD game sound may note be that much of a problem though.

Arkhan

  • Hero Member
  • *****
  • Posts: 14142
  • Fuck Elmer.
    • Incessant Negativity Software
Re: Question about Unity and HuC
« Reply #5 on: March 04, 2017, 08:31:45 PM »
The only thing you will get to reuse is any logic you might have for enemy behaviors and crap.   

But even that will need to be redone a bit, and will probably be slow if you don't go back to assembly with it.

Unity would still be good to use to prototype stuff out though, so don't think there is no point to using Unity.

[Fri 19:34]<nectarsis> been wanting to try that one for awhile now Ope
[Fri 19:33]<Opethian> l;ol huge dong

I'm a max level Forum Warrior.  I'm immortal.
If you're not ready to defend your claims, don't post em.