jo klar
[code]procedure OnCartPlayerStart(PlayerControl: IPlayerControl; Item: IPlaylistItem);
begin
if PlayerControl.GetCaption = ‘1’ then IOWarriorRemote(0).SetPort(29, true)
if PlayerControl.GetCaption = ‘2’ then IOWarriorRemote(0).SetPort(30, true)
if PlayerControl.GetCaption = ‘3’ then IOWarriorRemote(0).SetPort(31, true)
if PlayerControl.GetCaption = ‘4’ then IOWarriorRemote(0).SetPort(28, true)
if PlayerControl.GetCaption = ‘5’ then IOWarriorRemote(0).SetPort(27, true)
if PlayerControl.GetCaption = ‘6’ then IOWarriorRemote(0).SetPort(26, true)
if PlayerControl.GetCaption = ‘7’ then IOWarriorRemote(0).SetPort(23, true)
if PlayerControl.GetCaption = ‘8’ then IOWarriorRemote(0).SetPort(24, true)
if PlayerControl.GetCaption = ‘9’ then IOWarriorRemote(0).SetPort(25, true)
end;
procedure OnCartPlayerStop(PlayerControl: IPlayerControl; Item: IPlaylistItem; Duration: int64);
begin
if PlayerControl.GetCaption = ‘1’ then IOWarriorRemote(0).SetPort(29, false)
if PlayerControl.GetCaption = ‘2’ then IOWarriorRemote(0).SetPort(30, false)
if PlayerControl.GetCaption = ‘3’ then IOWarriorRemote(0).SetPort(31, false)
if PlayerControl.GetCaption = ‘4’ then IOWarriorRemote(0).SetPort(28, false)
if PlayerControl.GetCaption = ‘5’ then IOWarriorRemote(0).SetPort(27, false)
if PlayerControl.GetCaption = ‘6’ then IOWarriorRemote(0).SetPort(26, false)
if PlayerControl.GetCaption = ‘7’ then IOWarriorRemote(0).SetPort(23, false)
if PlayerControl.GetCaption = ‘8’ then IOWarriorRemote(0).SetPort(24, false)
if PlayerControl.GetCaption = ‘9’ then IOWarriorRemote(0).SetPort(25, false)
end;
begin
end.[/code]dann geht immer nur ein einziges Lämpchen, wenn das allerdings folgendes in onStartUp schreibe gehen die Lampen alle an:
procedure OnStartup;
begin
IOWarriorRemote(0).SetPort(31, true);
IOWarriorRemote(0).SetPort(30, true);
IOWarriorRemote(0).SetPort(29, true);
IOWarriorRemote(0).SetPort(28, true);
IOWarriorRemote(0).SetPort(27, true);
IOWarriorRemote(0).SetPort(26, true);
IOWarriorRemote(0).SetPort(25, true);
IOWarriorRemote(0).SetPort(24, true);
IOWarriorRemote(0).SetPort(23, true);
end;
bitte nicht schlagen, man kann das auch mit Schleifen machen. Aber gehen muss es so auch…