CSharp 2D Game Engine Framework

Small update for those who are interested. Instead of creating an engine, I’ve resorted to merely creating a framework that you can utilize to make your own engines. They are only project templates, so feel free to add/remove/change code to your liking. I’m by no means an expert programmer, so you probably won’t see the best code and program structure. But if even one person finds it useful, I’ll be happy. Also, I’m not great with documentation. It’s something I know I need to do as a standard, so I apologize for the major lack of it.

You can still find it on my GitHub page here.

Original post

! So, over the past year or so, I’ve been teaching myself C# through various means. I’ve always wanted to make an engine with C# for the community, and I’m trying to do just that. But I’m not promising anything. I’m rather content with what I’ve written so far, even though I know it’s not the best thing you’ll find. Feel free to leave constructive criticism if you’d like.
!  
! In regards to the features of the engine so far, you can’t really produce a game with it right now. All that’s established is networking, a custom user interface, and graphics. There’s just a test menu displaying what the custom GUI can do, and that’s pretty much it. Nothing too special.
!  
! Here’s a link to the GitHub repository for the engine.
!  
! I was using SFML 2.1 when building this engine which was the current version at the time. I now see they released a new version (2.2), but I can’t guarantee that it’ll work flawlessly with my code. Use 2.1 just in case. Keep in mind that I’ve got the x86 bindings in the engine now. If you want them to be x64, you’ll have to change it yourself. You can find them on SFML’s website.
!  
! Enjoy 🙂

Forking and testing it out 🙂

~~EDIT: Why are they references not already in the solution? 😮 Now I have to figure out how to add in a library in VS ~~ Fixed this

EDIT2: Add a read-me to the repo so that we can get some placeholder graphics to run the engine? 🙂

I hope you get some help with this and the community can bring a 2015 engine

I’m with spirits on this.

Thanks for trying. The community is only as good as the members contributing to it.

Thanks guys! I’ll try and push out another update soon.

Forking and testing it out 🙂

~~EDIT: Why are they references not already in the solution? 😮 Now I have to figure out how to add in a library in VS ~~ Fixed this

EDIT2: Add a read-me to the repo so that we can get some placeholder graphics to run the engine? 🙂

Will do! Thanks for the suggestion!

So, I’ve got a bit of progress. What with school being a thing, it’s diminished the time available to me to develop, but I managed to push something out for today. I’ve added in the ability for the server to send files to the client, I isolated a few variables, and I improved the way graphics are rendered in preparation for upcoming features. Right now it’s hard to get anything big done because I need to finish the map editing system, and that takes a lot of work. But hopefully, I’ll get there in time. Thanks for all your support guys 🙂

I’ll contribute. What’re you rules on pull requests?

I’ll contribute. What’re you rules on pull requests?

As of right now I haven’t established any, but following my syntax conventions are a given.

I’ve got a bit of progress for the past few days. I’ve been working on a map editor for the engine. The idea is for all the game-data editors to be external pieces of software. Reason being is to segregate the game-developing code from the game-functionality code. It also leaves more room for the editors themselves to be more fluid to use. For example, auto-tiling that doesn’t lag up the client, or the ability to transverse the map without player-movement as a restriction.

I really want to get things moving a bit in an effort to encourage my motivation to develop, so I’ve been being a bit more sloppy with the code in the editor. Optimization in the engine itself is my top priority, and editors are external. I’ll re-work the editors in due time, but functionality is all I want for them at the moment. Please keep in mind that there is still no possibility for game development with this engine, and there won’t be for a while; the map editor isn’t finished yet.

I’ve pushed out a few updates in the past few days, all of which were regarding the map editor. I’ve got a few photos to show you my progress. 🙂

I wrote my own map editor a while ago. Was definitely a huge learning experience (by the end of it I had culling pretty much down in theory which translates to pretty much any dimension; the math to get super involved with stuff like quad/binary trees and sorting algorithms is still over my head though).

After I knew how to render tens of thousands of tiles in the viewport plus a thousand or so particles above 60 fps I knew that going any further with it was a waste when there was Tiled out there and other editors out there like it.

So I say to you: great work so far and go at it for as long as you’re taking away something from it. Later on down the road you may find more efficient ways of utilizing your time, thus increasing overall productivity and product quality. 🙂

Edit: I had a thought when I read that you were going with external editors (I hope you make use of just one environment in which to edit all game content).  Using Unity as my muse my thought was that by using external editors you could actually create content for a game inside of your environment (editor) then “build” and deploy it to a remote host.  From there, both the game server and clients are updated. 😮

Basically, you’d just be packaging raw game data.  You could add options to install an entirely new client (and new libraries with it) too by simply using a file containing a set of instructions (boolean values).  Super neat and something I might do for a project I have coming up myself.

  • snip -

Well hey thank you Bud! In regards to your comments about the external editors, I was planning on creating various external editors for the game data. But I now realize that going for one environment would be simpler, and make more sense than having multiple. I do want the editor to support having multiple developers rather than just one, so I do need to add support to making individual binary files for data, and adding pre-existing binary files for data. But that’s more of a mental note for me than something for you. In regards to the deploying of the game cache, it was an idea I was rather fond of. I might just go for a simpler method and just send the cache to the server, and commence a server-restart. Upon re-connecting to the server, the client executable and game cache would be updated. If the client is going to be updated, the player would have to close the outdated client anyways. Anyways, thank you for your input! ^_^

I’ve got a video today explaining what I’ve done with the map editor. Enjoy 😄

https://www.youtube.com/watch?v=B9LMoK08Sh0&feature=youtu.be

Well, it looks interesting, and I might like it more if I was used to it, but as of now, it seems like a lot of work to edit maps, but easy to make more and such, good work 🙂

Well, it looks interesting, and I might like it more if I was used to it, but as of now, it seems like a lot of work to edit maps, but easy to make more and such, good work 🙂

It took 12 minutes to explain, but it takes pretty much no time at all once you understand it. The surface directory and export directories are saved in settings, so you don’t have to do it each time. The main reason why there’s more setup required is because it’s more dynamic and flexible than EO’s system. Take a look at the way layers are handled. But yeah, right now, EO is easier to use. But once I make the proper Game Cache Editor, it’ll hopefully shine past EO. 😄

Looks interesting. 🙂 I will finish watching the video later.

It took 12 minutes to explain, but it takes pretty much no time at all once you understand it. The surface directory and export directories are saved in settings, so you don’t have to do it each time. The main reason why there’s more setup required is because it’s more dynamic and flexible than EO’s system. Take a look at the way layers are handled. But yeah, right now, EO is easier to use. But once I make the proper Game Cache Editor, it’ll hopefully shine past EO. 😄

As I said, to me being used to EO and it’s user friendliness, it seems to need a lot of work, but it does have a lot of flexibility, I’m wanting to see where the engine goes, it’s looking nice

Dat voice…

Looking good bae, keep it up 😄

I’m liking the look of this project and you seem to be adding in features that I for the longest of time have wanted to add into an engine but been to lazy to do so. I do hope you have all the external editors be apart of an IDE if you will for game development like Bud suggested. I do have a couple of suggestions for the map editor:

  • Can you rename layers? I’d like to be able to provide more descriptive names to my layers.
  • Maybe you should create a New Project wizard like if you were to create a new project in VS, I’m sure a wizard would appear to guide you through the initial setup process and I think something similar could be done for the map editor so instead of clicking on menus (Cache > Import Graphics etc) you have a little wizard that guides you through that which would simplify the current process of setting things up.

Other than that, keep it up!

I see a lot of static modifiers.

2spooky4me

Log in to reply