Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HR and Help refugees task: Less HR is given and the overall HR changes after save #154

Open
Warhammer47 opened this issue Nov 8, 2017 · 4 comments

Comments

@Warhammer47
Copy link
Collaborator

Version: develop
Mods: ACE
Mode: MP

Looks like some bug exists between the task "Help refugees" and the HR given after the mission.
After completing the mission not only received less HR for the ppl I saved (8 instead of 10 even though it appeared "HR: +10" in the FIA resources update).
After saving and loading the game, the HR level goes back to the previous number and the task sometimes appears/initializes like it wasn't completed.

CODE:
1:41:01 Error in expression <ssionSuccessfulCondition = {
(not alive _veh) or ({_x getVariable ["BLUFORSpawn">
1:41:01 Error position: <_veh) or ({_x getVariable ["BLUFORSpawn">
1:41:01 Error Undefined variable in expression: _veh
1:41:01 File mission\spawns\fnc_destroy_vehicle.sqf [AS_mission_fnc_destroy_vehicle], line 103
1:41:01 "[AS] Error: AS_mission_fnc_complete: mission 'rescue_refugees_lifou' is not active"
1:41:01 "[AS] 2: spawn 'rescue_refugees_lifou' finished state 'clean'"
1:41:03 Error in expression <able [_variable,false] and {_x distance _reference < _distance}}
} else {
privat>
1:41:03 Error position: <_reference < _distance}}
} else {
privat>
1:41:03 Error Undefined variable in expression: _reference
1:41:03 File fnc_unitsAtDistance.sqf [AS_fnc_unitsAtDistance], line 12
1:41:03 Error in expression <able [_variable,false] and {_x distance _reference < _distance}}
} else {
privat>

@LordGolias LordGolias added the bug label Nov 9, 2017
@Warhammer47
Copy link
Collaborator Author

More code about it:

2:51:21 "[AS] 2: spawn 'rescue_refugees_lobaka' finished state 'run'"
2:51:21 "[AS] 2: spawn 'rescue_refugees_lobaka' started state 'clean'"
2:51:22 soldier[I_Soldier_LAT_F]:Some of magazines weren't stored in soldier Vest or Uniform?
2:51:22 soldier[I_Soldier_LAT_F]:Some of magazines weren't stored in soldier Vest or Uniform?
2:51:22 "DICT:get([1675967: empty.p3d,""rescue_refugees_lobaka"",""location""]):ERROR: invalid key"
2:51:22 "DICT:get([1675967: empty.p3d,""rescue_refugees_lobaka"",""type""]):ERROR: invalid key"

@LordGolias
Copy link
Owner

I am not able to reproduce this in SP:

  1. start a new game
  2. start mission rescue refugees in Neri
  3. go there, pick all the refugees
  4. drive to the HQ
  5. save game
  6. load game

the relevant log is

 6:43:54 "[AS] 0: new spawn 'rescue_refugees_neri'"
 6:43:54 "[AS] Server: scheduler_fnc_execute(AS_spawn_fnc_execute):"
 6:43:54 "[AS] 0: spawn 'rescue_refugees_neri' started state 'initialize'"
 6:43:54 "[AS] 0: spawn 'rescue_refugees_neri' finished state 'initialize'"
 6:43:54 "[AS] 0: spawn 'rescue_refugees_neri' started state 'spawn'"
 6:43:54 "[AS] 0: spawn 'rescue_refugees_neri' finished state 'spawn'"
 6:43:54 "[AS] 0: spawn 'rescue_refugees_neri' started state 'run'"
 6:49:00 "[AS] 0: spawn 'rescue_refugees_neri' finished state 'run'"
 6:49:00 "[AS] 0: spawn 'rescue_refugees_neri' started state 'clean'"
 6:49:29 "[AS] 0: spawn 'rescue_refugees_neri' finished state 'clean'"
 6:51:15 "[AS] Server: saving game..."
 6:51:15 "[AS] Server: serializing game..."
 6:51:15 "[AS] Server: serializing AAF arsenal..."
 6:51:15 "[AS] Server: serializing locations..."
 6:51:20 "[AS] Server: serializing fia_hq..."
 6:51:20 "[AS] Server: serializing FIA arsenal..."
 6:51:21 "[AS] Server: serializing persistents..."
 6:51:24 "[AS] Server: serializing missions..."
 6:51:24 "[AS] Server: serializing players..."
 6:51:26 "[AS] Server: serialization completed."
 6:51:26 "[AS] Server: game saved."

// after restart
 6:51:57 "[AS] Server: deserializing data..."
 6:52:04 "[AS] Server: migrating to latest save version..."
 6:52:04 "[AS] Server: loading persistents..."
 6:52:04 "[AS] Server: loading locations..."
 6:52:05 "[AS] Server: server side-variables initialized"
 6:52:05 "[AS] Server: waiting for HQ position..."
 6:52:05 "[AS] Client: waiting for commander to choose HQ location..."
 6:52:10 "[AS] Server: loading HQ..."
 6:52:10 "[AS] Server: loading FIA arsenal..."
 6:52:10 "[AS] Server: loading players..."
 6:52:10 "[AS] Server: loading AAF arsenal..."
 6:52:10 "[AS] Server: spawn loop started."
 6:52:10 "[AS] Server: resources loop started."
 6:52:10 "[AS] Server: loading missions..."

Isn't the HR reaching its maximum value (16 for level 0) because of the FIA skill restriction?

@Warhammer47
Copy link
Collaborator Author

Maybe it's that, but the thing is after surpassing the level it might remove all the last increment of HR, can you check that?
E.g. I have 10 HR, I receive 9 the level raises to 19 but then returns to 10
Either way I'm gonna post in investigation

@Kortonki
Copy link

In the scripts which update the HR, FIA resousces etc. is line which compares current HR to maximum HR vie BE module. However the BE module returns the difference from current HR to max HR while the script calling it uses it like it's the absolute max HR allowed.

Creates strange outcomes indeed! But it's a quick fix

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

No branches or pull requests

3 participants