So, I'll put this out there. If anyone has the solution, please let me know:
This code:
Code:
public override void OnBuildingKilled(string title, Point3d pos, AiDamageInitiator initiator, int eventArgInt)
{
base.OnBuildingKilled(title, pos, initiator, eventArgInt);
string BuildingName = title;
string BuildingArmy = "";
string PlayerArmy = "";
string sectorTitle = "";
string sectorName = GamePlay.gpSectorName(pos.x, pos.y);
if (GamePlay.gpFrontArmy(pos.x, pos.y) == 1)
{
BuildingArmy = "England";
}
else if (GamePlay.gpFrontArmy(pos.x, pos.y) == 2)
{
BuildingArmy = "France";
}
else
{
BuildingArmy = "Neutral";
}
if (initiator.Player.Army() == 1)
{
PlayerArmy = "RAF";
}
else if (initiator.Player.Army() == 2)
{
PlayerArmy = "Luftwaffe";
}
else
{
PlayerArmy = "Unknown";
}
GamePlay.gpLogServer(null, "BUILDING:" + BuildingName + " in " + BuildingArmy + " was destroyed in sector " + sectorName + " by " + initiator.Player.Name() + " from the " + PlayerArmy + ".", new object[] { });
}
...is designed to put up a little message when anyone destroys a building on the map. Any building at all. Not just buildings placed in the FMB, but buildings on the base maps as well.
When added to a Single Player map, it works perfectly.
When added to a Multi Player map, it works...only for the person hosting the server.
When added to a dedicated server, it doesn't work for anyone.
Ideas? It might be that I'm missing something that I'm just not aware of.
Bookmarks