I have made a start/stop-script for IOw24 for the mairlist2x-version-engine. But after the installation of 3x i can’t use it:
procedure OnCartPlayerStop(PlayerControl: IPlayerControl; Item: IPlaylistItem; Duration: int64);
var
i : integer;
begin
if ((PlayerControl.GetState <> PS_PAUSED) and (PlayerControl.GetCaption = ‘11’)) then begin
IOWarriorRemote(0).SetPort(9, true);
for i := 1 to 5000 do;
IOWarriorRemote(0).SetPort(9, false);
end;
if ((PlayerControl.GetState <> PS_PAUSED) and (PlayerControl.GetCaption = ‘12’)) then begin
IOWarriorRemote(0).SetPort(8, true);
for i := 1 to 5000 do;
IOWarriorRemote(0).SetPort(8, false);
end;
end;
i have read the information about the changes, but i’am not a professional programmer. Please help me !!!
I assume that it’s Players 11 and 12 you’re looking at here, correct?
They have the internal indices 10 and 11, so the script could be rewritten like this (not tested):
procedure OnCartPlayerStop(PlayerIndex: integer; Duration: int64);
var
i : integer;
begin
if (PlayerIndex= 10) and (Engine.GetCartwall.GetPlayer(10).GetState <> PS_PAUSED) then begin
IOWarriorRemote(0).SetPort(9, true);
for i := 1 to 5000 do;
IOWarriorRemote(0).SetPort(9, false);
end;
if (PlayerIndex= 11) and (Engine.GetCartwall.GetPlayer(11).GetState <> PS_PAUSED) then begin
IOWarriorRemote(0).SetPort(8, true);
for i := 1 to 5000 do;
IOWarriorRemote(0).SetPort(8, false);
end;
end;
Instead of the long for loops, you should use the sleep command, e.g. sleep(500) to delay the processing by 500ms.
The IOWarriorRemote thing is a bug. If you had mentioned the error message (unknown identified) in the first place, it could have been fixed already Please try to report all errors as exactly as possible. If there’s an error message, write it down and mention it in your post.
Regarding the other problem you mentioned on the phone, I did a forum search for “1010” again, and it seems that this particular card is problematic in many ways. Just do that search and see for yourself.