Author Topic: Designing menu's with file' image  (Read 2180 times)

0 Members and 1 Guest are viewing this topic.

Offline b@nditoTopic starter

  • Jr. Member
  • **
  • Posts: 48
  • Activity:
    0%
  • Reputation Power: 0
  • b@ndito has no influence.
  • Respect: +5
  • Referrals: 0
    • View Profile
Designing menu's with file' image
« on: December 07, 2010, 10:28:07 PM »
0
I've always used the EasyUO menu designer for my scripts but i think that placing images where needed may improve readability and would make menus definitely better looking and less eye-stressing...
I looked on EUO wiki for informations but haven't been able to manage multiple images (IE: i wanted to create icons for my resource gatherer menu), also easyuo forum boards did not give any results.
Now i'm asking here to you if someone can write me some lines to find the way to properly do this, or some script snippet to figure out it.






sorry for the poor english  Kiss

Offline manwinc

  • Elite
  • *
  • *
  • Posts: 2556
  • Activity:
    0%
  • Reputation Power: 32
  • manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!manwinc is a rising star!
  • Gender: Male
  • "The Devs Hard at Work"
  • Respect: +123
  • Referrals: 1
    • View Profile
Re: Designing menu's with file' image
« Reply #1 on: December 08, 2010, 05:41:12 PM »
0
First you must create a directory to the folder that contains the Image Files. I do that with this sub

Gosub Filename C:\Documents and Settings\User\Desktop\EasyUO\Nub Plant Tender

Code: [Select]
Sub Filename
set %Filename %1
for %i 2 %0
{
set %Filename %Filename , #spc , % . %i
}
set %Filename %Filename , \
return

Then you have to set the Directory for that file by doing something along these lines

set %Filename1 %Filename , Plant.Bmp

Where Plant.Bmp is the name for the file in the Folder.

Then you create the Image "Space"

menu Image Create Plant 0 0 400 400

And add in the Image that you have specified at the coordinates you choose

Menu Image File Plant 25 40 %Filename1

I don't think I've ever actually seen scripts that do this other than some that I just play around with, But it Creates some pretty Neat Menus.




Monkeys and Typewriters!

" Oh I know, We'll make a Boss Encounter that requires 3 keys per player to enter, Then we'll make it not a closed instance so you never know if you are going to pop into a fresh room or a boss that has 1% Health left with 20 dudes smashing its face in, wasting your time and effort"

Offline b@nditoTopic starter

  • Jr. Member
  • **
  • Posts: 48
  • Activity:
    0%
  • Reputation Power: 0
  • b@ndito has no influence.
  • Respect: +5
  • Referrals: 0
    • View Profile
Re: Designing menu's with file' image
« Reply #2 on: December 08, 2010, 08:01:33 PM »
0
assuming i set %filename to "C:\Documents and Settings\User"  that your creates to me a variable like this:

%filename: " C:\Documents and Settings\User N/A C:\Documents and Settings\User\

are u sure that sub should work this way?


anyway i got your directions and remembered what was my real problem, trying time ago...

i wrote down this:

Code: [Select]
set %filepath C:\Users\Riccardo\Desktop\Programmi\Easyuo\
set %filename %filepath , menuscript.gif

menu Window Size 264 384
menu Image Create Plant 0 0 400 400
Menu Image File Plant 25 40 %Filename
menu show 300 300

and that's the result:



note that the original image size was 260x380 and  264x384 for menu... as you can see the image has been resized through easyuo rendering.
i'm wondering if this issue is caused by win7 or is easyuo bugged, i can't try this for at least a week since i'm with my laptop @ university apartment and cannot reach my old PC running XP.

if someone wants to try please let me know, i leave the pic in attachment and the script is written above.

There are 1 attachment(s) in this post. You must register and post an acceptable introduction to download
menuscript.gif
« Last Edit: December 08, 2010, 08:05:06 PM by b@ndito »

Tags: