12 Commits

Author SHA1 Message Date
VladMordock
78310771c3 Merge pull request #40 from szporwolik/dev
0.10.1
2020-09-15 00:45:41 +02:00
szporowolik
18b6d8b0ce Build for 0.10.1 2020-09-15 00:38:53 +02:00
szporowolik
dcb9510802 DB update for 0.10.1 2020-09-15 00:25:27 +02:00
szporowolik
d35ceafab2 Final build for 0.10.1 2020-09-15 00:24:36 +02:00
VladMordock
84e1d97c8e Changed autostart to 500ms 2020-09-15 00:20:24 +02:00
szporowolik
9f22b0e4df Fixed #38 - Scuds shall be counted now 2020-09-15 00:09:38 +02:00
VladMordock
699787c00e Commend line parameter for autostart 2020-09-15 00:01:20 +02:00
szporowolik
403b3df59a - Prepared for 0.10.1 build
- Added autostart parameter
2020-09-14 23:59:20 +02:00
VladMordock
c2fa89e364 Updated ReadMe as per #37
Updated ReadMe as per #37
2020-09-14 23:27:06 +02:00
Szymon Porwolik
5b96f2387e Added PHP integration example
Added PHP integration example per #37
2020-09-14 23:24:01 +02:00
VladMordock
52891a19e7 Merge pull request #36 from szporwolik/dev
Fixed events not triggered
2020-07-01 14:32:24 +02:00
szporowolik
466171a756 Fixed events not triggered 2020-07-01 14:31:45 +02:00
9 changed files with 238 additions and 44 deletions

View File

@@ -9,7 +9,7 @@ package.cpath = package.cpath..";"..lfs.currentdir().."/LuaSocket/?.dll"
Perun.RefreshStatus = 15 -- (int) [default: 60] Base refresh rate in seconds to send status update Perun.RefreshStatus = 15 -- (int) [default: 60] Base refresh rate in seconds to send status update
Perun.RefreshMission = 60 -- (int) [default: 120] Refresh rate in seconds to send mission information Perun.RefreshMission = 60 -- (int) [default: 120] Refresh rate in seconds to send mission information
Perun.TCPTargetPort = 48620 -- (int) [default: 48621] TCP port to send data to Perun.TCPTargetPort = 48621 -- (int) [default: 48621] TCP port to send data to
Perun.TCPPerunHost = "localhost" -- (string) [default: "localhost"] IP adress of the Perun instance or "localhost" Perun.TCPPerunHost = "localhost" -- (string) [default: "localhost"] IP adress of the Perun instance or "localhost"
Perun.Instance = 1 -- (int) [default: 1] Id number of instance (if multiple DCS instances are to run at the same PC) Perun.Instance = 1 -- (int) [default: 1] Id number of instance (if multiple DCS instances are to run at the same PC)
Perun.JsonStatusLocation = "Scripts\\Json\\" -- (string) [default: "Scripts\\Json\\"] Folder relative do user's SaveGames DCS folder -> status file updated each RefreshMission Perun.JsonStatusLocation = "Scripts\\Json\\" -- (string) [default: "Scripts\\Json\\"] Folder relative do user's SaveGames DCS folder -> status file updated each RefreshMission
@@ -22,7 +22,7 @@ Perun.MOTD_L2 = "Wymagamy obecnosci DCS SRS oraz TeamSpeak - szczegoly na forum"
-- ###################### END OF SETTINGS - DO NOT MODIFY OUTSIDE THIS SECTION ###################### -- ###################### END OF SETTINGS - DO NOT MODIFY OUTSIDE THIS SECTION ######################
-- Variable init -- Variable init
Perun.Version = "v0.10.0" Perun.Version = "v0.10.1"
Perun.StatusData = {} Perun.StatusData = {}
Perun.SlotsData = {} Perun.SlotsData = {}
Perun.MissionData = {} Perun.MissionData = {}
@@ -796,33 +796,6 @@ Perun.onGameEvent = function (eventName,arg1,arg2,arg3,arg4,arg5,arg6,arg7)
-- Game event has occured -- Game event has occured
Perun.AddLog("Event handler for ".. eventName .. " started",2) Perun.AddLog("Event handler for ".. eventName .. " started",2)
-- Below debug helper
local event_arguments = eventName
if arg1 ~= "" then
event_arguments = event_arguments .. " arg1: " .. arg1
end
if arg2 ~= "" then
event_arguments = event_arguments .. " arg2: ".. arg2
end
if arg3 ~= "" then
event_arguments = event_arguments .. " arg3: ".. arg3
end
if arg4 ~= "" then
event_arguments = event_arguments .. " arg4: ".. arg4
end
if arg5 ~= "" then
event_arguments = event_arguments .. " arg5: ".. arg5
end
if arg6 ~= "" then
event_arguments = event_arguments .. " arg6: ".. arg6
end
if arg7 ~= "" then
event_arguments = event_arguments .. " arg7: ".. arg7
end
Perun.AddLog("DEBUG onGameEvent:" .. event_arguments,2)
if eventName == "friendly_fire" then if eventName == "friendly_fire" then
--"friendly_fire", playerID, weaponName, victimPlayerID --"friendly_fire", playerID, weaponName, victimPlayerID
if arg2 == "" then if arg2 == "" then
@@ -869,7 +842,7 @@ Perun.onGameEvent = function (eventName,arg1,arg2,arg3,arg4,arg5,arg6,arg7)
_temp_event_type="kill_Infantry" _temp_event_type="kill_Infantry"
elseif _temp_category == "Fortification" then elseif _temp_category == "Fortification" then
_temp_event_type="kill_Fortification" _temp_event_type="kill_Fortification"
elseif _temp_category == "Artillery" then elseif _temp_category == "Artillery" or _temp_category == "MissilesSS" then
_temp_event_type="kill_Artillery" _temp_event_type="kill_Artillery"
else else
_temp_event_type="kill_Other" _temp_event_type="kill_Other"

