Page 20 of 49

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sat May 30, 2015 5:19 am
by Neocon
I used OYS for CFN. For the first 45 minutes, with three of us online, everything went fine. Then it started using up memory. That caused some major lag. I got clearance to land, and about the time I touched down Speky asked if I needed to change runways. Long story short, What they were seeing of me was delayed by about 3 minutes, so they didn't see me land until 3 minutes after I was on the ground! It was great fun until OYS finally kicked us all out.

There's probably a memory leak somewhere.

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sat May 30, 2015 2:08 pm
by Flake
I was working with VNAF on the project earlier this month actually and noticed that Asynchronous Sending is worse then Synchronous sending - the more people you have online, the worse Asynch gets.

So I reverted the code to Synchronous sending and it works better. There's much to be done though.

Thanks for your feedback! I hope you guys all had fun with the Civ night. Thanks for supporting the project!

I may restructure the threading mechanism to have "time to live" attached to the threads lists... Is the thread goes over say, 30 seconds, the thread will be killed immediately (unless it's meant to do that.)

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Wed Jun 24, 2015 1:54 pm
by Flake
Exciting history was made today - I've mapped the "ordinance spawned" packet - the one that tells YS a missile, bomb, agm, or even flare is created.

I can now launch bombs from the gun cannon for example (in fact I've already done so, it was HILARIOUS!).

I also want to make flare "fireworks" - spawns one flare, once it reaches it's peak hight, it creates a star of other flares from the "fizzle out" point.

I surprisingly have a decent amount of control of the ordinance! Neat!

And for my next trick, I will aim to fix the networking stability fundamentals that is causing OYS to force clients to DC. I'll need peoples help on this one though! so I'll first start proper logging and analysis of all DC's made and WHY they were made, then I'll run a public server to check all this :)

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Wed Jun 24, 2015 5:38 pm
by Neocon
The two biggest problems I've seen are the disconnection problems where it will kick most or all of the clients, and the memory problem. I think the memory usage might be related to old and new versions of YSF being connected at the same time, but I really have no idea. I left OYS running overnight with Guam to SoCal and the memory stayed low and nobody logged in. Whatever is using the memory has to involve clients being connected, I guess.

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Wed Jun 24, 2015 10:47 pm
by Dragon029
OfficerFlake wrote:Exciting history was made today - I've mapped the "ordinance spawned" packet - the one that tells YS a missile, bomb, agm, or even flare is created.

I can now launch bombs from the gun cannon for example (in fact I've already done so, it was HILARIOUS!).
We need vidyas ASAP

Is it possible for you to modify the airspeed or other properties of ordinance?

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Thu Jun 25, 2015 12:15 am
by Flake
Yep. I can change spawn speed, max velocity. Position and orientation, ordinance type, durationse sender Id...

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Thu Jun 25, 2015 9:19 am
by Dragon029
I know you're working on a fair bit (and this would probably come under your existing WIP), but any chance of having a trainer / plugin that reads extra / custom weapon data from an aircraft's .dat (stored within some commented-out section)? :mrgreen:

But yeah, this obviously opens up a ton of opportunity for things like realistic missiles, guided bombs (if you can get rid of the smoke effect of the AGM), laser weapons, etc.

Re: [PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Fri Jun 26, 2015 6:38 am
by Flake
Dragon029 wrote:I know you're working on a fair bit (and this would probably come under your existing WIP), but any chance of having a trainer / plugin that reads extra / custom weapon data from an aircraft's .dat (stored within some commented-out section)? :mrgreen:
This is part of the plan! Once I stablise OpenYS and complete the mapping of the YS Protocal, I'll extend server functions! - so aircraft can be modded to have special permissions, for example. Full details when I finally get around to that.

By the way, I have mapped like, 80% of the YSFlight online protocol now. Soon, I'll do the damage packets, and ground object data packet (like flight data packet, but for a ground object). Then the other stuff is really just not even needed. (score reporting, for example)

OYS has been without ground combat for too long (which is what makes YSF fun when alone/with a team)

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 19, 2015 2:10 pm
by Flake
Hi all - an update on this.

Their are two major issues with OYS at current stopping further advancement.

1 - The socket structure causing the program to lag behind and use massive ammounts of memory.
2 - The threading structure causing the program to use too many threads and lag to a halt.

These are solvable without destorying the project and restarting it thanks to my recent upgrades to the source code - I only have to re-write the sending/receiving and processing allocators.

However, the flaws are a design flaw. I DO need to use Async sending but not in the method I tried - I can't create my own managed threads and send that way, I need the operating system to do it for me by using callbacks - something I've never used before, so I will have to learn that.

The thread allocation should be tied with that solution.

I'll be doing some research on the asynch sockets with callbacks to make this work - I am told by stack over flow that these socket structures work fine with MMO's with little lag - up to 5000 players! (YSF will never have that many!)

Leave it with me! I haven't forgotton about OYS, but yes, now you know why nothing has happened for a while.

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 19, 2015 2:13 pm
by Neocon
OfficerFlake wrote:[post]88579[/post] I haven't forgotton about OYS, but yes, now you know why nothing has happened for a while.
Thanks for the update!

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Tue Jul 21, 2015 11:37 am
by Flake
Finally implemented the advanced sun-fading I wanted to do, as well as a standardised timing system for the server.

Merging threads into the core thread now to take the load off system resources - less threads, less locks, less lag!

Please enjoy this delicious beverage!

[youtube]https://www.youtube.com/watch?v=sZEtCxBv-Ao[/youtube]

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Wed Jul 22, 2015 4:40 pm
by Barr
Aww yeah

Now the time it takes to change from sunset,night, sunrise, day etc adjustable or is it fixed for now?

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Wed Jul 22, 2015 10:59 pm
by Flake
The day length can be adjusted - the amount of time it takes for sunrise etc. to happen during the day is not - Sunrise/sunset takes 2 in game hours.

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Thu Jul 23, 2015 2:34 pm
by Flake
Okay I've re-done how the sockets work - now there is only one thread for all the incoming data to be processed on - this should stop lockups.

Tested okay on local host but I'm wanting people to check over the network - I have seen socket errors in the console so perhaps I'll need to work that out more gracefully later!

Re: [PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 6:38 am
by Flake
Now Updated to Version 20150726(1630)

Changes:
+MASSIVE Update to many components of OYS
+Server time uses a tick based system - the environment can now be any time of a 24hr day.
+Environment changes color based on time of day. (2015 YSF+)
+Socket structure massively revamped, hopefully less lag. appears very stable so far. maybe a few more issues to solve.
+Bombs from gun novelty.
-Removed Nukes

Notes:
~Very major updates to code - minor bugs but server stability should be increased. Threads reduced dramatically.
~Pretty please test this version - let me know how your server experience goes!

Download: https://www.mediafire.com/?22tyn9d5f7p8tt5



[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 9:35 am
by Kujo
OfficerFlake wrote: MASSIVE Update to many components of OYS

Socket structure massively revamped, hopefully less lag. appears very stable so far.

minor bugs but server stability should be increased. Threads reduced dramatically.
One big yes to you, my friend. :D

Image

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 11:56 am
by C P
OfficerFlake wrote:[post]88871[/post] let me know how your server experience goes!
Won't start server for me here. Says need to enable LoadFromRemoteSourcesSwitch in .NET?
Old version starts fine 201550227(1339).

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 1:59 pm
by Neocon
I have it running on my end. It caused a buffer overrun the first time I started it up, but I think that was a PC problem. OYS seems to be running fine on a 48 minute day/night cycle. I was able to connect from the 2013 version of YSF, without the color changes, of course. The 2015 version of YSF has the color changes, and they look amazing! Nice work. I will monitor memory use through the day.

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 4:15 pm
by Bombcat
Flake, I received the following error when trying to run the latest update of OYS on a server running Windows Server 2012 R2. I was using the latest official 2015 release of YSFlight.

Image

[PROGRAM] OpenYS - Open Source YSFlight Server!

Posted: Sun Jul 26, 2015 11:54 pm
by Flake
Hi Bombat! Looks like it's struggling to find the dll libraries. I'll try simulating your setup to see what I find.

The resource switch thing... U wot m8? Try reinstalling .Net

Thanks for the feedback pat! I hope it serves you well!