Nifflas' Support Forum

Being Creative => Collaborations => Topic started by: Joozey on August 31, 2009, 00:30:00

Title: Knytt Alternate Stories
Post by: Joozey on August 31, 2009, 00:30:00
Alright, I just couldn't bear it any longer. This project is getting covered in dust while my notebook is under repair. For two months I haven't worked on it, but I show you this now nevertheless. I just have to give in. I'm sorry for not being strong enough. :(

Knytt Alternate Stories, an early W.I.P. browser based knytt engine running on my crappy bedroom server.
To use, install the vitalize plugin. You can get it by following the link that'll pop up. If firefox addon wont work, use offline installation.

http://212.182.179.183:36080/KnyttAS/


The idea:
MMO Knytt through browser. No custom levels, let alone custom use, for a long time to come, only my tiny test level.
If you don't see anything moving, that's because movement is only done at server side. Ha-hah. And I'm not sitting there all day steering Juni around. If you really really wanna see movement, catch me on MSN, or niff's IRC channel. Of course, it's supposed to have client side movement, but my notebook decided to crack its motherboard and cause havoc.


The mechanics:
-There's an MMF2 server application running (a modified knytt source), and a client-side vitalize MMF2 application.
-The server sends an initial background snapshot of the tiles and stuff to the client, without Juni, objects, or enemies. That took easily care of the tile creation.
-Then the server sends animation and position data each 1/x second to the client. The client creates a Juni character and animates and places it according to the received data.
-Well, that's really all.


While I can't do any development without my developer notebook, I'm still looking for help.

1) There are loads of MMF2 addons that can not be used by vitalize, the movement object being one of them. So I'll need to somehow make Juni move in a nice way, without stuttering (as happening now due to data being send every fourth of a second or so). It's a major problem that needs some special thought. Anyone?

2) There are a lot of gameplay problems occuring with multiplayer knytt. Like in a puzzle scenario, how would dying work when it easily screws up the multiplayer puzzle? Someone needs to map these out! :crazy:

3) If you wanna jump in on this project, I have set up a subversioning system (SVN), and you're free to dev away with it. Just drop me a PM. You'll be having fun with level management, object creation, and mapping out all the other stuff I hadn't thought of.

That's all for now, I'll let you know when they fixed the notebook and of course totaly erased my entire hard disk.

Yours truly,
Joozey
Title: Re: Knytt Alternate Stories
Post by: Purple Pineapple on August 31, 2009, 01:52:56
To use, install the vitalize plugin. You can get it by following the link that'll pop up. If firefox addon wont work, use offline installation.
Firefox is having incompatibility issues. Then again, it's been bugging up recently, so I'm not sure when I'll be able to try this.

1) There are loads of MMF2 addons that can not be used by vitalize, the movement object being one of them. So I'll need to somehow make Juni move in a nice way, without stuttering (as happening now due to data being send every fourth of a second or so). It's a major problem that needs some special thought. Anyone?
Well, either you increase bandwidth, or it's going to stutter.

2) There are a lot of gameplay problems occuring with multiplayer knytt. Like in a puzzle scenario, how would dying work when it easily screws up the multiplayer puzzle? Someone needs to map these out! :crazy:
Just need to design the puzzles around such problems. Like the fish in KS.
Title: Re: Knytt Alternate Stories
Post by: Joozey on August 31, 2009, 02:06:18
Quote
Firefox is having incompatibility issues. Then again, it's been bugging up recently, so I'm not sure when I'll be able to try this.
For me too, just use the offline installation. Worked like a charm for me.

Quote
Well, either you increase bandwidth, or it's going to stutter.
I'm sure there're plenty of other solutions ;). Moving Juni from point to point may be one. But I'd need the proper movement formula. Perhaps rrc_soft could help me here with his DS version...

Quote
Just need to design the puzzles around such problems. Like the fish in KS.
Yeah, if anything, just shift the problem to the end user :^^:. But if I can prevent it through code, I'd happily do it.
Title: Re: Knytt Alternate Stories
Post by: Purple Pineapple on August 31, 2009, 02:30:40
Quote
Well, either you increase bandwidth, or it's going to stutter.
I'm sure there're plenty of other solutions ;). Moving Juni from point to point may be one. But I'd need the proper movement formula. Perhaps rrc_soft could help me here with his DS version...
So.. What's the problem here? Is it lag or jerkiness..? What are you trying to accomplish?
Title: Re: Knytt Alternate Stories
Post by: Salmoneous on August 31, 2009, 07:53:44
With some work and than some more work on this the results could be awesome.
I might be intrested in 3) there, but not now, I have to go to school.
Title: Re: Knytt Alternate Stories
Post by: Joozey on August 31, 2009, 13:11:57
Quote
So.. What's the problem here? Is it lag or jerkiness..? What are you trying to accomplish?
The problem is jerkiness. I can't send data any faster than a set amount of time, currently this time is around 1/4th of a second. So the position of all the clients are updated every 1/4th second from the server, and the client should interpolate all the Juni's that have moved between the previous and the next position. The way of interpolating is the problem. How to move Juni correctly, taking potential lags and such in mind as well.
Title: Re: Knytt Alternate Stories
Post by: LPChip on August 31, 2009, 18:03:04
I'm moving this to dev. showcase, as this isn't a project that is made by more than one niff-forum member where the development is openly communicated through the forum.
Title: Re: Knytt Alternate Stories
Post by: Joozey on August 31, 2009, 21:35:41
Eh?
Description:
"When you want to start a project with other forum members, you can post about such collaborations here. "

I'm trying to find members and I openly discussed how it worked and what has yet to be done :P.
Anyhow, I'm fine with the moving, but I really thought I had picked the proper forum X) .
Title: Re: Knytt Alternate Stories
Post by: LPChip on August 31, 2009, 23:50:25
Oh my bad.

It looked like you worked on it solelly, and stopped working on it because your laptop died on you, and you just were showcasing what you had in order to inspire others.

I'll move it back then.
Title: Re: Knytt Alternate Stories
Post by: Purple Pineapple on September 01, 2009, 01:20:11
Quote
So.. What's the problem here? Is it lag or jerkiness..? What are you trying to accomplish?
The problem is jerkiness. I can't send data any faster than a set amount of time, currently this time is around 1/4th of a second. So the position of all the clients are updated every 1/4th second from the server, and the client should interpolate all the Juni's that have moved between the previous and the next position. The way of interpolating is the problem. How to move Juni correctly, taking potential lags and such in mind as well.
So.. the problem is it runs at ~1/4 second per frame..
Title: Re: Knytt Alternate Stories
Post by: Joozey on September 01, 2009, 01:35:54
Quote
It looked like you worked on it solelly, and stopped working on it because your laptop died on you, and you just were showcasing what you had in order to inspire others.
Well actually, it's both. But the 'searching members' part gives more value to it, so let's stick to that  :^^: .

Quote
So.. the problem is it runs at ~1/4 second per frame..
Yes. If you think you're able to solve it in MMF2, do PM C)p !

Also, the server will be down in the nights (somewhere between 00:00 and 10:00 GMT). You'll see a "can't connect" text appear during that time. Until I am in posession of a virtual server, which may take quite a while yet, it'll remain this way.
Title: Re: Knytt Alternate Stories
Post by: AClockworkLemon on September 01, 2009, 11:19:25
Hmm... I hope you get that virtual server soon, coz over here in Aus... Argh the time difference!

Sounds great - cant wait 'till I can play it!

A way around the 'jerkiness' (this coming from a non-programmer and complete noob) might be to run all the movement stuff for the client avatar on the their computer, making their avatar have (Im guessing) fairly lag-less movement. Then have the server sweep all the client computers every (whatever-ths) of a second and send their new co-ordinates to all the rest of the clients. Finally, Incorperate a logic circuit thingy into the client version, that reads the change from A (x1,y1) to  B (x2,y2) and makes their avatar move smoothly between the two points.....

As I said, the above is quite posibly stupid and rather impossible
Title: Re: Knytt Alternate Stories
Post by: Joozey on September 01, 2009, 12:28:27
Clockwork, your solution is really spot on. I *think* this is how it should be done in multiplayer games. However the problem is in that I can not use the normal movement object used in the original knytt source, as the vitalize plugin (the thing that makes it running in browser) only allows a small selection of functionality to run on the client. So I need someone to recreate the movement with more basic components.
Title: Re: Knytt Alternate Stories
Post by: Purple Pineapple on September 02, 2009, 01:32:58
Here's another possible solution like Bored's:
Have the game send actions of the players every 1/4 second. (e.g. from .00 to .25 player held left. At .09, player pressed and held jump until .21) This will generate graphics of players on other servers. For safety, you could also send the player's position at the end of 1/4 a second. As there is no need for your player to do this, you need only re-render positions of others. The other people won't be jerky, now. But they will lag 1/4 second.

EDIT:
Clockwork, your solution is really spot on. I *think* this is how it should be done in multiplayer games. However the problem is in that I can not use the normal movement object used in the original knytt source, as the vitalize plugin (the thing that makes it running in browser) only allows a small selection of functionality to run on the client. So I need someone to recreate the movement with more basic components.
So it isn't a problem anymore?
Title: Re: Knytt Alternate Stories
Post by: AClockworkLemon on September 02, 2009, 09:01:33
Clockwork, your solution is really spot on. I *think* this is how it should be done in multiplayer games. However the problem is in that I can not use the normal movement object used in the original knytt source, as the vitalize plugin (the thing that makes it running in browser) only allows a small selection of functionality to run on the client. So I need someone to recreate the movement with more basic components.

wow... really?
Possibly It would be best to just find a differnt plugin. something like shockwave. Java would work pretty well as well (I think) and pretty much every computer has it, so that would rule out incompatibility issues
Title: Re: Knytt Alternate Stories
Post by: Razzorman on September 02, 2009, 17:41:56
wow... really?
Possibly It would be best to just find a differnt plugin. something like shockwave. Java would work pretty well as well (I think) and pretty much every computer has it, so that would rule out incompatibility issues
(from my understanding,) That would mean that you can't code the game in mmf2, which is what I guess joozey is using.
On the other hand, I think i remember niff saying something about java exporting being possible now...