View File

@@ -77,6 +77,7 @@
this.con_img_dcs = new System.Windows.Forms.PictureBox(); this.con_img_dcs = new System.Windows.Forms.PictureBox();
this.con_img_db = new System.Windows.Forms.PictureBox(); this.con_img_db = new System.Windows.Forms.PictureBox();
this.con_Button_Add_Marker = new System.Windows.Forms.Button(); this.con_Button_Add_Marker = new System.Windows.Forms.Button();
this.TIM_Autostart = new System.Windows.Forms.Timer(this.components);
this.con_GroupBox_1.SuspendLayout(); this.con_GroupBox_1.SuspendLayout();
this.con_GroupBox_2.SuspendLayout(); this.con_GroupBox_2.SuspendLayout();
this.con_GroupBox_3.SuspendLayout(); this.con_GroupBox_3.SuspendLayout();
@@ -524,6 +525,10 @@
this.con_Button_Add_Marker.UseVisualStyleBackColor = true; this.con_Button_Add_Marker.UseVisualStyleBackColor = true;
this.con_Button_Add_Marker.Click += new System.EventHandler(this.con_Button_Add_Marker_Click); this.con_Button_Add_Marker.Click += new System.EventHandler(this.con_Button_Add_Marker_Click);
// //
// TIM_Autostart
//
this.TIM_Autostart.Interval = 500;
//
// form_Main // form_Main
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
@@ -573,7 +578,10 @@
((System.ComponentModel.ISupportInitialize)(this.con_img_db)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.con_img_db)).EndInit();
this.ResumeLayout(false); this.ResumeLayout(false);
this.PerformLayout(); this.PerformLayout();
// TIM_Autostart
//
this.TIM_Autostart.Tick += new System.EventHandler(this.TIM_Autostart_Tick);
//
} }
#endregion #endregion
@@ -625,6 +633,7 @@
private System.Windows.Forms.Label label13; private System.Windows.Forms.Label label13;
private System.Windows.Forms.Label label14; private System.Windows.Forms.Label label14;
private System.Windows.Forms.Button con_Button_Add_Marker; private System.Windows.Forms.Button con_Button_Add_Marker;
private System.Windows.Forms.Timer TIM_Autostart;
} }
} }

View File

