Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int PlayerInPlayerGroupWithBestProperty (playergroup g, int property) {
- fixed bestQuantity = 0;
- fixed quantity;
- int bestPlayer;
- int player;
- int count;
- for (count = PlayerGroupCount(g); count > 0; count-=1)
- {
- player = PlayerGroupPlayer(g,count);
- quantity = PlayerGetPropertyFixed(player,property);
- if (quantity > bestQuantity)
- {
- bestPlayer = player;
- bestQuantity = quantity;
- }
- }
- return bestPlayer;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement