Beispiel #1
0
        public PlayerResources(Actor self, PlayerResourcesInfo info)
        {
            Info  = info;
            owner = self.Owner;

            var startingCash = self.World.LobbyInfo.GlobalSettings
                               .OptionOrDefault("startingcash", info.DefaultCash.ToString());

            if (!int.TryParse(startingCash, out Cash))
            {
                Cash = info.DefaultCash;
            }
        }
Beispiel #2
0
        public PlayerResources(Actor self, PlayerResourcesInfo info)
        {
            Info  = info;
            owner = self.Owner;

            var startingCash = self.World.LobbyInfo.GlobalSettings
                               .OptionOrDefault("startingcash", info.DefaultCash.ToString());

            if (!int.TryParse(startingCash, out Cash))
            {
                Cash = info.DefaultCash;
            }

            lastNotificationTime = -Info.InsufficientFundsNotificationInterval;
        }