Ticket #3413: 3413.diff

File 3413.diff, 1.6 KB (added by Stan, 9 years ago)

Should assess 1) and 3) untested.

  • binaries/data/mods/public/gui/common/functions_global_object.js

     
    110110            caption += "\n";
    111111            ++linesCount;
    112112        }
    113         if (Engine.ConfigDB_GetValue("user", "gui.session.ceasefirecounter") === "true" && g_SimState.ceasefireActive)
     113        if (g_SimState.ceasefireActive)
    114114        {
    115115            var remainingTimeString = timeToString(g_SimState.ceasefireTimeRemaining);
    116116            caption += remainingTimeString + "\n";
  • binaries/data/mods/public/simulation/components/CeasefireManager.js

     
    123123    var playerEntities = Engine.QueryInterface(SYSTEM_ENTITY, IID_PlayerManager).GetAllPlayerEntities();
    124124    for (var i = 1; i < playerEntities.length; ++i)
    125125        Engine.QueryInterface(playerEntities[i], IID_Player).SetDiplomacy(this.diplomacyBeforeCeasefire[i-1]);
    126 
    127     // Send chat notifications and update the diplomacy screen
    128     for (var i = 1; i < playerEntities.length; ++i)
    129         for (var j = 1; j < playerEntities.length; ++j)
    130             if (i != j && this.diplomacyBeforeCeasefire[i-1][j] == -1)
    131                 cmpGuiInterface.PushNotification({"type": "diplomacy", "players": [j], "player1": [i], "status": "enemy"});
    132126   
    133127    // Reset values
    134128    this.ceasefireIsActive = false;