Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3495170
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T12:05:39+00:00 2026-05-18T12:05:39+00:00

I was having a discussion with my developer mate on following game design. I

  • 0

I was having a discussion with my developer mate on following game design.

I have a collection of Move in the Game class. my developer mate is asking me to remove the collection and only have the current move information there.

what is your suggestions?

public class Game
{
    public String Id { get; set; }
    public String CreatorId { get; set; }

    public List<Player> Players { get; set; }
    public List<Move> Moves { get; set; }
}

public class Player
{
    public String Id { get; set; }
    public String Name { get; set; }
}

public class Move
{
    public String Id { get; set; }
    public String PlayerId { get; set; }
    public String PlayerName { get; set; }
    public String NextMoveId { get; set; }
    public String NextPlayerId { get; set; }
    public String Position { get; set; }
}

Edit:
my developer mate suggests me to only have a single Move object in the Game class.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T12:05:40+00:00Added an answer on May 18, 2026 at 12:05 pm

    There’s no really correct approach that any of us can provide for your design. It isn’t a cut-and-dry situation; there’s no “right” or “wrong” answer. And it’s especially difficult for us to make suggestions given that we don’t know all of the details behind your game’s design. For example, as I asked in a comment and several of the other answers have hinted towards, if you have an “Undo” or “Replay” feature, you will need to store a history of all the moves. If not, and you have no desire to implement such a feature, there is no need to store information about all of the moves.

    This is the kind of design decision that you need to learn how to make as a programmer. Consider all of the possible benefits of one approach and the benefits of the other approach, then decide which one best suits your application. Make a “T” chart if you find it helpful. Something like:

           Keeping List of All Moves           |         Storing Only Last Move
        ---------------------------------------|------------------------------------
         - Allows you to implement Undo        |   - Simplifies your game's design 
            or Replay feature                  | 
         - Consumes more memory                |   - Saves memory by only storing the
                                               |      minimum amount of data
                                               | 
                                               |
        ...etc.
    

    In the end, you (and your colleague) are the ones in the best position to make this decision. Making sure that you’ve armed yourself with a careful comparison of the advantages and disadvantages is the best way to ensure that you’ve made the right one.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We're having a discussion with a friend concerning java code design and efficiency. He
I was having a discussion with a developer at work on the issue of
Having a design discussion with some co-workers about our app. Looking for the best
I was having a discussion with coworkers. We have to implement some security standards.
I was having a discussion with one of my colleagues about how defensive your
We are currently having a discussion if dataset should go in the data or
We are having another discussion here at work about using parametrized sql queries in
I've been having a discussion with my coworkers as to whether to prefix overridden
We're having this discussion here. Which is better and why? 1) a php file
Recently I was having a discussion with a friend about Ruby's Proc . You

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.