Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 08-29-2006, 08:03 PM
JkWhoSaysNi JkWhoSaysNi is offline
Ruler of the graalaxy
Join Date: Feb 2005
Location: Great Britain
Posts: 488
JkWhoSaysNi is on a distinguished road
Send a message via ICQ to JkWhoSaysNi
Showimg, calculating positons after changeimgzoom

Hello,

If i put an image on the screen at 0,0 pixels using ShowImg() then use changeimgzoom to make it bigger or smaller, findimg(num).x and findimg(num).y are still 0 even though the top left hand corner of the image is no longer at 0,0.

I'm trying to overlay another image and keep it in the same place even if the bottom image gets resized. Is there a way to find out the actual location of the top left pixel after it's been resized? The problem occurs because it resizes around the centre of the image. Not the corner of it.

Thanks.
Reply With Quote
  #2  
Old 08-29-2006, 08:10 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
It's fairly simple math. A zoom factor of 2 makes the image twice as big. A zoom factor of 0.5 makes the image half the size. Surely you can work it out from there.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 12:37 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.