![]() |
GuiShowImgCtrls
PHP Code:
|
You're using getImgWidth/getImgHeight. This is all well and all, but they will not give you the correct width/height until the image is loaded in the cache(after it downloads)... and since you're calling this onCreated, and not in a timeout loop, it most likely isn't updated. Also, try bitmap="image"; and see if that makes a difference. I doubt it though.
If you're still having problems, try deducing what could be causing the problem. Change the image to something you KNOW works, like head0.png. Also, put an echo in the function to make sure the function is calling. |
Dusty, I tried head0.png like you suggested that worked perfectly fine however the image did not show even within a timeout as you suggested. :O
|
So that means there's something wrong with the image itself.
Try doing a find on RC and seeing if it's downloadable. If it isn't move it to the correct folder(level/images) and try again. |
It's downloadable and all.
|
So the ctrl works fine when you use head0.png?
Also, for future reference: extent = {getImgWidth(image), getImgHeight(image)}; |
It bugs me when people use position and extent :(
x, y, width, height FTW |
Problem was fixed either way thanks guys.
|
| All times are GMT +2. The time now is 11:09 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.