• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.

lride

Members
  • Content count

    190
  • Joined

  • Last visited

Community Reputation

674 Good

About lride

  • Rank
    Member
  1. Server rewinding to account for player's ping spike is a terrible idea imo. If a player has unstable network condition, he/she should not expect a smooth gameplay.
  2. You could tick slightly slower. E.g. if you tick at 25hz, that's 40ms per tick. Increasing that to 41ms will slow you down by about 2.5%, which is probably not very noticeable to the player, but it will also not close the gap very fast (6.4s for 3 ticks at 25hz). There's a bit of a trade off to make between closing the gap faster and how noticeable the slowdown is to the player, this doesn't have to be a static value though, you can adjust the slowdown based on how large the gap is.   Thanks, this approach sounds good. 
  3. I'm making a 2d multiplayer platformer. I do client prediction for my own player and do interpolation for other players. I understand client always tries to stay ahead of server, so an input for tick T should arrive close to when server simulates T. For every input packet, server tells the client how far the input was off. If the input was too early, then the client needs to slow down. If the input was late, then the client needs to speed up. What i don't understand is how to slow down or speed up. For example, if server tells me it received my input for tick 10 at tick 7(3 ticks early), then I need to slow down 3 ticks worth of time. How should I go about doing this?
  4. Thanks, that works. But I don't understand why I don't get a warning with packer.pack<0, 127>(7u)?
  5. Here, I'm calling uint32_t version of Packer::pack, but I'm getting this warning.  Could someone help me out? Thanks! Packer packer; packer.pack<0, 127>(7u); //no warning packer.pack<0, 128>(7u); //warning class Packer { public: Packer(); const void * getData() const; std::size_t getDataSize() const; void pack(bool data); template <std::int8_t min = (std::numeric_limits<std::int8_t>::min)(), std::int8_t max = (std::numeric_limits<std::int8_t>::max)()> void pack(std::int8_t data); template <std::uint8_t min = (std::numeric_limits<std::uint8_t>::min)(), std::uint8_t max = (std::numeric_limits<std::uint8_t>::max)()> void pack(std::uint8_t data); template <std::int16_t min = (std::numeric_limits<std::int16_t>::min)(), std::int16_t max = (std::numeric_limits<std::int16_t>::max)()> void pack(std::int16_t data); template <std::uint16_t min = (std::numeric_limits<std::uint16_t>::min)(), std::uint16_t max = (std::numeric_limits<std::uint16_t>::max)()> void pack(std::uint16_t data); template <std::int32_t min = (std::numeric_limits<std::int32_t>::min)(), std::int32_t max = (std::numeric_limits<std::int32_t>::max)()> void pack(std::int32_t data); template <std::uint32_t min = (std::numeric_limits<std::uint32_t>::min)(), std::uint32_t max = (std::numeric_limits<std::uint32_t>::max)()> void pack(std::uint32_t data); ...  
  6. https://developer.valvesoftware.com/wiki/Source_Multiplayer_Networking https://code.google.com/archive/p/nuclear-bomberman/wikis/Interpolation.wiki   After reading these 2 articles, I was able to implement mine.
  7. Trying to see if there is a point in trying to write endian independent code
  8. i2 points to the same address as i does. so since i becomes "0", shouldon't i2 also be "0"?
  9. String i = "3"; String i2 = i; i = "0"; System.out.println(i2);     I expected this to print out 0, but it prints out  3. Why?
  10. Right now is a fantastic timing to build a desktop since the new skylake intel cores were just released. But if you absolutely need the portability, I recommend a high end ASUS or MSI gaming laptop.
  11. Hello, I'm trying to write my own GUI system with SFML, but I'm a bit lost where to start... Like how should the classes be designed? How should the events be handled when there are  2 overlapping windows?  Are there any resources on this?
  12. struct A { A(){} A(int i, std::string s){} A(std::string s){} }; A createA(...) { return A(...); } int main() { createA(); createA(1, "zz"); createA("zz"); } I'm getting error C2143: syntax error : missing ')' before '...' why??
  13. I'm trying to implement network entity interpolation described in this article: http://www.gabrielgambetta.com/fpm3.html   so far I have this and the circle's movement looks jittery. What did I do wrong? struct Circle { sf::Vector2f current; sf::Vector2f last; sf::CircleShape shape; Circle() { shape.setRadius(100); } void interpolate() { sf::Vector2f difference = current - last; current.x += difference.x * 0.1; current.y += difference.y * 0.1; } void draw(sf::RenderWindow & window) { shape.setPosition(current.x, current.y); window.draw(shape); } void setPosition(sf::Vector2f v) { last = current; current = v; } }; //server void server() { sf::TcpListener listener; sf::TcpSocket client; listener.listen(PORT); listener.accept(client); client.setBlocking(false); Circle circle; sf::RenderWindow window(sf::VideoMode(800, 600), "server"); sf::Clock clock; sf::Time elapsed = sf::Time::Zero; sf::Time timePerFrame = sf::seconds(1 / 20.f); while (window.isOpen()) { sf::Time dt = clock.restart(); elapsed += dt; while (elapsed > timePerFrame) { elapsed -= timePerFrame; sf::Event event; while (window.pollEvent(event)) { if (event.type == sf::Event::Closed) window.close(); } sf::Packet packet; sf::Socket::Status s = client.receive(packet); while (s == sf::Socket::Done) { //new position sent from the client; float x, y; packet >> x >> y; circle.setPosition({ x, y }); packet.clear(); s = client.receive(packet); } circle.interpolate(); } window.clear(); circle.draw(window); window.display(); } } what's wrong with my code?