Possible problem with roads on italy map

For bug reports and fixes, installation issues, and new ideas for technical features.

Moderator: SEOW Developers

DD_Friar
Posts: 93
Joined: Fri 07 Sep 2007 9:57 am
Location: Croydon, England
Contact:

Possible problem with roads on italy map

Post by DD_Friar »

Hi,

We are experiencing problems with moving vehicles on some of the roads around the Monte Cassino area.
It may be that, as we have found some errors with airfields on the map that there are a few bugs with the road network as well.

From what I understand of the seow database, each road is mapped with a co-ordinate at a change of direction, is this correct?

I am willing to check the routes out if someone could point me in the right direction to the tables concerned.

My plan would be to plot a vehicle movement in the game fmb and then compare that to the database.

Would that be the right way to go about it?

If not perhaps a way of checking the database could be suggested

Cheers
DD_Friar
IV/JG7_4Shades
Posts: 2211
Joined: Mon 08 Jan 2007 11:10 pm
Location: Perth, Western Australia

Post by IV/JG7_4Shades »

Hi Frior (or is it Friar?),

Each SEOW Map in the MP consists of a folder with a stack of .php files in it. Most of these files have the following general contents format:

Code: Select all

<?php
  session_start();

// asp2php (vbscript) converted

//If the session variable is False or does not exist then redirect the user to the unauthorised user page
if ($_SESSION["CommanderGood_session"] != true) {
		header("Location: ../Scripts/default.php");
}

//Set page specific variables
// Sector B Italy.
$CampaignMap="Italy";
$pageTitle="Scorched Earth Mission HQ"; //Title bar text
$pageName="Italy - District B"; //Title in top left corner of page
$GeographicMapImage="Italy_District_B.jpg"; //Bitmap of geographic area
$maxpX=1024; //Size of map image in pixels in x direction
$mincX=0; //Min longitude of image in FB coords
$maxcX=159999; //Max longitude of image in FB coords
$maxpY=729; //Size of map image in pixels in y direction
$mincY=300; //Max latitude of image in FB coords
$maxcY=114000; //Min latitude of image in FB coords
$mapOffsetX=0.0; //FB longitude offset of map origin
$mapdivoffsetX=250; //Pixel offset of left edge of map image DIV 
$mapOffsetY=0.0; //FB latitude offset of map origin
$mapdivoffsetY=0; //Pixel offset of top edge of map image DIV 
$ShowRoads=false; //Turns on display of pre-defined road routes
$ShowRoadWP=false; //Turns on display of pre-defined road route waypoints
$ShowRailways=false; //Turns on display of pre-defined rail routes
$ShowRailwayWP=false; //Turns on display of pre-defined rail route waypoints

include '../Scripts/MP-BuildPage.php';

?>
Down near the end you will see some variables called $ShowRoads and $ShowRoadWP, both set to false in this example. If you edit these files and change these values to true and refresh the corresponding MP page, you will see the road drawn in place over the map. Mousing over the orange dots along the roads will show you the corresponding route number and X-Y coordinates, as read by the MP from the Highways table of the database. The Highways table contains all the road information. The Highway_Intersections table is derived from the Highways table. Route numbers are allocated for each stretch of road between two intersections.

It would be great if you could check out the Italy highways.

Cheers,
4Shades
IV/JG7_4Shades
SEOW Developer

Image
DD_Friar
Posts: 93
Joined: Fri 07 Sep 2007 9:57 am
Location: Croydon, England
Contact:

Post by DD_Friar »

Ok, I will see what I can do.

As to the name....When I first joined the dogz (www.dangerdogz.com) I made the schoolboy mistake of spelling it Frior, after quite a long time I decided to corrct this error and changed it to Friar. So thats what i am called now, although on TS on a good night with the dogz, I answer to a lot worse!
JAGD_RC
Posts: 27
Joined: Sun 14 Jan 2007 10:38 pm

Post by JAGD_RC »

Frior

I pm'd you a link to the original capture data I used for that sector. Hopefully that helps you. Let me know if there's more italy info you need, I think I still have everything.

