thomf00
|
|
« on: January 05, 2017, 07:47:55 PM » |
|
Ahoy! Starting a quick play battle arena game! I've never created a real time multiplayer game from scratch, so this will be a fun experiment. I've drawn a colored pencil Link below as slightly more appealing placeholder art, added some boiler plate Entity Component System stuff, and hooked up some keyboard interaction. I may try to partner with an artist if I stick with it, but seeing how I've done nearly zero art for the past 10 years or so it might be time to workout that part of my brain. It's written in Haxe with a library I'm trying called heaps.
|
|
« Last Edit: February 09, 2017, 05:29:41 PM by thomf00 »
|
Logged
|
|
|
|
Excy
|
|
« Reply #1 on: January 06, 2017, 02:53:03 AM » |
|
So you created heaps then? Not much to say at the moment but will follow
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #2 on: January 06, 2017, 10:20:26 AM » |
|
Hey, no, Nicholas Cannase created heaps, he also created the programming language I'm using called Haxe. Yea not much to say right now, just want to start dev logging to get the ball rolling!
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #3 on: January 10, 2017, 05:44:28 PM » |
|
Wow! I wanted to do a post earlier but I needed a lot more code than expected. I wrote a haxe to neko web socket server implementation. It's well encapsulated so using it in other projects isn't hard if people want it. Just ask! The gist of websockets... - Client opens a web socket and sends a header
- Server hand shakes based on the header
- Client & Server can now send data back and forth using a web socket specific byte header
Each client gets it's own thread & socket until the client disconnects. After the web socket implementation I wrote some basic game level commands to get the following up and running. NEW_PLAYER - "I'm ready to play! Oh and I want to be the color red." UPDATE - "I moved, here's my new position." GET_POSITIONS "Where is every other player and what is their color?" Right now I'm spewing updates at the server based on my frame rate, I think that might have to change in the future, but running a-ok in primitive land. Anyways... Check it out! A real time online multiplier game engine entirely in haxe!
|
|
|
Logged
|
|
|
|
Mixer
Level 1
I've never really known what to put here.
|
|
« Reply #4 on: January 10, 2017, 05:53:39 PM » |
|
Hello! Came from twitter, awesome to see another haxe project. Heaps looks really nice, created by haxe founder. I've meant to check out heaps for a while, currently using kha. I've struggled with networking with mphx, so I can appreciate your networking code lol.
You should open the server up so we can play the game against you as you make it :D
|
|
|
Logged
|
|
|
|
snackycactus
|
|
« Reply #5 on: January 10, 2017, 05:53:43 PM » |
|
Nice work!!
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #6 on: January 11, 2017, 05:50:38 PM » |
|
As a first step toward an end-to-end integration testing I've pulled out haxe websocket server and open sourced it! The API will likely change a bit as things progress, but the crux of what I need is in there. The thread management will remain separate, at least for now. If you follow the README on github you should be able to build the example in minutes, let me know how it goes! https://github.com/thomasuster/haxe-websocket-server@Mixer Yes! I will totally open up the server to everyone once there's some sort of game to be played.
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #7 on: January 18, 2017, 06:12:35 PM » |
|
Full integration testing failed!!! The concept would be sweet but it just doesn't seem practical with the limitations of working in the browser. So I've abandoned that! Spent a couple of hours adding some basic movement with TEMPORARY Zelda graphics. Looking for an artist!!! Animations looks pretty smooth for my client (right character), but ice-skatey for the other player. The animation logic is running per frame and the server ticks come every few frames. So next step is probably to have some custom logic for other players, perhaps predicting what their position will be on frames when I don't have updated info from the server. PS If your curious about my attempt at a JS -> Backend integration platform check out the source! https://github.com/thomasuster/integrate
|
|
« Last Edit: January 18, 2017, 06:19:09 PM by thomf00 »
|
Logged
|
|
|
|
thomf00
|
|
« Reply #8 on: January 20, 2017, 12:39:25 PM » |
|
Added smooth movement and arrows! What I'm actually making... (SPOILER ALERT) The game isn't really called Battle Dash, real name TBD. It's going to be an online multiplayer arrow combat game. I'll be using a lot of mechanics from tower fall, drawing arrows with directional feedback, finite arrows, picking up arrows, arrows hitting walls bounce, things passing through the side of the game reappear on the opposite side. I'll also be heavily trying to recreate the feeling I had when I first played Battle Grounds, a revolutionary war mod for Half-Life. The feeling is anticipation! In Battle Grounds your rifle was so inaccurate and so slow to reload that you usually would wait until the PERFECT moment to let it off. I plan have the same feeling by giving each player a shield that protects them from one direction, that way more often then not you wont be firing arrows, you'll be staring down your enemy with a shield in hand! What I'm going for is less like Realm of the Mad God and more like Nidhogg.
|
|
|
Logged
|
|
|
|
AKWolf
|
|
« Reply #9 on: January 20, 2017, 03:51:28 PM » |
|
The concept sounds great! Following.
|
|
|
Logged
|
|
|
|
tanis
|
|
« Reply #10 on: January 21, 2017, 01:34:27 AM » |
|
Thomas, you probably don't want to use web sockets or anything TCP for realtime network stuff. Been there, done that Use UDP. There's a nice wrapper for bnet from Sven, I think it's called linc_bnet. You should give that a try
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #11 on: January 22, 2017, 09:51:20 AM » |
|
@tanis I would consider UDP but the front-end is in the browser. So my two choices are web sockets (WS) or WebRTC. WebRTC is more for p2p networking, and WS is more natural for having a server, so I went with WS. I'll check out the lib though for kicks, is this it? https://github.com/snowkit/linc_enet@AKWolf Thanks!
|
|
|
Logged
|
|
|
|
tanis
|
|
« Reply #12 on: January 22, 2017, 12:52:43 PM » |
|
Yeah, enet, that's it. I told you the wrong name Browser front-end, argh! then you're a bit limited on options indeed
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #13 on: February 01, 2017, 09:57:34 AM » |
|
Hey there! Did some stuff! * Players can kill each other! * Directional shield (hold space bar + mouse position) * Show other players bow / shield * Basic map * Entering your name * Kill streak Leaderboard * Re-spawning (press space bar after dying) Next steps... 1) Game mechanic design! I'll be playing around with things like shield max hits, max arrows, item pickups, etc, teams or FFA, kill streak bonuses. 2) Get ping down, it's currently around 100 MS (Server US West) 3) Get in contact with someone who's done a game similar to this before. Know anyone? 4) Find a pixel artist!
|
|
« Last Edit: February 02, 2017, 01:32:12 PM by thomf00 »
|
Logged
|
|
|
|
Pixel Noise
|
|
« Reply #14 on: February 01, 2017, 06:06:39 PM » |
|
Very cool! I wasn't sure where this was going from the first post, but really nice progress. Love these kinds of games - will follow
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #15 on: February 13, 2017, 06:35:37 PM » |
|
Ahoy! * Took out the shield mechanic and replaced it with a dash mechanic, much more fun. * Added shoot in 360 degrees not just 8 (using just 8 felt restrictive) * Added arrows on the ground that randomly spawn * Added arrow power! (The longer you hold the faster it goes up to 3X)
|
|
« Last Edit: February 13, 2017, 06:45:41 PM by thomf00 »
|
Logged
|
|
|
|
|
snackycactus
|
|
« Reply #17 on: February 13, 2017, 06:42:01 PM » |
|
Yay! 360 degree shots!!! Are you going to do variable shooting speeds? It kinda looks like the first arrow you shoot goes faster, but maybe it's just an optical illusion. Could be like how long you hold the bow back or a little meter with a sweet spot like gear's of war's active reload. REGARDLESS, this looks like its comin along! Can't wait to see the next post :D
|
|
|
Logged
|
|
|
|
thomf00
|
|
« Reply #18 on: February 13, 2017, 06:46:58 PM » |
|
@snackycactus Oops! It actually does just that, I just forgot to say so (edited above).
|
|
|
Logged
|
|
|
|
snackycactus
|
|
« Reply #19 on: February 13, 2017, 06:47:46 PM » |
|
SWEET
|
|
|
Logged
|
|
|
|
|