Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

100 Neutral

About P@u1

  • Rank
  1. P@u1

    A* - Which Cell Size?

    Very interesting article! This probably can solve some of my pathfinding problems. I really like to do it with a grid, because it makes things very simple. I think that unfortunately this will only work out with quadratic units, won't it? And how would you implement collision avoidance on top of this? I think of something like before examining any node with A* I check if a move to this node would yield a collision with a not-moving unit and if so, the cell/node is treated as unpassable. Later when the path is executed the same checks are made before entering any node/cell.
  2. P@u1

    A* - Which Cell Size?

    I don't really understand this. Do you want to make different cells with different sizes? Could you please explain a bit more? Thx in advance :-)
  3. Hi everyone, I'm trying to do some basic pathfinding with the A* algorithm for an rts game. I wondered, which is the right cell size to choose. My first idea was to set the cell size to width of the unit with the highest width in the game. Otherwise I would have to check nodes at the sides too, to see if the unit can pass. For small units the cells can then maybe be divided in subcells, which will then be examined. What do you think about this? If you have any recommendations for articles/tutorials/books about this (not basic A*, but rather how to apply it for rts games), it would be very nice. Thanks in advance!
  4. P@u1

    Some Questions

    Thanks for your answers. That doesn't make much sense at all. Somewhat like asking: If I want to design a formula-one racecar engine, should I color the car red or blue? The choice to run your game in lockstep or not is one decision. There are pros and cons to either direction. The choice about the format to transmit your data across the wire is a separate decision. Send whatever data is necessary to keep your games in sync. And yes, both options are available in C#. [/quote] with float/double I was not talking about what I'm transfering across the wire, but I was talking about how to maintain fully determinism, which is required for a lockstep simulation. I know 2 solutions to this: - avoid float/double in all relevant parts of the code - make sure that your program will run with 100% ieee754 compliance. So I wanted to ask, which of these two methods usually is used and if and how I can get this ieee754 compliance with C#.
  5. Hi everyone, I have three questions: 1.: How fast is the speed of a typical LAN connection (local and not internet) (upload and download)? 2.: If I would make an rts game and want to use lockstep networking, should i then avoid float/double, or should I use them and make sure that I have floating point determinism? (Is this also possible with C#/.Net?) 3. Which networking model is best suited for a platformer game (e.g. imagine a mario game with multiplayer support)? I think server/client, but what do you think? Would lockstep work out, too? Or anything else maybe?
  6. Hallo everyone, it is common practice to run parts of the actual game logic in scripts written in some scripting language like lua. I wondered, if it will work out, if I run these scripts on the server only and the clients only see the effects of the scripts through state updates. Or do I have to run (parts of) the scripts on the clients too, or maybe use and send some events to control things?
  7. I like this idea, but it probably will make things much more complicated. Should then the client also be responsible for checking collisions between his actor and other actors or should this be done on the server? At the moment everything except for some movement extra/interpolation is done on the server.
  8. That's what I'm already doing. That's what I meant with interpolation (maybe it's the wrong word for this?). I'm correcting the position gradually (the difference between client-position and server-position is reduced by 10% each time a position update is received). But I'm not doing it with the velocity. Instead I set the velocity directly to the server's value (which will be out of date when it's received). When I try the same with the velocity as with the position (10% ...) it only partially fixes the problem and makes all other movements appear much worse. Do you have further suggestion, on how I can fix this? Thanks for your help so far!
  9. Thanks for your answers. The game is only programmed as a hobby, so I don't want put too hard restrictions on it. The problem with ~200ms delay was that when the client starts a jump he starts it locally and sends a message to the server. The server then also starts the jump (short time later) and sends the client back position and velocity updates. I use interpolation for the position, so that's not a big problem, but so far I set the velocity directly without interpolation. When then the next update from the server arrives, the actor stands still in the air for a very short time, which is very annoying for the player. Short after that the next update arrives and the rest of the jump is performed without problems. I tried to fix it using interpolation also for the velocity (although I read that that's not a good idea), but it didn't help that much and made other parts of movements worse... I haven't found a good solution for it so far. Maybe I will just don't care and only play it with low latencies, but if you have any suggestions which could help me to fix it, it would be very nice :-) Edit: Should I maybe start a new topic for that?
  10. Hi everone, how much delay when using UDP do you consider "normal"? How much would you reasonably expect? And another question: Does delay (usually/always) mean roundtriptime, or does it (sometimes) mean one way time? I just made some tests with a friend using lidgren library. Over internet it displayed just 16ms delay, which I consider very low. Is this normal? Or is this maybe because of the low physical distance? Before that I tested using with artificial delay (a feature of lidgren) and set it to 200ms and it had quite heavy impact on my game. But with 16ms it runs perfectly well (ofcourse). What do you think?
  11. I think something is wrong with your brackets: while(input == 10) { if (Server.Send(SendPacket,IP ,Port) != sf::Socket::Done) { std::cout<<"Could not send data"; } input = getchar(); if(input == 'z') break; } Server.Close(); so the while loop only contains the if statement. You could also post here: http://www.sfml-dev.org/forum/index.php Laurent (the sfml developer) usually answers very quickly and can help very good :-)
  12. Which status code is returned if it's not sf::Socket::Done? Does this directly happen or does it take some time, before the message is printed?
  13. First make sure, that the right thing is sent. Change the line for the server code from SendPacket >> PersonData1; to SendPacket << PersonData1; and verify with the debugger that everything is written as it should be. Then when receiving make sure that you use the right operator, it must be Packet >> Struct and not the other way round. Your code looks quite ok except for the wrong operators. Try it again with the right operators for both client and server and tell us what happens. If you have problem, use the debbuger and maybe post the new code here.
  14. In your client code replace if (ReceivePacket << PersonData2) with if (ReceivePacket >> PersonData2)
  15. Hello everyone, I'm searching for an open source game to learn something from reading the sources. There are some important requirements: - No turn based games or RTS - The game must have network support - No (or low amount of C code), I prefer C++ (for example std::string instead of char * strcpy strcat etc.) - Easily understandable (comments would be nice) I just tried SuperTuxKart and like the source, but unfortunately I recognized that the network support is still in quite early development. Any suggestions?
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!