Skip to content
This repository has been archived by the owner on Nov 24, 2021. It is now read-only.

MissionCaseDestruction Error #181

Closed
Jbaukens opened this issue May 19, 2016 · 6 comments
Closed

MissionCaseDestruction Error #181

Jbaukens opened this issue May 19, 2016 · 6 comments

Comments

@Jbaukens
Copy link
Contributor

Jbaukens commented May 19, 2016

Hello jan, another error that happen sometimes in the main pack is this one

[19-May-2016 21:28:54] NOTICE: "Undefined index: universe"
File: /home/xterium/public_html/includes/classes/class.PlanetRessUpdate.php | Line: 188
URL: http://xterium.space/game.php?page=galaxy | Version: 1.7.git
USERID:
Stack trace:
#0 /includes/classes/class.PlanetRessUpdate.php(188): errorHandler(8, 'Undefined index...', '/home/xterium/p...', 188, Array)
#1 /includes/classes/missions/MissionCaseDestruction.class.php(93): ResourceUpdate->CalcResource(Array, false, true, '1463623685')
#2 /includes/classes/class.FlyingFleetHandler.php(93): MissionCaseDestruction->TargetEvent()
#3 /includes/FleetHandler.php(42): FlyingFleetHandler->run()
#4 /includes/common.php(138): require('/home/xterium/p...')
#5 /game.php(35): require('/home/xterium/p...')
#6 {main}

188 is for me that line
$this->config = Config::get($this->USER['universe']);

I tried some stuf f to fix it but nothing change, it does not reconize the user since even my USERID errorinfo is empty, and when i check the code all looks correct as you use a global query that select * from what it need so universe should be included, also when i try to hard fix it changed in planetresupdate the query of universe to 1 since i only have one universe so it wil allways be 1, then i get a next error saying undefined index urlaubs_modus, so there should be a small problem with something in that
i still try to look if i manage to fix it i will post a PR

@jkroepke
Copy link
Owner

$this->USER does (and should not used)not exist on the missions context,

You should use $this->_fleet['fleet_universe']

@jkroepke
Copy link
Owner

jkroepke commented May 19, 2016

i still try to look if i manage to fix it i will post a PR

It is not an 2Moons error, because $this->USER['universe'] does not exist in mission code on upstream source.

@Jbaukens
Copy link
Contributor Author

Jbaukens commented May 19, 2016

Hello you closed my issue without reading all of it
the code i shared you is from planet res update that does part of your main code nothing to do with the missioncasedestruction
Thats the mission line that cause the error

list($targetUser, $targetPlanet) = $planetUpdater->CalcResource($targetUser, $targetPlanet, true, $this->_fleet['fleet_start_time']);

i would not have posted it here if it was an error of my own code

Regards

@jkroepke jkroepke reopened this May 20, 2016
@jkroepke
Copy link
Owner

Sorry, my fault.

I will try to look into this.

@Jbaukens
Copy link
Contributor Author

Jbaukens commented May 23, 2016

Hello depending on my flying fleets, it only happen where no more moon is present because it has been destroyed in case it can help you and this is my var_dump error on the line 188

[23-May-2016 16:18:19] USER ERROR: "Unknown universe id: "
File: /home/xterium/public_html/includes/classes/Config.class.php | Line: 76
URL: http://xterium.space/game.php?page=messages | Version: 1.7.git
USERID: Patounet
Stack trace:
#0 /includes/classes/class.PlanetRessUpdate.php(188): Config::get(NULL)
#1 /includes/pages/game/AbstractGamePage.class.php(53): ResourceUpdate->CalcResource()
#2 /includes/pages/game/ShowMessagesPage.class.php(35): AbstractGamePage->__construct()
#3 /game.php(63): ShowMessagesPage->__construct()
#4 {main}

Regards

@Jbaukens
Copy link
Contributor Author

ok i got more information about the error
this happen only when you send multiple waves
if one of them destroy the moon, it continue to send on moon but it doesnt exist so no information to send i guess ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants