Hot answers tagged

4

Card and Slot concepts should not be mixed. They're not the same. My behind is not fused with the chair on which I'm sitting. This allows me to play musical chairs. Let's organize your data: // A card; belongs to a player, has abilities (among which we find 'CanJump') Card Owner : Player // Blue or red CanJump : bool // Tells if the card can jump two ...


2

I need somehow to delay an initialization of other level's entities Why not add an init() and a terminate() methods to your Level class that does just that? init() populates your level when you're ready to play it, and terminate() cleans everything up when you're done with it. You might want to consider changing your architecture to have Level created ...


2

Based on your description, I would make each card effect verb a class & then use composition to combine them into cards as needed. E.G. the draw cards action would be an effect class, its parameters might be # of cards, source drawn from & type of draw. Damage player might be another effect class & its parameters might be amount & ...


2

In a multiplayer racing game, the client should be communicating position updates to the server. The server will then sanity check the message and update all the other clients. Never, ever trust the client to do these kinds of calculations for you. If you have the server do all the calculations, then you don't need to worry about the client telling the ...


1

I'm not 100% sure I caught your main idea between card relationships here, but to me it looks like some sort of network-like structure might work here. Your cards would have neighbours specified with some relation. It seems like you are trying to force a generic array here, but I think this is where using some traditional OOP simplifies the thinking process ...


1

Paradigm As of the time that this answer was written, the other posted answers here are all wrong. Instead of asking whether or not Domain-Driven Design is good for games. You should ask whether or not "Domain Modeling" is good for games. Is domain modeling good for games? The answer is: sometime it's absolutely fabulous. However, if you're creating a ...



Only top voted, non community-wiki answers of a minimum length are eligible