I will look for the mission file so you can see what I did. I know there was an issue with some of the airfields. They were part of the new airfields included in a 1C patch but were not yet supported by SEOW. So I used the closest airfields I could find.

RC
JAGD_RC
Posts: 27
Joined: Sun 14 Jan 2007 10:38 pm

Post by JAGD_RC »

Ok, I did have the orignal .mis file and added to that .zip, same link will get it for you.

RC
doubletap
Posts: 16
Joined: Mon 16 Apr 2007 4:26 pm

Italy Moves

Post by doubletap »

I did not see this before posting on another thread about this very issue.

If we were to change the DB to show this on the SEOW map, would it impact anything with the ongoing campaign?

I would be more than willing to try and discover which routes are "broken".

Doubletap
IV/JG7_4Shades
Posts: 2211
Joined: Mon 08 Jan 2007 11:10 pm
Location: Perth, Western Australia

Post by IV/JG7_4Shades »

You can substitute new Highways and Highway_Intersections tables during a campaign without breaking anything. Just for info, I will post later the SQL query that generates the Highway_Intersections table from the Highways table, so people can see the changes from modifying the Highways table themselves.

Cheers,
4Shades
IV/JG7_4Shades
SEOW Developer

Image
EJGr.Ost_Chamel
Posts: 56
Joined: Sun 14 Jan 2007 11:37 pm
Location: Germany
Contact:

Post by EJGr.Ost_Chamel »

We have been facing problems with routes on the Italy map too. So I have redone the highways and now I have generated a highway_intersections table with the help of a spreadsheet. But as I would like to double check the results, could you , 4Shades, please post the announced sql query for automatically generating the intersections from the highways table?

Thanks in advance for this and even more for all your work for SEOW!!

Chamel
IV/JG7_4Shades
Posts: 2211
Joined: Mon 08 Jan 2007 11:10 pm
Location: Perth, Western Australia

Post by IV/JG7_4Shades »

Hi Chamel,

Here it is:

Code: Select all

drop table if exists Highway_Intersections;
CREATE TABLE `Highway_Intersections` (
`Map` varchar(50) default NULL,
`Intersection_X_Axis` int(11) default NULL,
`Intersection_Y_Axis` int(11) default NULL,
`Route` int(11) default NULL,
`Waypoint_Number` int(11) default NULL
) TYPE=InnoDB;
INSERT INTO Highway_Intersections SELECT DISTINCT * FROM (SELECT Map, X_Axis as Intersection_X_Axis, Y_Axis AS Intersection_Y_Axis, Route, Waypoint_Number FROM Highways, (SELECT Map AS Junction_Map, X_Axis AS Junction_X_Axis, Y_Axis AS Junction_Y_Axis, COUNT(Route) AS Exits FROM Highways GROUP BY CONCAT(Map,'^',X_Axis,'^',Y_Axis) HAVING COUNT(Route)>1) AS Junctions WHERE Map=Junctions.Junction_Map AND X_Axis=Junctions.Junction_X_Axis AND Y_Axis=Junction_Y_Axis ORDER BY X_Axis, Y_Axis, Route) AS Table_With_Dups;

And here is the corresponding query for railways:

Code: Select all

drop table if exists Railway_Intersections;
CREATE TABLE `Railway_Intersections` (
`Map` varchar(50) default NULL,
`Intersection_X_Axis` int(11) default NULL,
`Intersection_Y_Axis` int(11) default NULL,
`Route` int(11) default NULL,
`Waypoint_Number` int(11) default NULL
) TYPE=InnoDB;
INSERT INTO Railway_Intersections SELECT DISTINCT * FROM (SELECT Map, X_Axis as Intersection_X_Axis, Y_Axis AS Intersection_Y_Axis, Route, Waypoint_Number FROM Railway_Waypoints, (SELECT Map AS Junction_Map, X_Axis AS Junction_X_Axis, Y_Axis AS Junction_Y_Axis, COUNT(Route) AS Exits FROM Railway_Waypoints GROUP BY CONCAT(Map,'^',X_Axis,'^',Y_Axis) HAVING COUNT(Route)>1) AS Junctions WHERE Map=Junctions.Junction_Map AND X_Axis=Junctions.Junction_X_Axis AND Y_Axis=Junction_Y_Axis ORDER BY X_Axis, Y_Axis, Route) AS Table_With_Dups;
Cheers,
4Shades
IV/JG7_4Shades
SEOW Developer

