Map does not show places visited.

Where we find trouble with the latest release... and shoot it.

usalabs
Posts: 26
Joined: Tue May 19, 2020 13:29 UTC

Map does not show places visited.

Post by usalabs » Fri May 22, 2020 07:40 UTC

Testing the game I visited all sectors sequentially from 0 to current 217 and looking at the map, it only shows sector 0 as showing a special port icon.

I just traveled to sector 219 and the main page shows an energy trading port, but looking at the map, shows nothing but a lot of boxes with ? and showing sector 0

This is the video screenshot of moving to sector 220 and showing a Goods trading port, but nothing on the map.

https://www.dropbox.com/s/7ntj82wvaimwl ... p.mp4?dl=0

User avatar
TheMightyDude
Site Admin
Posts: 294
Joined: Thu Apr 17, 2014 09:15 UTC

Re: Map does not show places visited.

Post by TheMightyDude » Sat May 23, 2020 10:43 UTC

Hmm, that is strange, due to its working fine for me on that code.

Check your database to see if its adding records to the movment_log table.
TheMightyDude::Blacknova Development.
Development Blog Twitter Twitch

usalabs
Posts: 26
Joined: Tue May 19, 2020 13:29 UTC

Re: Map does not show places visited.

Post by usalabs » Sat May 23, 2020 21:35 UTC

TheMightyDude wrote:
Sat May 23, 2020 10:43 UTC
Hmm, that is strange, due to its working fine for me on that code.

Check your database to see if its adding records to the movment_log table.
The table has 400 rows and the records show:-

event_id shows a sequential list
ship_id shows rows of 1
sector_id shows rows and rows of sector numbers
and time shows the time stamp for each row.

ADDENDUM
Instead if creating a new thread for this one, I'll add it here being as we're sorting out errors.

If a wrong password is given this is the result:-

Code: Select all

Notice: Undefined variable: l_login_title2 in /var/www/bnt/login2.php on line 70

Notice: Undefined variable: l_login_4gotpw1a in /var/www/bnt/login2.php on line 151

Notice: Undefined variable: l_login_4gotpw1b in /var/www/bnt/login2.php on line 151

Notice: Undefined variable: l_login_4gotpw2a in /var/www/bnt/login2.php on line 151

Notice: Undefined variable: l_login_4gotpw2b in /var/www/bnt/login2.php on line 151

Notice: Undefined variable: l_login_4gotpw3 in /var/www/bnt/login2.php on line 151

User avatar
TheMightyDude
Site Admin
Posts: 294
Joined: Thu Apr 17, 2014 09:15 UTC

Re: Map does not show places visited.

Post by TheMightyDude » Sun May 24, 2020 02:56 UTC

Ok, for the first issue, for the records in movement_log does their ship_id the ship_id in the ships table?
If so it seems like there might be an issue in maps.php or a caching issue.

The second issue could be one of 2 issues.
1: the Create Universe had an error or didn't complete.
2: the language for login2.php are not loading in the required variables.

Both are strange due to I have absolutely no issues what so ever, but I will try and look into it.
TheMightyDude::Blacknova Development.
Development Blog Twitter Twitch

usalabs
Posts: 26
Joined: Tue May 19, 2020 13:29 UTC

Re: Map does not show places visited.

Post by usalabs » Sun May 24, 2020 09:50 UTC

TheMightyDude wrote:
Sun May 24, 2020 02:56 UTC
Ok, for the first issue, for the records in movement_log does their ship_id the ship_id in the ships table?
If so it seems like there might be an issue in maps.php or a caching issue.

The second issue could be one of 2 issues.
1: the Create Universe had an error or didn't complete.
2: the language for login2.php are not loading in the required variables.

Both are strange due to I have absolutely no issues what so ever, but I will try and look into it.
OK, bnt_ships table, record ship_id does tally with the record ship_id in table bnt_movement_log

I just made a movement to sector 990 and examined the table movement_log, and event_id = 407, ship_id = 1 (my ship), sector_id = 990, and time shows current date and time I made the move. but nothing shows on the map.

I'm using Chrome with a lot of anti adware extensions, but just in case it might be a browser issue, I tried it in Edge, Firefox and Opera all with no extensions and have the same result with the map.

I have just had this zany idea, what if there's a PHP module that should be installed, but your scripts are not checking that it's there and tries to make a call to it, and with display_errors = Off nothing will show? (I did try with display_errors = On, same result), so listed below are all the modules that are installed in PHP v7.2

Code: Select all

[PHP Modules]

I set the PHP error logging to :- E_ALL & ~E_DEPRECATED & ~E_STRICT and boy this is what I get on the map page, around 12 pages of:-

Notice: Undefined variable: l_unknown in /var/www/bnt/galaxy.php on line 91
bcmath
calendar
Core
ctype
curl
date
dom
exif
fileinfo
filter
ftp
gd
gettext
hash
iconv
json
libxml
mbstring
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
sodium
SPL
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zlib

[Zend Modules]
Zend OPcache
I set the PHP error logging to E_ALL & ~E_DEPRECATED & ~E_STRICT and boy this is what I saw on the map page, around 12 pages of:-

Notice: Undefined variable: l_unknown in /var/www/bnt/galaxy.php on line 91

and this is at the bottom of all those pages:-

Code: Select all

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 108
: Special Port <- Special Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 109
: Ore Port <- Ore Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 110
: Organics Port <- Organics Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 111
: Energy Port <- Energy Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 112
: Goods Port <- Goods Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 113
: No Port <- No Port

