SRL Archive - MSI Bugs

MSI_GetReportInfo


Shuttleu

2010-07-22 14:35:19

while testing out the form which i made earlier today i noticed that the activity isnt updating in the report
i think it should be changed to


procedure MSI_GetReportInfo;
var
skill, i: Integer;
begin
for i:=0 to (HowManyPlayers-1) do
with ProgressReportArray[i] do
begin
if (i=CurrentPlayer) then
begin
skill := MSI_Scripts[MSI_Players[i].Scripts[CurrentScript]].SkillConstant;
ScriptInfo[i].PlayerSkillLevel := GetSkillLevel(skill);
end;

PlayerLoc := MSI_Players[i].Location;
PlayerStatus := MSI_Players[i].Active;
end;
end;

~shut

Sir R. M8gic1an

2010-07-22 16:18:09

Waste of time:

level := GetSkillLevel(skill);
if (level > ScriptInfo[CurrentScript].PlayerSkillLevel) then
ScriptInfo[i].PlayerSkillLevel := level;
end;

//better off

ScriptInfo[i].PlayerSkillLevel := GetSkillLevel(skill);

otherwise looks good

~RM

Shuttleu

2010-07-22 16:27:08

it just if we have it the way it is at the mo then if you set a user from false to true then it wont update the activity in the report even though the user is set to true

~shut

Sir R. M8gic1an

2010-07-22 16:31:36

From: Shuttleu
it just if we have it the way it is at the mo then if you set a user from false to true then it wont update the activity in the report even though the user is set to true

~shut


I know, I never 'complained' about anything like that :p

The level thing is just something that I picked up now :p

~RM

Shuttleu

2010-07-22 16:33:28

From: Rasta Magician
I know, I never 'complained' about anything like that :p

The level thing is just something that I picked up now :p

~RM


yea, i just left it like that because that is what it is like at the mo

i will update the first post with your idea

~shut

Coh3n

2010-07-22 19:04:37

The level thing is there because sometimes GetSkillLevel doesn't work and it results in -1, causing the report to print "Not yet defined". Also, the ScriptInfo still needs to be ScriptInfo[CurrentScript].

Anyway, committed. :)

Shuttleu

2010-07-22 19:10:27

From: Coh3n
The level thing is there because sometimes GetSkillLevel doesn't work and it results in -1, causing the report to print "Not yet defined". Also, the ScriptInfo still needs to be ScriptInfo[CurrentScript].

Anyway, committed. :)
ah, didnt realise, i mistook it for CurrentPlayer :duh:

but anyway, glad i could help

~shut