Git Product home page Git Product logo

Comments (4)

markmandel avatar markmandel commented on June 20, 2024

Thanks for submitting this bug! I think there are three things we can fix here:

  • Create some better docs here to let the end user know that only part of the GameServer configuration is exposed -- in this particular instance, what you will want to do is specify your counters and lists in the gameserver.status field - which is where you will see it (so that will help you move forward for now).
  • Only add default players and rooms when a file isn't loaded (probably a part of the defaultGs() function)
  • May also need to set GameServer.Status.Counts and GameServer.Status.Lists to empty maps on creation, just to ensure no nil pointer exceptions.

I think that will cover it!

from agones.

DazEdword avatar DazEdword commented on June 20, 2024

Brilliant, thank you. I will try moving the relevant fields into gameserver.status .

from agones.

DazEdword avatar DazEdword commented on June 20, 2024

Can confirm that the suggested fix does it:

status:
  lists: # lists are lists of values stored against this GameServer that can be added and deleted from. Keys must be declared at GameServer creation time.
    players: 
      capacity: 50
      values:
        - player
    test_list:
      capacity: 1
      values:
        - test

Correctly retrieving my test list capacity and values now 🎉 .

from agones.

markmandel avatar markmandel commented on June 20, 2024

Awesome! Good pickup!

It took @igooch and I a minute to work out what was going on when we looked at the code!

from agones.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.