Jump to content
IGNORED

The Game Development Thread


A nice cup of tea
 Share

Recommended Posts

Although I came in with a lot of programming experience, all these engines require some relearning and general time to understand.  It's well worth the effort, it would take years to accomplish the same things from building your own engine up from scratch.

 

For me the choice was simple, Unreal Engine kept falling over on my old iMac I started using but Unity worked, so I used that.  I went through one of the courses on Unity's web site https://learn.unity.com/course/create-with-code It's quite a long slog, and with the course aimed at beginners some of the stuff seemed woefully slow, but there were some real gems hidden in there that I really needed.  Like understanding the UI system, or how to be able to communicate between scriptable objects.

 

I hadn't heard of GoDot at the time, I've had a look and started twiddling with it - but it's just too much of a stretch to relearn all the stuff that I'd already become comfortable with in Unity.  Worth looking at if you are coming at it new, and if you want to do 2d games.  It's quite nice that the code editor is built in (as opposed to using Visual Studio or something) and it's very lightweight so will run on less powerful systems.

Link to comment
Share on other sites

I'm going to get back to Broker's post in a bit, but I started the Unity tutorials and pretty much immediately bumped up against it, so I needed something super simple. Even then I'm doing a Space Invader clone in Tic-80 and I'm struggling to get my head around what needs to go where. I think I'm getting the basics of heirachy and how shit needs to be nested inside other shit but if the tutorial goes "Have a go and see if you can get it to work" my brain just shits itself and goes "Nah, man."

 

I haven't done any for a couple of days but I'm surprised I've stuck with it as long as I have. I'm going to get back to it when sitting in front of the PC isn't akin to having the oven door open and sticking my head in there.

Link to comment
Share on other sites

I've got a three-quarter-finished Space Invader clone project (it's a project I may yet revisit one day, because it's a little different). It was actually trickier than I first thought. Normally with games you want enemies to take care of themselves - i.e you put a script on them that tells them how to behave, and let them get on with it. With Space Invaders all the enemies act as one, so you want one piece of code somewhere that takes care of all of them. Even realising this I struggled with getting the behaviour right - getting them to speed up nicely as their numbers dwindled. It was only after reading exactly how the original game worked that I managed to get it working correctly. If you want any pointers let me know.

Link to comment
Share on other sites

I think it's a great idea to start on a little Space Invaders clone or just a game you know well.  I recently put together a quick Asteroids style game just for a break - which took about a day, but was interesting as the way it needed to be put together was completely different from my Sim game.  Much more instantiation and managing of objects.  I turned it into a bit of a fun thing for a podcast I'm involved in, sticking the faces of the hosts in as Asteroids and then using little sound bytes as explosion noises.

 

Weirdly this took about 3 weeks - 1 hour to change the code, and the remainder of the time to chase people up for a few sound samples !

 

 

Link to comment
Share on other sites

  • 2 weeks later...
On 25/06/2020 at 13:34, MarkN said:

I've got a three-quarter-finished Space Invader clone project (it's a project I may yet revisit one day, because it's a little different). It was actually trickier than I first thought. Normally with games you want enemies to take care of themselves - i.e you put a script on them that tells them how to behave, and let them get on with it. With Space Invaders all the enemies act as one, so you want one piece of code somewhere that takes care of all of them. Even realising this I struggled with getting the behaviour right - getting them to speed up nicely as their numbers dwindled. It was only after reading exactly how the original game worked that I managed to get it working correctly. If you want any pointers let me know.

I made a space invaders clone a few years back. I'll see if I have it here and post a cosy video. 

Link to comment
Share on other sites

  • 3 weeks later...

I keep getting discouraged because I go "I CAN DO THIS!" and then it all becomes in comprehensible. I'll get back on it soon. In the meantime Humble have just put this bundle up

 

https://www.humblebundle.com/books/game-design-animation-packt-books?linkID=&mcID=102:5f245c2ce94ed964022d14de:ot:56c3def6733462ca8940c884:1&utm_source=Humble+Bundle+Newsletter&utm_medium=email&utm_campaign=2020_08_03_blenderbypackt_bookbundle&linkID=&utm_content=cta_button

Link to comment
Share on other sites

  • 2 months later...

 

 

The equivalent of typing out lines of BASIC from the back of a mag but I really enjoyed the process and I kind of get the logic behind it, and now I have a load of ideas of how to start something I want to make from scratch. 

 

Still tempted to take the plunge with Unity, to be honest, but I've got a few 2D ideas and think I'm better trying to actually make and complete something over the next six months or whatever and see if my interest remains. 

 

 

 

 

Link to comment
Share on other sites

Hmm, I have tried the opening tutorials of Unity and I can see myself getting into that, but I only have a basic micro PC thing I bought for some light photo and audio editing, and it's creaking whenever I open anything. Hmm...Given this is just a a hobbyist thing for me, I think I'd better stick with GMS2 for now and see if I can make something simple from start to finish. 

