Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Georgios Dagkakis
erp5
Commits
715a2c20
Commit
715a2c20
authored
Jul 27, 2023
by
Roque
Browse files
Options
Browse Files
Download
Plain Diff
erp5_officejs_drone_simulator: changes to make "test drone flight" work
See merge request
nexedi/erp5!1804
parents
4174385c
93ddab76
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
23 additions
and
8 deletions
+23
-8
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/drone_simulator_logic_js.js
...hTemplateItem/web_page_module/drone_simulator_logic_js.js
+16
-1
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/drone_simulator_logic_js.xml
...TemplateItem/web_page_module/drone_simulator_logic_js.xml
+2
-2
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/ojs_drone_simulator_script_page_js.js
...tem/web_page_module/ojs_drone_simulator_script_page_js.js
+3
-3
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/ojs_drone_simulator_script_page_js.xml
...em/web_page_module/ojs_drone_simulator_script_page_js.xml
+2
-2
No files found.
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/drone_simulator_logic_js.js
View file @
715a2c20
...
@@ -3,6 +3,8 @@
...
@@ -3,6 +3,8 @@
unparam: true */
unparam: true */
var
GAMEPARAMETERS
=
{};
var
GAMEPARAMETERS
=
{};
//for DEBUG/TEST mode
var
baseLogFunction
=
console
.
log
,
console_log
=
""
;
/******************************* DRONE MANAGER ********************************/
/******************************* DRONE MANAGER ********************************/
var
DroneManager
=
/** @class */
(
function
()
{
var
DroneManager
=
/** @class */
(
function
()
{
...
@@ -549,6 +551,15 @@ var GameManager = /** @class */ (function () {
...
@@ -549,6 +551,15 @@ var GameManager = /** @class */ (function () {
FixedWingDroneAPI
:
FixedWingDroneAPI
,
FixedWingDroneAPI
:
FixedWingDroneAPI
,
DroneLogAPI
:
DroneLogAPI
DroneLogAPI
:
DroneLogAPI
};
};
if
(
this
.
_game_parameters_json
.
debug_test_mode
)
{
console
.
log
=
function
()
{
baseLogFunction
.
apply
(
console
,
arguments
);
var
args
=
Array
.
prototype
.
slice
.
call
(
arguments
);
for
(
var
i
=
0
;
i
<
args
.
length
;
i
++
)
{
console_log
+=
args
[
i
]
+
"
\n
"
;
}
};
}
}
}
Object
.
defineProperty
(
GameManager
.
prototype
,
"
gameParameter
"
,
{
Object
.
defineProperty
(
GameManager
.
prototype
,
"
gameParameter
"
,
{
...
@@ -563,7 +574,11 @@ var GameManager = /** @class */ (function () {
...
@@ -563,7 +574,11 @@ var GameManager = /** @class */ (function () {
var
gadget
=
this
;
var
gadget
=
this
;
return
gadget
.
_init
()
return
gadget
.
_init
()
.
push
(
function
()
{
.
push
(
function
()
{
return
gadget
.
_flight_log
;
return
{
'
message
'
:
gadget
.
_result_message
,
'
content
'
:
gadget
.
_flight_log
,
'
console_log
'
:
console_log
};
});
});
};
};
...
...
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/drone_simulator_logic_js.xml
View file @
715a2c20
...
@@ -240,7 +240,7 @@
...
@@ -240,7 +240,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
10
09.36979.45339.6075
</string>
</value>
<value>
<string>
10
10.3592.54606.53538
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -260,7 +260,7 @@
...
@@ -260,7 +260,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
88635184.98
</float>
<float>
16
90478004.4
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/ojs_drone_simulator_script_page_js.js
View file @
715a2c20
...
@@ -555,9 +555,9 @@
...
@@ -555,9 +555,9 @@
.
push
(
function
(
result
)
{
.
push
(
function
(
result
)
{
var
a
,
blob
,
div
,
key
,
log
,
log_content
;
var
a
,
blob
,
div
,
key
,
log
,
log_content
;
i
=
0
;
i
=
0
;
for
(
key
in
result
)
{
for
(
key
in
result
.
content
)
{
if
(
result
.
hasOwnProperty
(
key
))
{
if
(
result
.
content
.
hasOwnProperty
(
key
))
{
log_content
=
result
[
key
].
join
(
'
\n
'
).
replaceAll
(
"
,
"
,
"
;
"
);
log_content
=
result
.
content
[
key
].
join
(
'
\n
'
).
replaceAll
(
"
,
"
,
"
;
"
);
blob
=
new
Blob
([
log_content
],
{
type
:
'
text/plain
'
});
blob
=
new
Blob
([
log_content
],
{
type
:
'
text/plain
'
});
a
=
domsugar
(
'
a
'
,
{
a
=
domsugar
(
'
a
'
,
{
text
:
'
Download Simulation LOG
'
+
i
,
text
:
'
Download Simulation LOG
'
+
i
,
...
...
bt5/erp5_officejs_drone_simulator/PathTemplateItem/web_page_module/ojs_drone_simulator_script_page_js.xml
View file @
715a2c20
...
@@ -246,7 +246,7 @@
...
@@ -246,7 +246,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
1009.
22574.47206.13909
</string>
</value>
<value>
<string>
1009.
59163.16294.47701
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -266,7 +266,7 @@
...
@@ -266,7 +266,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
16
87785962.67
</float>
<float>
16
90477710.21
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment