Error: Duplicate declaration "DeleteIndex" at line 298
idk
Error: Duplicate declaration "DeleteIndex" at line 298
idk
Just comment out the function "DeleteIndex" and it might work, it has to do with a new function in SRL which does the same thing.
Loaded Font UpChars
Loaded Font UpChars07
Loaded Font UpChars07_s
Loaded Font UpCharsEx
Loaded Font XPChars
Loaded Font UpChars_s
Error: Duplicate declaration "DeleteIndex" at line 298
Compiling failed.
Anyone have a fix to this?
Might be missing something obvious here but when i comment it out, it comes up with:
Error: Unknown declaration "self" at line 302
Compiling failed.
I.e. it then finds an error here instead:
begin
for i := index to High(self) - 1 do
self[i] := self[i + 1];
SetLength(self, Length(self) - 1);
end
Tried and did not work
I wouldn't comment it out, I'd override it. The script is designed to work with the script's .deleteIndex(), SRL-6's may not be the same.
Add an override; to the end of the function declaration, like so:(note: I pulled that from another script - it's only supposed to show the concept for overriding a function. The actual declaration may be different.)Simba Code:procedure T2DPointArray.deleteIndex(const index : Integer); override;
GitLab projects | Simba 1.4 | Find me on IRC or Discord | ScapeRune scripts | Come play bot ScapeRune!
<BenLand100> we're just in the transitional phase where society reclassifies guns as Badâ„¢ before everyone gets laser pistols
I have not tested the script but it should work. What is not working? What was your attempted fix? Post the code (just the section you changed) in [simba] [ /simba] tags without the space?
You can delete the whole function T2DpointArray.DeleteIndex, if you know what that means. From where it says that line, click on the "begin" below it. It will highlight the "end" which corresponds to the end of the function (likely only ~10-15 lines below but I don't have Simba on this computer). You can delete the whole thing, right from T2DPointArray.Delete index down to the end of the function.
Sorry I feel pretty useless at the moment... I only started scripted about last week so I have 0 knowledge of how the scripting works.
Specifically procedure T2DPointArray.deleteIndex(const index : Integer); is giving the error (I tried deleting the whole function like you said, aswell as overriding but both of them result in error compiling).
deleting the function gave this: Error: Don't know which overloaded method to call with params (array [0..3] of Int32, Int32) at line 140
Compiling failed. Line 140: self.canvas.Rectangle([0, 0, self.bounds.x2, 33], $21314e);
So now I'm completely lost, sorry about that
Could someone please get a fix for this. Greatky appreciated.
Well I've got good news and bad news.
The good news is that it appears that you deleted the proper function and didn't break it by yourself.
The bad news is that there appears to be another error on line 140 (the function you deleted was ~300 so it's not your fault). I haven't seen Superuser (the person who wrote this) around in a while so it's possible that the script is outdated unfortunately.
I won't really have any Simba access for a few days or I'd help you out right now. Best of luck.
thanks for clearing stuff up
There are currently 2 users browsing this thread. (0 members and 2 guests)