Link to comment
Share on other sites

Quality soundtrack @Marlew You should license it out to Activision for the next COD. :D

 

Re: Dev... why not commit to GMS2 and focus on getting one of your ideas formed into something. Then if you have the bug it could justify a hardware upgrade and some toe dipping into Unity?

 

I've been on-boarding a new colleague in work and as part of the process have had to go through all my old git repos to find things and stumbled upon all my game demos/exercises. Very tempted to try and carve out a bit of free time over the winter to work on them again.

Link to comment
Share on other sites

  • 4 weeks later...
On 31/10/2020 at 10:45, Marlew said:

I downloaded it, too, and had a few good rounds on my tablet. I'll have a go on my phone, probably a bit easier with thumbs. Art style is really fun. 

I missed this. Thanks for that. There's an update coming soon with the Witch Shack opening up so stay tuned.

Link to comment
Share on other sites

  • 1 month later...
  • 2 weeks later...

Oh goodness this is addictive :D Why have I not looked into this properly before!?  Ahem. 

 

Anyway!  Dead pleased for 2 nights effort.  This is so much fucking easier than the crap I did at Uni back in early 2000s :lol:

 

 

 

Made good progress today.  In summary:

  • Moved materials for physics off the ball and onto the ground, grass and sand behave nice and differently
  • Added aiming lines, and setting of power by how far mouse pointer is from the ball
  • Added stroke count
  • Added water hazard / offscreen out of bounds, which resets ball after a short delay without resetting strokes
  • Can complete a hole which resets the course after short delay, and resets stroke count
  • Added particles for rain and for ball impacts on the ground (green/orange as appropriate

 

To do!

  • Sound
  • Add water splashes when ball enters water
  • Make the raindrops change texture once they hit the ground
  • See if I can do a dramatic zoom-in when nearly getting ball in hole (think Peggle and the last peg)
  • Main menu
  • Rescale things to get bigger courses
  • Set up chain of courses
  • Persistent overall stroke count for all courses
  • Save game / record handicap
  • Muck about with lightning & related lighting effects
  • Look at touch/mobile build 
Link to comment
Share on other sites

23 hours ago, robdood said:
  • Sound
  • Add water splashes when ball enters water
  • Make the raindrops change texture once they hit the ground
  • See if I can do a dramatic zoom-in when nearly getting ball in hole (think Peggle and the last peg)
  • Main menu
  • Rescale things to get bigger courses
  • Set up chain of courses
  • Persistent overall stroke count for all courses
  • Save game / record handicap
  • Muck about with lightning & related lighting effects
  • Look at touch/mobile build 

Third day's progress! 

 

 

Getting the levels to chain and the ball / camera to persist was a bit of a ball ache, but I figured it out and hacked together a decent enough solution :D

 

Also figured out doing builds so that vid is of the actual exe of my first ever unity game running! 

 

New to do list:

  • See if I can do a dramatic zoom-in when nearly getting ball in hole (think Peggle and the last peg
  • Save game / record best / lowest score & show it somewhere
  • Muck about with lightning & related lighting effects
  • Look at touch/mobile build 
  • Music / Persistent rain audiofx
  • Redo art assets to be slightly prettier and not so similar to desert golfing(!) 
  • Reluctantly look at more efficient / tidy ways of managing everything. Currently the vast majority of logic (including which hole to load next) takes place in a single script against the ball. Also have way more public variables etc than I should have, need to clean up and make some tidy public functions instead. 

Getting a little bit tired of looking at it now tho, so want to move onto something else new soon! :D

Link to comment
Share on other sites

@robdood

That's fantastic progress for 3 days work! Great stuff. Also I loved Desert Golfing, and that's a top choice for a first project. 

 

A few points based on your to-do list.

 

A touch build should be a doddle. It's probably mostly working already. I can't remember the details, but for my Picross game I hadn't considered it until after I released it. A mate said it almost worked, but had an issue or two, and I patched it the same day.

 

If you've not got too much in the way of save data, then there's a resource called File Based PlayerPrefs that might be helpful for you. It's basically the same as Unity's PlayerPrefs (which you want to be using to store local data like controls and screen resolution etc.), but stored as an encrypted text file. It makes simple save data a doddle, and can be used with Steam Cloud. https://github.com/richardelms/FileBasedPlayerPrefs

 

Definitely look at splitting up how the game is handled. For every project I start I make a bunch of scripts before I even know what I'm doing. 3 of the main ones are a game manager script, a front end manager script, and a player manager script. The game manager handles the flow of the game - level intro, gameplay, level complete, next level etc., the front end manager handles all the user interface (and this and the game manager swap control at regular intervals), and the player manager handles control of the player's avatar. I'll add loads more scripts after this, but it's a good start point.

 

Public variables/methods I wouldn't worry about - do whatever works for you, ignore what is deemed "correct" unless it becomes a problem. FWIW, I tend to have a script in every project I start called "globalStuff", in which I share as many public variables and functions as I can. Everything in my projects can look at it and find the "player", the difficulty level, the function that eases the timer in and out so that things accelerate and decelerate nicely, and dozens of other things - anything that's useful across the board. (Most objects in my game also have a reference to the game manager's script so that they can call public methods directly rather than using SendMessage. It just feels more direct and happens instantaneously.) Get() and Set() functions feel like you're doing the right thing, but public variables/methods work just fine in most cases. If you're not working with a large team of people then there's really no harm doing it this way. Use the formal method when it works for you, but otherwise take the easy route. (I still use Gets and Sets occasionally for variables that I might not remember the name of later (so typing "Get" will make autocomplete suggest what I'm after)).

 

Looking forward to future updates. Good luck with it.

Link to comment
Share on other sites

Thanks for that info and encouragement! Much appreciated :)

 

In a way I feel like I want to start the project over again so I can use the things I've learned to make things tidier! But am not going to do that just yet and carry on slower chipping away at things. 

 

Spent half an hour this morning putting in camera panning and zooming, so I can make longer courses. 

 

I also want to try and figure out if there's an easier way for me to create courses and set up collision etc, Eg, can I just make a 2D asset in photoshop and then somehow automatically create a bounding Polygon around it.  

 

Its mad, for the first time in a long while my brain is really pinging with creative energy. It's awesome :D

Link to comment
Share on other sites

8 minutes ago, robdood said:

I also want to try and figure out if there's an easier way for me to create courses and set up collision etc, Eg, can I just make a 2D asset in photoshop and then somehow automatically create a bounding Polygon around it.  

It's probably worth searching the Unity Asset Store. There's lots of great stuff on there. I've not worked with 2D but I'd be surprised if there aren't tools that will let you build 2D maps inside Unity itself. You might also find what you've described above, or maybe even something that will let you script procedural generation from prefab shapes.

Link to comment
Share on other sites

No update tonight, really. Spent ages trying to get nice smooth zooming in and out to work but it was way more fiddly and annoying than expected so I gave up in the end. Bah. 

 

The spent ages moving code around, renaming & breaking things, taking ages to fix them, then had an undo / mass replace fail which meant I had to redo loads! Sigh. 

 

But! I've pretty much separated out all my camera updates into a camera script, and related input management into the input script. 

 

Oh and I made a new type game object to manage each hole's settings a bit better. Thing like tee positions, course/hole ID, and dimensions to stop camera viewing empty space. So exciting! 

 

Next up - pull all input processing out of the ball script, leaving it to handle moving the ball exclusively. Then gonna make a game manger to handle which course/hole to load next etc. 

 

 

Link to comment
Share on other sites

3 hours ago, MarkN said:

What's the problem with the zooming? As I said I've not used 2D at all, but I might still be able to help.

Too big a story to write out in detail, but in summary, I was trying to get the camera to zoom out by changing camera orthographicSize and setting a target position. I also have a script which makes the camera follow the ball. 

 

I tried to write something that basically said:

 

if (holdingZoomButton)
	MoveCameraToCoords;
	ZoomOut;

else
	CameraFollowsBall;

but it just ended up doing this weird jittery thing where it seemed to get stuck trying to do both at once (i.e. camera wouldn't move to the target, and would jitter back and forth keeping the ball on camera).  If I removed the zoomOut bit it would translate the camera to the right place, it was infuriating. 

 

 

Link to comment
Share on other sites

4 hours ago, robdood said:

Too big a story to write out in detail, but in summary, I was trying to get the camera to zoom out by changing camera orthographicSize and setting a target position. I also have a script which makes the camera follow the ball. 

 

I tried to write something that basically said:

 


if (holdingZoomButton)
	MoveCameraToCoords;
	ZoomOut;

else
	CameraFollowsBall;

but it just ended up doing this weird jittery thing where it seemed to get stuck trying to do both at once (i.e. camera wouldn't move to the target, and would jitter back and forth keeping the ball on camera).  If I removed the zoomOut bit it would translate the camera to the right place, it was infuriating. 

 

 

 

There are a lot of assets for this stuff on the asset store and tutorials on the web.

It's hard to diagnose without seeing the code though.

Link to comment
Share on other sites

4 hours ago, Padaxes said:

 

There are a lot of assets for this stuff on the asset store and tutorials on the web.

It's hard to diagnose without seeing the code though.

Thanks, I'm just gonna leave it for now though - it can be a puzzle for another day! :D

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Use of this website is subject to our Privacy Policy, Terms of Use, and Guidelines.