COG Verbs - Multiplayer


Notes:

The Backpack System

A backpack is a special powerup that usually contains the weapons and ammo of a dead player. Backpacks are created with CreateBackpack(). This verb will add all items whose inventory bin has the 0x80 Inventory Flag to the backpack.

PickupBackpack() adds all of the items in a backpack to a player's inventory, and probably replaced a more complicated system using the NthBackpack verbs. Here's a chart showing how items are organized in a backpack:


Item Storage In A Backpack
Item Number Bin Amount Bin Used For
121Bryar.
271Rail Detonator.
3101Lightsaber.
41150Energy ammo.
5156Rail charges.


The number of items in a backpack is returned by NumBackpackItems(). Once you have the number of items, you use NthBackpackBin() to return the bin ID of each item. With the bin number, you can find out how much is in the bin with NthBackpackValue().


Team System

When teamplay is used in a normal multiplayer game, four teams can be used: red, yellow, blue, and green. When teamplay is not checked, all players will have a team of 0 which cannot be changed. Whether teamplay is on or off, players always have a team.


Sync Verbs

The Sync Verbs are used to synchronize information on one computer with the other computers in a multiplayer game. This is mostly done for joining players to sync effects created before they joined. Once a Sync Verb has been run in a cog, it will run automatically when another player joins to sync the effect again for another joining player.

  • Create:
This page was last modified 23:41, 24 March 2006.   This page has been accessed 239 times.