scidave's Forum Posts

  • I'm scidave and I approve this tut. :-)   Sorry, for the terrible long delay. I was without internet access for awhile and finally back into looking at Construct stuff.

    I think it is awesome you are working on porting it to C2!

  • Anyways, will you keep working at the project after that half year?

    Yes, probably closer to the end of the year though with my new job. I don't think I'll ever plan to add built-in lag compensation though. Just features to make it easier to track players, know which player is which, and have the server assign players vs the way it is now. Then just features to compress traffic to save on bandwidth, etc.

  • Hi Delgado and welcome! The plugin shouldn't rely on Visual Basic..so your error sounds odd. I would post your entire error. Also make sure you copy the plugins correctly into the plugins folder. The network.csx into the Plugins directory and the network.csx into the Runtimes directory.

    I believe general consensus is that the plugin is stable for LAN games, but possibly buggy for Internet. I'm on a break for coding for 1/2 year or so though we will see if any body picks it up. :-)

  • Yes, unfortunately I'm not going to be able to do any work/help on this for about 6 months. Have intermittent computer/internet access.

    You might be able to look at the Pixel People online source that was posted for help. Besides that, C2 might be a better approach because more people are active on that project in relation to Networking. Although the benefit of CC is that the Server and Client can be written entirely in Construct.

    You might also explore Podsixnet, but I found the performance to be lacking for action games compared to my beta plugin (because it used TCP vs UDP). Cheers!!

  • What Wolod describes is probably the best way to do it. I showed a similar way, using arrays, in the Mikey's adventure tutorial part 4.

  • Surely somebody on the boards has time to make a trial EXE exporter (I mean wrapper) using Awesomium. Probably would take a week's work for somebody with a little bit of C# or C++ experience. Then we can see how buggy or realistic a fully supported wrapper might be.

    I think the devs time is best suited now for making C2 as good as it can be instead taking on another side project. Problem is if they support an exporter nearterm, they now have another codebase to support with all the accomplanying bugs, etc. With 2-3 devs maybe, but 1...unlikely.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You could do this either in Python:

    wiki.python.org/moin/WebBrowserProgramming

    Or probably the preferred solution is to make a Plugin using Awesomium:

    awesomium.com/docs/1_6_3/cpp_api

  • You are welcome. Hopefully somebody with come C++ skills and time can add to it.

    Do you mean the source code? If you no nothing about C++ then it might be difficult, if not then it isn't too hard to understand the source if you visit the ENET website. If you mean the plugin, then don't know what to say as it is about the most basic network plugin possible. You just host and receive or connect and send.

  • Folks,

    Good and bad news. Good news is I'll be starting a new job and moving in a month so it will be exciting. Bad news is I wont have reliable internet for awhile and need to focus on new work.

    So in light of that I'm going to open source this plugin. I've only had a few hours to spend on it over the last couple months and feel that surely somebody can help move it along faster than me...

    If for some reason, nobody does I'll pick this up again end of next summer when the initial job contract is over.

    Network plugin source (Visual Studio 2010 Project file/ and source):

    Network Plugin Source

  • Thanks Jayjay...I know I just need to implement the update to see if that fixes it, but still kinda baffled that it isn't even working on localhost on my new computer.

    Surely somebody else who downloaded it has tried it out??????

  • >> both clients kept receiving the 'hassentGameOn' message.

    I discovered something similar myself. Couldn't figure out why the GameOn message kept being sent even after the group was disable. The fact the group is disabled means for sure the computer processed the event which means it should stop sending!!

    I then tested with a reliable packet to send the GameOn message. SOmething like "GameOn:1". Because reliable packets expect a ":" and something else. This test worked just fine and the flood of game on packets stopped. So only using reliable packets instead of messages is one workaround for that part.

    That still didn't help with the buggy position/other updates...and to be honest this whole thing baffles me as it isn't even working right on one system or my LAN computers. I have no clue how it could have worked perfectly on my old test laptop and not now! More to follow.....

    EDIT: To help me figure this out. For all those who have used the network plugin please post saying if it works perfectly, works off and on, doesn't work at all, and your system specs/Construct version.

    For me, I had an HP Envy 14 laptop (Win7 64bit using CC1.1) which I developed it on(since sold) that it worked perfectly on. Have since tested it on a Win7 Pro and Win7 Home Premium both 64 bit (CC1.1 and 1.2) and it is very buggy...

  • I didn't realize that about the local HTTP server requirement. That complicates things a bit. Unfortunately, the problem isn't quite as simple as loading an index.html file. Need to build in an exe compressor (like UPX), the local HTTP server, and ideally allow for export to different OS's. Other problem with a wrapper is you now rely on another Chromium code base...if the Awesomium guys fall behind and don't fix bugs/update source tree, now the wrapper becomes unstable and everybody complains to the devs. So I can understand the hesitance to official support a wrapper at this point.

    After looking at the SDK, I think there would have to be three separate wrappers built (independent of the IDE). Need to make one each for Linux, Windows, and Mac. So that entails three different types of compressors/web servers. I don't have a Mac so if I try this out it would have to be just Linux and Windows.

    Still, I don't think there should be much of a rush asking for wrapper as we are all kinda in test mode anyway...MAYBE this weekend I'll throw together a Windows wrapper and see how it looks. :-)

  • hmmm. those suggestions probably wont help, I think I introduced a new bug into the latest version that makes things unstable. Looking at it now. :-(

    If you want to mess with the older version of the plugin just to see if it is bug free.. here it is:

    box.net/shared/jaxkj9skkmkdc12p8nim

    Edit: Just tested the first version of the plugin and it isn't working. Very odd I never encountered this bug before. Not sure how it is computer dependent! argggh..

  • >> Players ID's synched up? You mean for the server to identify who is

    using which character?

    Yes, it is admittedly not the best way so important that step be done right first. Once that is good then you can move to telling everybody that the game is starting ("GameOn" Message). IMPORTANT: While folks are getting/processing the GameOn message you don't want position packets to flood the network.

    Finally, once everything is stabilized (dont see gameOn packets flooding) THEN start sending position packets. One way to do this is to delay start by a several seconds once. Also, the example is poor in that it sends the position packets every tick..not good for over the internet. Change that to every couple ticks.

    If I get a chance to test this I'll send an updated example .cap...but hope that makes sense.

  • Sorry it isn't working over Hamachi. Problem is definitely something to do with lag..as it works fine for me over internet as well (but I have fast connection).

    On the ServerGame vs ClientGame. The server should never act as the client (or in the example display client locations)...it is simply a dumb terminal passing packets back and forth. You need two clients and the server running.

    I have had requests to let the server also act as a client, but that is low on priority list compared to fixing this dreaded bug. :-)

    One potential fix/workaround is to add more checking/time for players to get their ID's all synched up. I think perhaps switching layouts combined with a laggy connection might be putting the game into a bad state. If you look for a workaround it would be to make sure that everybody gets their IDs and gets the GameOn message without sending ANY additional packets around to minimize lag problems. Also, in my example I was sending positions as floats (which is very bad).. you should correct that by casting any position as an int before being sent.