@@ -67,6 +67,19 @@ namespace Perun_v1
} }
} }
if (args.Length > 5)
{
// Get argument lotATC file path
if (args[5] != null)
{
if (args[5] == "1")
{
TIM_Autostart.Enabled = true;
PerunHelper.AddLog(ref Globals.AppLogHistory, "Autostart parameter provided", 0, 1);
}
}
}
// Initialize controls // Initialize controls
con_img_db.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected"); con_img_db.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected");
con_img_dcs.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected"); con_img_dcs.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected");
@@ -183,7 +196,7 @@ namespace Perun_v1
DatabaseConnection.DatabaseConnectionString = "server=" + con_txt_mysql_server.Text + ";user=" + con_txt_mysql_username.Text + ";database=" + con_txt_mysql_database.Text + ";port=" + con_txt_mysql_port.Text + ";password=" + con_txt_mysql_password.Text; DatabaseConnection.DatabaseConnectionString = "server=" + con_txt_mysql_server.Text + ";user=" + con_txt_mysql_username.Text + ";database=" + con_txt_mysql_database.Text + ";port=" + con_txt_mysql_port.Text + ";password=" + con_txt_mysql_password.Text;
// Start listening // Start listening
PerunHelper.AddLog(ref Globals.AppLogHistory, "Opening connections",0,1); PerunHelper.AddLog(ref Globals.AppLogHistory, "Opening connections", 0, 1);
TCPServer.Create(Int32.Parse(con_txt_dcs_server_port.Text), ref Globals.AppLogHistory, ref DatabaseSendBuffer); TCPServer.Create(Int32.Parse(con_txt_dcs_server_port.Text), ref Globals.AppLogHistory, ref DatabaseSendBuffer);
TCPServer.thrTCPListener = new Thread(TCPServer.StartListen); TCPServer.thrTCPListener = new Thread(TCPServer.StartListen);
TCPServer.thrTCPListener.Start(); TCPServer.thrTCPListener.Start();
@@ -197,13 +210,14 @@ namespace Perun_v1
// Send initial data // Send initial data
Tim_MySQL_Tick(null, null); Tim_MySQL_Tick(null, null);
tim_3rdparties_Tick(null, null); tim_3rdparties_Tick(null, null);
TIM_Autostart.Enabled = false;
} }
private void con_Button_Listen_OFF_Click(object sender, EventArgs e) private void con_Button_Listen_OFF_Click(object sender, EventArgs e)
{ {
// Stop listening // Stop listening
// Prepare GUI // Prepare GUI
PerunHelper.AddLog(ref Globals.AppLogHistory, "Closing connections",0,1); PerunHelper.AddLog(ref Globals.AppLogHistory, "Closing connections", 0, 1);
con_Button_Listen_OFF.Enabled = false; con_Button_Listen_OFF.Enabled = false;
Tim_GUI_Tick(null, null); Tim_GUI_Tick(null, null);
this.Refresh(); this.Refresh();
@@ -239,7 +253,7 @@ namespace Perun_v1
con_img_srs.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected"); con_img_srs.Image = (Image)Properties.Resources.ResourceManager.GetObject("status_disconnected");
// Display information about closed connections // Display information about closed connections
PerunHelper.AddLog(ref Globals.AppLogHistory, "Connections closed",0,1); PerunHelper.AddLog(ref Globals.AppLogHistory, "Connections closed", 0, 1);
Tim_GUI_Tick(null, null); Tim_GUI_Tick(null, null);
// Set title bar // Set title bar
@@ -483,9 +497,9 @@ namespace Perun_v1
// Send ping to check for possible connection issues // Send ping to check for possible connection issues
DatabaseConnection.SendToMySql("", true); DatabaseConnection.SendToMySql("", true);
if (PerunHelper.CheckVersions()==0) if (PerunHelper.CheckVersions() == 0)
{ {
MessageBox.Show("Version mismatch detected - please check log files and update.\n\nPerun will now terminate.", "Perun ERROR!",MessageBoxButtons.OK,MessageBoxIcon.Error); MessageBox.Show("Version mismatch detected - please check log files and update.\n\nPerun will now terminate.", "Perun ERROR!", MessageBoxButtons.OK, MessageBoxIcon.Error);
con_Button_Listen_OFF_Click(null, null); con_Button_Listen_OFF_Click(null, null);
} }
@@ -609,7 +623,7 @@ namespace Perun_v1
Globals.AppForceIconReload = true; Globals.AppForceIconReload = true;
// Add information // Add information
PerunHelper.AddLog(ref Globals.AppLogHistory, "Resetted error counter",0,1); PerunHelper.AddLog(ref Globals.AppLogHistory, "Resetted error counter", 0, 1);
} }
else if (dialogResult == DialogResult.No) else if (dialogResult == DialogResult.No)
{ {
@@ -621,7 +635,14 @@ namespace Perun_v1
private void con_Button_Add_Marker_Click(object sender, EventArgs e) private void con_Button_Add_Marker_Click(object sender, EventArgs e)
{ {
// Added user marker // Added user marker
PerunHelper.AddLog(ref Globals.AppLogHistory, "User Marker",0,1); PerunHelper.AddLog(ref Globals.AppLogHistory, "User Marker", 0, 1);
}
private void TIM_Autostart_Tick(object sender, EventArgs e)
{
// Handle autostart parameter from command line
TIM_Autostart.Enabled = false; // Disable timer
con_Button_Listen_ON_Click(sender,e); // Simulate button click
} }
} }
} }