Notice: Undefined variable: l_port in /var/www/bnt/galaxy.php on line 114
: Unexplored <- Unexplored
Also at the top of the map page is:-

Warning: mysqli_free_result(): Couldn't fetch mysqli_result in /var/www/bnt/backends/adodb/drivers/adodb-mysqli.inc.php on line 1066

Then at the top of the main page is:-

Notice: Undefined variable: l_zname_1 in /var/www/bnt/main.php on line 176

Also with PHP error logging set and display_error = On, there's a lot of undefined variables showing on every page.

OK, I give up, (throws computer in the trash lol), all these errors did show, but when I moved the current bnt installation to a new folder '/var/www/bnt-test' then installed the older version v0.663 (no b) in the bnt folder but using the same DB, but PHP switched to 5.6, set an Apache doc alies to point to it, then I switch PHP back to 7.2 and ran the v0.663b code from a different folder, but mind you, I did set the entire folder and its contents to world writable (0777) and now it all seems to work fine, the map shows all the places that's been visited.
Last edited by usalabs on Sun May 24, 2020 11:24 UTC, edited 1 time in total.

User avatar
TheMightyDude
Site Admin
Posts: 294
Joined: Thu Apr 17, 2014 09:15 UTC

Re: Map does not show places visited.

Post by TheMightyDude » Sun May 24, 2020 11:18 UTC

Ok, so we know its adding them into the database, but I have no clue why you are getting that the variables starting with l_ are language variables are missing.
I would check your database to see if those undefined variables starting with l_ are in your languages table, there should be 1 for each language.

Its all working fine when I run it on a virtual machine.

I do get the odd Warning: mysqli_free_result(): Couldn't fetch mysqli_result but a refresh of the page fixes that.
TheMightyDude::Blacknova Development.
Development Blog Twitter Twitch

usalabs
Posts: 26
Joined: Tue May 19, 2020 13:29 UTC

Re: Map does not show places visited.

Post by usalabs » Sun May 24, 2020 11:32 UTC

TheMightyDude wrote:
Sun May 24, 2020 11:18 UTC
Ok, so we know its adding them into the database, but I have no clue why you are getting that the variables starting with l_ are language variables are missing.
I would check your database to see if those undefined variables starting with l_ are in your languages table, there should be 1 for each language.

Its all working fine when I run it on a virtual machine.

I do get the odd Warning: mysqli_free_result(): Couldn't fetch mysqli_result but a refresh of the page fixes that.
I checked the language table and yes there are 4 l_unknown fields, and 28 rows of l_port.

That's why I said in my previous post addendum, "I give up", one minute there's errors, the next nothing, then errors, then nothing, personally, I think the only way to really test things like this is to have a laptop, and completely reformat it every time a test is made, then it's assured that everything is clean lol

User avatar
TheMightyDude
Site Admin
Posts: 294
Joined: Thu Apr 17, 2014 09:15 UTC

Re: Map does not show places visited.

Post by TheMightyDude » Sun May 24, 2020 11:48 UTC

LOL, well it has baffled me, I know I don't use that for our live versions, I run a heavy modified / hacked version of it set to work on our live server.

If you know SVN you could try the latest code version, but its not been updated since 2014.
https://sourceforge.net/p/blacknova/cod ... /original/
There are still loads of errors due to it was stopped in mid update, so you WILL run into to issues with that too.
I haven't tested that version so I have no idea what state it is at, due to I haven't committed changes for a while.

ERM, 28 rows of l_port ??? there should only be 4 of them.

I would try emptying the database (i.e. a database with no tables) and then re-create the universe with create_universe.php , I am not saying that will fix it, but you shouldn't have more than 4 rows of each language variable.

This is why I really hate this very old code :(
TheMightyDude::Blacknova Development.
Development Blog Twitter Twitch

usalabs
Posts: 26
Joined: Tue May 19, 2020 13:29 UTC

Re: Map does not show places visited.

Post by usalabs » Sun May 24, 2020 12:17 UTC

TheMightyDude wrote:
Sun May 24, 2020 11:48 UTC
LOL, well it has baffled me, I know I don't use that for our live versions, I run a heavy modified / hacked version of it set to work on our live server.

If you know SVN you could try the latest code version, but its not been updated since 2014.
https://sourceforge.net/p/blacknova/cod ... /original/
There are still loads of errors due to it was stopped in mid update, so you WILL run into to issues with that too.

ERM, 28 rows of l_port ??? there should only be 4 of them.

I would try emptying the database (i.e. a database with no tables) and then re-create the universe with create_universe.php , I am not saying that will fix it, but you shouldn't have more than 4 rows of each language variable.

This is why I really hate this very old code :(
l_port on it's own there is only 4, but there's l_port_bounty, l_port_bounty2, etc etc

Has this version 0663 been dropped entirely? Or will be a version close to what you use live?
Last edited by usalabs on Sun May 24, 2020 12:20 UTC, edited 1 time in total.

User avatar
TheMightyDude
Site Admin
Posts: 294
Joined: Thu Apr 17, 2014 09:15 UTC

Re: Map does not show places visited.

Post by TheMightyDude » Sun May 24, 2020 12:19 UTC

Ah, I get yah now, I was going to say LOL.
TheMightyDude::Blacknova Development.
Development Blog Twitter Twitch

Post Reply