I posted this over on gamedev.net but haven't had any hits yet, hoping some of the bright minds here can give me some guidance.
I have started working on writing a 2D Isometric style game. The idea is to have a persistant world (each tile is unique) and sent from the server where it is then generated (tile object) and then drawn when needed.
The way the game code works right now is that all objects have Draw() and Update() functions that are called every loop by it's parent "Screen" (Static objects, with their own controls/objects/references) Draw() and Update() functions, which in turn are called during the game loop. Basically:
While (!Exited)
ActiveScreen->Update(); -> In turn updating all child objects
ActiveScreen->Draw(); -> In turn drawing all the child objects
While our FPS > Max wait
Inside the Update() functions are things such as positioning, reloading certain objects I free to prevent leaks, checking sdl events (mouse movements, key presses, etc).
Then the Draw() functions determine if that object is visible on the screen, if it is marked visible, if the texture is valid, etc then it runs the SDL Functions to draw it (blit).
The screens Draw() function first clears the screen, runs all the draw functions for the objects that have been programmed then it refreshes the screen so that the changes are visible.
First question, is the above the right concept? I used things I had read/sdl tutorials/way XNA did things to put that bit together. If anyone has a better suggestion I am all ears.
Second question, even though I have the checks to ensure that things show on screen I notice that with a large tile array it slows right down even though it is only displaying a small portion, should I have an array that is filled on the update function that holds all the tile objects instead of looping through all of them at draw time? As each tile is it's own thing and done isometrically I need to redraw each visible tile every time so that they stack properly, so updating only 1 tile at a time isn't doable as it will end up overlapping in the wrong way.
I am sure I will have more questions as I go along. I am pretty experienced with C# and I understand C++ enough to make it work/work right however I am not that well versed in game logic as I do application programming for a living. I want to do this in C++ with SDL instead of using a pre-built solution (XNA,MonoGame,etc) as this will teach me a lot more than using things I am already comfortable with, and a lot of the logic is already handled in.
SpaceX took its largest step yet toward becoming a retail wireless carrier on Friday when President and COO Gwynne Shotwell told investors at the company's IPO roadshow that SpaceX is considering launching a Starlink-branded mobile phone service for US consumers..............
https://www.techtimes.com/articles/319177/20260627/starlink-mobile-coming-t-verizon-spacex-has-spectrum-still-needs-towers.htm
Stop asking people that. It's a "No True Scotsman" argument in that you are attempting to discredit the opinions of a person by Attacking the Messenger.
The reason that these are logical fallacies is the TRUTH is based on facts as supported by evidence. Nothing else.
So, always debate the facts with evidence to reach the truth.
Once you learn to do this, you'll be able to recognize when people are fearmongering and lying to you for their own selfish ends.
It doesn't matter if you didn't directly hear it from person X or Y. Every one of your statements comes straight from the racist, skinhead, anti-immigrant, be afraid of everything, "they are all taking our jobs", etc. etc. mouthpieces. That's where Farag and Putin heard it from too...and used it against the UK.
So, while you keep disavowing the people who publicly peddled that position, you keep proving over and over again that those lies influenced you into being tricked when the Brexit vote came around too.
In fact, your final sentence makes it crystal clear that it was the racist/anti-immigrant lies you fell and voted for, since you stated that you didn't have an issue with the economic trade issues with the EU. Ahem.
To be clear, all of these LIES are EONS old, mate. They are the same fearmongering lies peddled to the same ignorant, gullible cowards by the same charlatans, snake-oil salesmen, and would be demagogues who've been doing this since caveman Ugh lied about his slightly different neighbor in order to steal his land.
And, finally, you answered your own previous question. The reason that the EU isn't clamoring to bring the UK back is that they have had enough of people who would rather shoot themselves in the foot than get over their "insecurity issues".
It's the same reason the entire world is moving away from the USA as fast as it can...
Question
firey
I posted this over on gamedev.net but haven't had any hits yet, hoping some of the bright minds here can give me some guidance.
I have started working on writing a 2D Isometric style game. The idea is to have a persistant world (each tile is unique) and sent from the server where it is then generated (tile object) and then drawn when needed.
The way the game code works right now is that all objects have Draw() and Update() functions that are called every loop by it's parent "Screen" (Static objects, with their own controls/objects/references) Draw() and Update() functions, which in turn are called during the game loop. Basically:
While (!Exited)
ActiveScreen->Update(); -> In turn updating all child objects
ActiveScreen->Draw(); -> In turn drawing all the child objects
While our FPS > Max wait
Inside the Update() functions are things such as positioning, reloading certain objects I free to prevent leaks, checking sdl events (mouse movements, key presses, etc).
Then the Draw() functions determine if that object is visible on the screen, if it is marked visible, if the texture is valid, etc then it runs the SDL Functions to draw it (blit).
The screens Draw() function first clears the screen, runs all the draw functions for the objects that have been programmed then it refreshes the screen so that the changes are visible.
First question, is the above the right concept? I used things I had read/sdl tutorials/way XNA did things to put that bit together. If anyone has a better suggestion I am all ears.
Second question, even though I have the checks to ensure that things show on screen I notice that with a large tile array it slows right down even though it is only displaying a small portion, should I have an array that is filled on the update function that holds all the tile objects instead of looping through all of them at draw time? As each tile is it's own thing and done isometrically I need to redraw each visible tile every time so that they stack properly, so updating only 1 tile at a time isn't doable as it will end up overlapping in the wrong way.
I am sure I will have more questions as I go along. I am pretty experienced with C# and I understand C++ enough to make it work/work right however I am not that well versed in game logic as I do application programming for a living. I want to do this in C++ with SDL instead of using a pre-built solution (XNA,MonoGame,etc) as this will teach me a lot more than using things I am already comfortable with, and a lot of the logic is already handled in.
Link to comment
https://www.neowin.net/forum/topic/1156484-csdl-game-design-guidance/Share on other sites
8 answers to this question
Recommended Posts