Ignore:
Timestamp:
Sep 4, 2018, 1:00:48 PM (6 years ago)
Author:
alloc
Message:

Code style cleanup (mostly whitespace changes, enforcing braces, using cleanup)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • binary-improvements/7dtd-server-fixes/src/API.cs

    r324 r325  
    1 using System;
    21using System.Collections.Generic;
    32
    4 namespace AllocsFixes
    5 {
     3namespace AllocsFixes {
    64        public class API : IModApi {
     5                public void InitMod () {
     6                        ModEvents.GameAwake.RegisterHandler (GameAwake);
     7                        ModEvents.GameShutdown.RegisterHandler (GameShutdown);
     8                        ModEvents.SavePlayerData.RegisterHandler (SavePlayerData);
     9                        ModEvents.PlayerSpawning.RegisterHandler (PlayerSpawning);
     10                        ModEvents.PlayerDisconnected.RegisterHandler (PlayerDisconnected);
     11                        ModEvents.ChatMessage.RegisterHandler (ChatMessage);
     12                }
    713
    814                public void GameAwake () {
     
    1319                        StateManager.Shutdown ();
    1420                }
    15                
     21
    1622                public void SavePlayerData (ClientInfo _cInfo, PlayerDataFile _playerDataFile) {
    1723                        PlayerDataStuff.GM_SavePlayerData (_cInfo, _playerDataFile);
     
    2127                        AllocsLogFunctions.RequestToSpawnPlayer (_cInfo, _chunkViewDim, _playerProfile);
    2228                }
    23                
     29
    2430                public void PlayerDisconnected (ClientInfo _cInfo, bool _bShutdown) {
    2531                        AllocsLogFunctions.PlayerDisconnected (_cInfo, _bShutdown);
    2632                }
    2733
    28                 public bool ChatMessage (ClientInfo _cInfo, EChatType _type, int _senderId, string _msg, string _mainName, bool _localizeMain, List<int> _recipientEntityIds) {
     34                public bool ChatMessage (ClientInfo _cInfo, EChatType _type, int _senderId, string _msg, string _mainName,
     35                        bool _localizeMain, List<int> _recipientEntityIds) {
    2936                        return ChatHookExample.Hook (_cInfo, _type, _msg, _mainName);
    30                 }
    31 
    32                 public void InitMod () {
    33                         ModEvents.GameAwake.RegisterHandler (GameAwake);
    34                         ModEvents.GameShutdown.RegisterHandler (GameShutdown);
    35                         ModEvents.SavePlayerData.RegisterHandler (SavePlayerData);
    36                         ModEvents.PlayerSpawning.RegisterHandler (PlayerSpawning);
    37                         ModEvents.PlayerDisconnected.RegisterHandler (PlayerDisconnected);
    38                         ModEvents.ChatMessage.RegisterHandler (ChatMessage);
    3937                }
    4038        }
    4139}
    42 
Note: See TracChangeset for help on using the changeset viewer.