WEEK16 – AvatarChattingGame

This week i thought about to do something little (as i always do). But really fast it was clear: this will be a little bit bigger task.

I thought about making a AvatarChattingGame (like in WhoRU but this time with client and server).

To keep it really simple here was my plan

– Making a game where 2 network players can simple interact (just they can run around and the other can see it)
– Use premade assets (specialize for the 3D Character)
– Chatting is a optional feature

First i wanted to skip this idea and try again with something stupid – but then i thought “hell you try this since years – do it now!”

And i did – and it was an interesting journey.

What went good:

Much more as i expected: i wrote a small Server in C#. It handles some types of packets and dispatch them to the clients.
What this time really went good: i used a premade Avatar from the Unity Asset Store which had a fully functional animator. So instead of design things i could concentrate of prototype this idea.

Second as i first expected i didn’t overscoped this. And i made this in the time. Also it was my first multiplayergame.

What went bad:

Not much this time – but i had some weired bugs. Also i used a Socket Server and Client instead of premade Libraries. Next time is should try them. There are some Libraries like Mirror or UNet (which is deprecated i think). But i wanted to do it “raw” this time.

The world is simple – but maybe i got to change this too until today in the evening.

What i learned:
A lot of Stuff about SocketClient Communication. Before that i wrote only Servers. This is the first time i got a client working. I learned that i am on the write way to write something like this.
Also i like what i did and i think about to extend this to a fully working “WhoRU” Replacement.

I provided the Source Code this time – so you can download it here:

You can Play the Game here: https://www.nerdvision.net/GAW/Week16/AvatingWindows.rar .

Just start the Exe in the Server directory and the client as often as you want.
Important: the Server has a little “disposed” Object issue which i was unable to solve. So the server could crash if clients leaving maybe.

Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *