INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Controlling position of mini-skin?  (Read 2272 times)

MBaas

  • Regular Member
  • Recent member
  • *
  • Posts: 9
  • Change this by choosing profile
Controlling position of mini-skin?
« on: August 03, 2004, 11:44:33 am »

Hi,

I have designed a mini-skin, mainly by just using an existing one and stripping what I did not need. That all worked fine, the only problem I have is controlling the position of the player-window: whenever I switch to mini-mode, it appears centered in the middle of the screen, not considering its last position.
Could it be that I have left any parameter in the skin which controls that? I would be happy if it would either remember the last position or be drawn at a position that I specify - how can I do that?

Thanks

Michael
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re:Controlling position of mini-skin?
« Reply #1 on: August 03, 2004, 04:32:29 pm »

http://www.musicex.com/mediajukebox/DevZone/Scripts.html

Specifically, you're interested in the SaveSkinState and LoadSkinState functions.
Logged

MBaas

  • Regular Member
  • Recent member
  • *
  • Posts: 9
  • Change this by choosing profile
Re:Controlling position of mini-skin?
« Reply #2 on: August 04, 2004, 01:20:44 am »

Thanks, that looks really good  :)
Logged

MBaas

  • Regular Member
  • Recent member
  • *
  • Posts: 9
  • Change this by choosing profile
Re:Controlling position of mini-skin?
« Reply #3 on: August 04, 2004, 01:44:32 am »

Hmmmm, so I used a main.js from another mini-skin and added the pointer to it to main.xml

Main.js now has this:
Code: [Select]
function OnInitialize()
{
   if(Metamorphis.LoadSkinState() == false)
   {
      Player.Left = 600;
      Player.Top = 0;

      Info.ShowWindow(true);
      OnToggleWindowShow();

   }
}


function OnExit()
{
   Metamorphis.SaveSkinState();
}
But still the skin always returns to its centered position, not the last position. What else could I have done wrong?

Thanks

Michael

P.S: main.xml also gives the window the correct name:
Code: [Select]
<WINDOW Type="Main" Name="Player" Bitmap="body.bmp" TransColor="FF00FF">
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re:Controlling position of mini-skin?
« Reply #4 on: August 06, 2004, 08:54:53 am »

What version of MC are you using? There was a bug in this part of the SDK that wasn't fixed until I think one of the latter MC10 builds. Also, try deleting the state.xml file that gets created. I found that I needed to delete that file to insure that any changes I was making actually carried through.
Logged

MBaas

  • Regular Member
  • Recent member
  • *
  • Posts: 9
  • Change this by choosing profile
Re:Controlling position of mini-skin?
« Reply #5 on: August 07, 2004, 01:58:46 am »

Thanks for commeting. I'm using 10.0.155  Deleting the state.xml did not cure the issue. Any further thoughts?

Tx

Michael
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re:Controlling position of mini-skin?
« Reply #6 on: August 09, 2004, 08:27:59 am »

Any chance you could post a link to the skin?
Logged

MBaas

  • Regular Member
  • Recent member
  • *
  • Posts: 9
  • Change this by choosing profile
Re:Controlling position of mini-skin?
« Reply #7 on: August 10, 2004, 09:09:26 am »

No, I'm too modest and shy  ;)

Yeah, I thought myself that this might be better than all the theoretic stuff. It's @ http://www.mbaas.de/baasblade.zip - extremely minimalistic, I just wanted to have a display of the current song's title and Blade was a bit too large, so I did this reduced version....
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re:Controlling position of mini-skin?
« Reply #8 on: August 16, 2004, 06:19:49 pm »

Well, I'm stumped. I can't see any reason why this shouldn't be working. Although it looks as though it's never even firing the script at all. I'll do some more testing to see if I can prove that...
Logged
Pages: [1]   Go Up