neroyu.blogg.se

Bzflag server list
Bzflag server list










bzflag server list
  1. Bzflag server list how to#
  2. Bzflag server list code#

Now, before we access the information in the player record, we must check that record is not NULL because bz_getPlayerByIndex() will return NULL if a player with the given ID does not exist. int playerID = 1 īz_BasePlayerRecord *record = bz_getPlayerByIndex(playerID) Let's create a player record for the player whose ID is currently 1. In the previous chapter, it was mentioned that player IDs were unique to players during their current session on a server these player IDs will be used throughout your plugin. We'll be using the bz_getPlayerByIndex(int playerID) function to create a record for the player with the given player ID and we'll receive a pointer to our player record since we're receiving a pointer to the data, we must free the record once we're done with it with bz_freePlayerRecord(). This change encouraged significant simplification of the server list processing.

Bzflag server list code#

So what happens when we're in a place of our code where the API doesn't provide a record for us? We create it by ourselves. thread List bzflag commitsSubject SF.net SVN bzflag 19405 trunk bzflag. Data // - // (int) playerID - The player ID that is joining // (bz_BasePlayerRecord*) record - The player record for the joining player // (double) eventTime - Time of event. Some servers provide additional benefits for registered users, such as voting. case bz_ePlayerJoinEvent:īz_PlayerJoinPartEventData_V1 *data = (bz_PlayerJoinPartEventData_V1*)eventData BZFlag is a free 3D online multi-player multi-platform tank battle game. For example, the bz_ePlayerJoinEvent has a record attribute that is automatically created and freed for you however, the player record will only exist in the same scope of *data as seen in the snippet below.

bzflag server list

Player Records to "Player Records" sectionĪll player records are bz_BasePlayerRecord objects and they can either be created manually or are automatically given to you by the API.

Bzflag server list how to#

Let's go over what information is available, how to create them, how to use them, and how to free them when we're done. Last week, I briefly mentioned player records and the fact that they'll typically be used whenever we want information regarding a player on the server. We're back and in this chapter we'll be discussing player records and modification API events. I told you it wouldn't take another 2 years until the next post. Interstellar space pirate extraordinaire












Bzflag server list