Hi everyone
I am writing a MMORPG server (just the server) and I am starting to focus on the "lightweight-ness" and effeciency of it.
I am going to give an extremely short version of my question;
I am going to use a loop to look through around 10-100 objects every minute and have an If/else statement in there. How much does a loop like this effect on my server ? It might be a silly question but I am debating on whether to create an object for every 100 instances (of clients) and then loop through 1-6 objects instead. Which one would work more effeciently ?
if this didn't make any sense I'll try to explain it differently. Imagine around 100 clients in a map. I am trying to find 8 of those clients that are related to each other (theyre in a group/party). Would it be wisest to loop through all 100 stand alone clients to find the 8 ones, or use around 10 Objects (in this case called groups/partys) and look throughout those instead ? (each group contains 8 clients). Remember, either way this check will happen every minute or so.
Thanks! I am curious about the responses !