Image
EJGr.Ost_Chamel
Posts: 56
Joined: Sun 14 Jan 2007 11:37 pm
Location: Germany
Contact:

Post by EJGr.Ost_Chamel »

My reworked tables for the Highways and Highway_Intersections on the Italy map are ready. I have just sent them to 4shades for possible inclusion into the next SEOW version/update.
If anyone here is actually flying a campaign on the Italy map and wants to have the data, PM me your mail address.

Greetings
Chamel
EJGr.Ost_Chamel
Posts: 56
Joined: Sun 14 Jan 2007 11:37 pm
Location: Germany
Contact:

Post by EJGr.Ost_Chamel »

@4Shades (or anyone else with solid SQL-knowledge):
Is there a script to extract the Bridges data from the Highways / Railway_Waypoints tables? Would be kind to post it here ... if exists! :wink:

Greetings
Chamel
Goanna
Posts: 49
Joined: Wed 10 Jan 2007 1:49 am
Location: Ingham

Post by Goanna »

Hi Chamel,
All the bridge data in those two tables have a negative orientation figure so you could use these sql statements to extract;

SELECT * FROM `highways` WHERE `Orientation` <0
SELECT * FROM `railway_waypoints` WHERE `Orientation` <0

Cheers

Goanna
IV/JG7_4Shades
Posts: 2211
Joined: Mon 08 Jan 2007 11:10 pm
Location: Perth, Western Australia

Post by IV/JG7_4Shades »

Cheers Goanna.

Chamel, the negative orientation value maps into the BridgeID according to the following formula:

Code: Select all

BridgeID = -Orientation - 1
So if bridge orientation = -23 then BridgeID = 22.

You will notice that each negative orientation in Highways or Railway_Waypoints occurs twice (two records). These two records give the start and end coordinates of the bridge. In the Bridges table, the bridges are located by midpoint.

Cheers,
4Shades
IV/JG7_4Shades
SEOW Developer

Image
PA-Dore
Posts: 469
Joined: Thu 01 Nov 2007 8:58 am
Location: Savoie-France
Contact:

Post by PA-Dore »

SEOW_Routes_Tool is a easy way for:
- Highways
- Railways
- Bridges

Then use 4Shades sql request for Highways&Railways_Intersections
EJGr.Ost_Chamel
Posts: 56
Joined: Sun 14 Jan 2007 11:37 pm
Location: Germany
Contact:

Bridges table for Iasi incorrect?

Post by EJGr.Ost_Chamel »

Hi Dore + others,

I first tried to find a way to get waypoint and bridges data without the SEOW_Routes_Tool because I currently have no Excel installed on my home PC. OpenOffice-Calc can open the Tool-file, but doesn't unerstand the macros.
But now I mistrust the Routes-Tool, because I think that the current bridges data for the Iasi map in the SEDB32E are not correct!
Some quick examples (all from Iasi map):
  • In the DB there are 90 railway bridges while I can only find 46
  • In the DB there are railway bridges at 14900/269900 (x/y) and at 15300/218500 . But in the Iasi map there is only a railway line at these points without any bridge!
  • The Obj_Names/Bridge_IDs in the DB completely differ from my results! For example in the DB the bridge at 15700/155100 has the name/ID 19 while I think it has to be 4
Maybe I am doing something terribly wrong here - but I don't think so as have checked all my results carefully. So could you - Dore - please check the results that you have apparently determined with the help of the Routes_Tool? I think something is wrong here.

Thanks in advance
Chamel
Last edited by EJGr.Ost_Chamel on Tue 26 Jan 2010 7:33 pm, edited 2 times in total.
Post Reply