View File

@@ -419,6 +419,9 @@
<metadata name="tim_MySQL.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="tim_MySQL.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>687, 19</value> <value>687, 19</value>
</metadata> </metadata>
<metadata name="TIM_Autostart.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>800, 4</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>26</value> <value>26</value>
</metadata> </metadata>

View File

@@ -31,8 +31,8 @@
<PublisherName>szporwolik</PublisherName> <PublisherName>szporwolik</PublisherName>
<SuiteName>Perun</SuiteName> <SuiteName>Perun</SuiteName>
<WebPage>Perun.htm</WebPage> <WebPage>Perun.htm</WebPage>
<ApplicationRevision>0</ApplicationRevision> <ApplicationRevision>2</ApplicationRevision>
<ApplicationVersion>0.10.0.%2a</ApplicationVersion> <ApplicationVersion>0.10.1.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust> <UseApplicationTrust>false</UseApplicationTrust>
<CreateDesktopShortcut>true</CreateDesktopShortcut> <CreateDesktopShortcut>true</CreateDesktopShortcut>
<PublishWizardCompleted>true</PublishWizardCompleted> <PublishWizardCompleted>true</PublishWizardCompleted>

View File

@@ -33,7 +33,7 @@ using System.Runtime.InteropServices;
// Możesz określić wszystkie wartości lub użyć domyślnych numerów kompilacji i poprawki // Możesz określić wszystkie wartości lub użyć domyślnych numerów kompilacji i poprawki
// przy użyciu symbolu „*”, tak jak pokazano poniżej: // przy użyciu symbolu „*”, tak jak pokazano poniżej:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.10.0.0")] [assembly: AssemblyVersion("0.10.1.0")]
[assembly: AssemblyFileVersion("0.10.0.0")] [assembly: AssemblyFileVersion("0.10.1.0")]
[assembly: NeutralResourcesLanguage("en")] [assembly: NeutralResourcesLanguage("en")]

View File

@@ -17,7 +17,7 @@ CREATE TABLE IF NOT EXISTS `pe_Config` (
) ENGINE=InnoDB DEFAULT CHARSET=utf8; ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
INSERT INTO `pe_Config` (`pe_Config_id`, `pe_Config_payload`) VALUES INSERT INTO `pe_Config` (`pe_Config_id`, `pe_Config_payload`) VALUES
(1, 'v0.10.0'); (1, 'v0.10.1');
DROP TABLE IF EXISTS `pe_DataMissionHashes`; DROP TABLE IF EXISTS `pe_DataMissionHashes`;
CREATE TABLE IF NOT EXISTS `pe_DataMissionHashes` ( CREATE TABLE IF NOT EXISTS `pe_DataMissionHashes` (

View File

@@ -0,0 +1,183 @@
<!-- This is integration example for https://github.com/szporwolik/perun - please keep the code as simple and straightforward as possible -->
<!DOCTYPE html>
<html>
<head>
<title>Perun - Example of PHP Integration</title>
<meta charset="utf-8">
<meta name="description" content="Example of PHP integration of Perun for DCS World">
<meta name="keywords" content="dcs world perun">
<meta name="author" content="VladMordock">
<style>
body {
background-color: #eeeeee;
padding: 0 20px 0 20px;
}
h1,h2,h3 {
color: navy;
}
#header{
padding: 10px 0 10px 0px;
}
#content{
border-top: 1px solid navy;
border-bottom: 1px solid navy;
padding: 10px 0 10px 0px;
}
#footer{
padding: 10px 0 10px 0px;
text-align: right;
}
table, td{
border: 1px solid navy;
}
</style>
</head>
<body>
<div id="header">
<h1>Perun Integration Example</h2>
<h2>PHP Integration example for Perun for DCS World</h2>
<h3>Get support at our <a href="https://discord.gg/MTahREx">Discord</a>
</div>
<div id="content">
<?php
// Configure database connection - put your database address and credentials here
$config_db_username="CHANGE_ME"; // <<=== CHANGE TO YOUR MYSQL SERVER USERNAME
$config_db_password="CHANGE_ME"; // <<=== CHANGE TO YOUR MYSQL SERVER PASSWORD
$config_db_host="CHANGE_ME"; // <<=== CHANGE TO YOUR MYSQL SERVER ADDRESS
$config_db_database="CHANGE_ME"; // <<=== CHANGE TO YOUR MYSQL DATABASE
// Try to connect to the database
$mysqli = new mysqli($config_db_host, $config_db_username, $config_db_password, $config_db_database);
// Check connection
if ($mysqli->connect_errno) {
printf("Connect failed: %s\n", $mysqli->connect_error);
exit();
}
// Some Examples
// List last 5 missions at the server
echo "<h3>List last 5 missions at the server</h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_DataMissionHashes` ORDER BY `pe_DataMissionHashes`.`pe_DataMissionHashes_datetime` DESC LIMIT 5")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_DataMissionHashes_id'] . "</td>";
echo "<td>" . $row['pe_DataMissionHashes_hash'] . "</td>";
echo "<td>" . $row['pe_DataMissionHashes_datetime'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// List last 5
echo "<h3>List last 5 players known server </h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_DataPlayers` ORDER BY `pe_DataPlayers`.`pe_DataPlayers_updated` DESC LIMIT 5")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_DataPlayers_id'] . "</td>";
echo "<td>" . $row['pe_DataPlayers_ucid'] . "</td>";
echo "<td>" . $row['pe_DataPlayers_lastname'] . "</td>";
echo "<td>" . $row['pe_DataPlayers_updated'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// List last 5 chat messages
echo "<h3>List last 5 chat messages (note: INNER JOIN is used to pull the player's name from other table)</h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_LogChat` INNER JOIN `pe_DataPlayers` on `pe_LogChat`.pe_LogChat_playerid = `pe_DataPlayers`.pe_DataPlayers_id ORDER BY `pe_LogChat`.`pe_LogChat_datetime` DESC LIMIT 5")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_LogChat_datetime'] . "</td>";
echo "<td>" . $row['pe_DataPlayers_lastname'] . "</td>";
echo "<td>" . $row['pe_LogChat_msg'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// List last 5 events
echo "<h3>List last 5 events</h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_LogEvent` ORDER BY `pe_LogEvent_datetime` DESC LIMIT 5")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_LogEvent_datetime'] . "</td>";
echo "<td>" . $row['pe_LogEvent_content'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// List last statistics
echo "<h3>List last statistics (note: multiple INNER JOINs is used to pull information from other table)</h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_LogStats` INNER JOIN `pe_DataMissionHashes` ON `pe_LogStats`.pe_LogStats_missionhash_id = `pe_DataMissionHashes`.pe_DataMissionHashes_id INNER JOIN `pe_DataPlayers` ON `pe_LogStats`.pe_LogStats_playerid = `pe_DataPlayers`.pe_DataPlayers_id INNER JOIN `pe_DataTypes` ON `pe_LogStats`.pe_LogStats_typeid = `pe_DataTypes`.pe_DataTypes_id ORDER BY pe_LogStats_datetime desc LIMIT 5")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_LogStats_datetime'] . "</td>";
echo "<td>" . $row['pe_DataPlayers_lastname'] . "</td>";
echo "<td>" . $row['pe_DataTypes_name'] . "</td>";
echo "<td>" . $row['ps_crashes'] . "</td>";
echo "<td>" . $row['ps_kills_planes'] . "</td>";
echo "<td>" . $row['ps_kills_armor'] . "</td>";
// TIP: See documentation there is many more counted events which can be displayed here
echo "<td>" . $row['pe_LogStats_mstatus'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// Get JSON objects with actual server information including LotATC and DCS SRS information
echo "<h3>Get JSON objects with actual server information including LotATC and DCS SRS information</h3>";
if ($result = $mysqli->query("SELECT * FROM `pe_DataRaw`")) {
echo "<table>";
while($row = mysqli_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['pe_dataraw_updated'] . "</td>";
echo "<td>" . $row['pe_dataraw_payload'] . "</td>";
echo "</tr>";
}
echo "</table>";
$result->close();
}
// Close database connection
$mysqli->close();
?>
</div>
<div id="footer">
<a href="https://github.com/szporwolik/perun">
<img src="https://camo.githubusercontent.com/50a1df184e069b36f3ddf9223bf16582f49aa16c/68747470733a2f2f692e696d6775722e636f6d2f5072496b714e412e706e67" alt="Perun_Logo">
</a>
</div>
</body>
</html>

View File

@@ -49,6 +49,7 @@ The following arguments are accepted (keep the order!):
* instance ID (shall be the same as in the lua file!) * instance ID (shall be the same as in the lua file!)
* path to SRS client-list.json * path to SRS client-list.json
* path to LotATC stats.json * path to LotATC stats.json
* numeric value (without quotes), set 1 for Autostart (Perun will start within 500ms after starting up)
Example for windows shortcut: Example for windows shortcut:
``` ```
@@ -60,6 +61,8 @@ Data displaying and handling is not in the current scope of this project. Since
![Mission statistics](https://i.imgur.com/uiRSa9e.png) ![Mission statistics](https://i.imgur.com/uiRSa9e.png)
Due to resource limitations, "Perun for DCS World" will focus on pulling the data from DCS (and external modules) and pushing it to MySQL server, but if anyone would like to develop open sourced PHP applets for data/statistics displaying we're willing to cooperate and support such projects. Unfortunetly it's not possible to share the hardcoded code from forum.gildia.org. Due to resource limitations, "Perun for DCS World" will focus on pulling the data from DCS (and external modules) and pushing it to MySQL server, but if anyone would like to develop open sourced PHP applets for data/statistics displaying we're willing to cooperate and support such projects. Unfortunetly it's not possible to share the hardcoded code from forum.gildia.org.
Basic example was provided [HERE](/04_Misc/05_PHP_Example/index.php) , support is available via Perun community at our [Discord](https://discord.gg/MTahREx).
## Troubleshooting - FAQ ## Troubleshooting - FAQ
- [I keep getting 1305 MySQL error](#i-keep-getting-1305-mysql-error) - [I keep getting 1305 MySQL error](#i-keep-getting-1305-mysql-error)
- [Carrier landing are not tracked correctly](#carrier-landing-are-not-tracked-correctly) - [Carrier landing are not tracked correctly](#carrier-landing-are-not-tracked-correctly)
@@ -84,6 +87,8 @@ DCS API does not track carrier or FARP operations natively, so there is a trick
* table: pe_LogLogins - holds login to server event history * table: pe_LogLogins - holds login to server event history
* table: pe_LogStats - holds static information * table: pe_LogStats - holds static information
![Database Scheme](https://i.imgur.com/dmJ2pIY.png "MIT")
## Data packets - send from lua to TCP port ## Data packets - send from lua to TCP port
* ```ID: 1```, contains version/diagnostic information * ```ID: 1```, contains version/diagnostic information
* perun version - for server administration usage * perun version - for server administration usage