Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > IL-2 Sturmovik: Cliffs of Dover > FMB, Mission & Campaign builder Discussions

Reply
 
Thread Tools Display Modes
  #1  
Old 08-04-2012, 01:05 PM
hc_wolf hc_wolf is offline
Approved Member
 
Join Date: Jul 2010
Posts: 439
Default

does this help?

Code:
    private void sendChatMessageTo(int army, string msg, object[] parms)
    {
        List<Player> Players = new List<Player>();

        //Singleplayer or Dedi Server
        if (GamePlay.gpPlayer() != null)
        {
            if (GamePlay.gpPlayer().Army() == army || army == -1)
                Players.Add(GamePlay.gpPlayer());
        } // Multiplayer
        if (GamePlay.gpRemotePlayers() != null || GamePlay.gpRemotePlayers().Length > 0)
        {
            foreach (Player p in GamePlay.gpRemotePlayers())
            {
                if (p.Army() == army || army == -1)
                    Players.Add(p);
            }
        }
        if (Players != null && Players.Count > 0)
            GamePlay.gpLogServer(Players.ToArray(), msg, parms);
    }
__________________
__________________
Win7, 64bit Ultra
Asus P8P67Pro MB
Intel i7-2600K
Coursair 16GB (4x 4GB), DDR3-1600MHz
Gainward Nvidia 580GTX 3GB DDR5
850-Watt Modular Power Supply
WIN7 and COD on Gskill SSD 240GB
40" Panasonic LCD
TrackIR5 +
Thrustmaster Warthog stick, throttle & pedals
Reply With Quote
  #2  
Old 08-04-2012, 01:28 PM
salmo salmo is offline
Approved Member
 
Join Date: Mar 2011
Posts: 632
Default

Sorry to say it doesn't Wolf. I'm trying to write script-log information to the Launcher console from a sub-mission script, not write to the game screen chat window.
__________________
When one engine fails on a two engine bomber, you will always have enough power left to get to the scene of the crash.

Get the latest COD Team Fusion patch info HERE
Reply With Quote
  #3  
Old 08-04-2012, 02:53 PM
podvoxx podvoxx is offline
Approved Member
 
Join Date: Feb 2010
Posts: 190
Default

Quote:
Originally Posted by salmo View Post
Sorry to say it doesn't Wolf. I'm trying to write script-log information to the Launcher console from a sub-mission script, not write to the game screen chat window.
http://www.sukhoi.ru/forum/showthrea...65#post1875465

Ask about this naryv on Sukhoi.ru, he know how do this.
Reply With Quote
  #4  
Old 08-13-2012, 02:14 PM
salmo salmo is offline
Approved Member
 
Join Date: Mar 2011
Posts: 632
Default

I've tried using the 'Sending server console commands from script' example below, but the code below throws a "missing reference required error" at the line in the sub-mission script where SendServerCommand function is called
__________________
When one engine fails on a two engine bomber, you will always have enough power left to get to the scene of the crash.

Get the latest COD Team Fusion patch info HERE

Last edited by salmo; 10-18-2012 at 09:16 AM.
Reply With Quote
  #5  
Old 09-25-2012, 06:30 AM
podvoxx podvoxx is offline
Approved Member
 
Join Date: Feb 2010
Posts: 190
Default

Quote:
Originally Posted by salmo View Post
I've tried using the 'Sending server console commands from script' example below, but the code below throws a "missing reference required error" at the line in the sub-mission script where SendServerCommand function is called

Code:
    public void SendServerCommand(string command)
    #region send a command to the game server console
    {
        GameServerDef gameServerDef = base.GamePlay as GameServerDef;
        if (gameServerDef != null)
        {
            gameServerDef.consoleInput(command);
        }
        
    }
    #endregion
http://www.sukhoi.ru/forum/showthrea...=1#post1880966

I'm very sorry, I lost this topic. If necessary, use this:

Code:
using maddox.game;
Reply With Quote
  #6  
Old 09-25-2012, 07:25 AM
salmo salmo is offline
Approved Member
 
Join Date: Mar 2011
Posts: 632
Default

Quote:
Originally Posted by podvoxx View Post
http://www.sukhoi.ru/forum/showthrea...=1#post1880966

I'm very sorry, I lost this topic. If necessary, use this:

Code:
using maddox.game;
Thankyou podvoxx. This does not provide a solution however. It's been dificult to get the mesage to the game developers that there are certain C# processes that just don't work when launched from a sub-mission script.

It looks like any server console output or in-game text output fails when you try to perform these from a sub-missions script. These are the C# actions that fail: gpHUDLogCenter, gpLogServer, Console.Write, Console.WriteLine, sayToGroup

Please see details HERE
__________________
When one engine fails on a two engine bomber, you will always have enough power left to get to the scene of the crash.

Get the latest COD Team Fusion patch info HERE
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:49 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.