• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

How to resize an image in a dialog?

Status
Not open for further replies.
Level 5
Joined
Aug 27, 2008
Messages
126
When I use this:

  • Dialog - Create an image for dialog (Last created dialog) with the dimensions (35, 35) anchored to Top Left with an offset of (100, 55) setting the tooltip to "" using the image Assets\Textures\icon-mineral.dds as a Normal type with tiled set to True tint color White and blend mode Normal
The image gets cropped (chopped in half) and its really ugly. Is there a way to actually resize it and use it in a dialog?
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,202
Try changing the image type.

Code:
// Image types
const int c_triggerImageTypeNone                        = 0;
const int c_triggerImageTypeNormal                      = 1;
const int c_triggerImageTypeBorder                      = 2;
const int c_triggerImageTypeHorizontalBorder            = 3;
const int c_triggerImageTypeEndCap                      = 4;

Some of them tile (so when you increase their size the image repeats). Others of them will cause the image to stretch.
 
Level 5
Joined
Aug 27, 2008
Messages
126
:O Now thats a piece of work good job :D Yes, it really is working but still, I aint touching jass (its jass in sc2 editor too, right?). I make everything with GUI. Thanks for the help tho :p

Ok, I may not write in jass but I understand it, its not that hard. I examined your code and I did it with gui:

Dialog - Create a Image for dialog (Last created dialog)
Dialog - Set (Last created dialog item) size to (35, 35) for (All players)
Dialog - Move (Last created dialog item) to (50, 55) relative to Top Left of dialog for (All players)
Dialog - Set (Last created dialog item) image to Assets\Textures\icon-mineral.dds for (All players)

This actually WORKED! Thanks +rep :p . The action that I was doing before was supposed to combine them all in one, but I guess not exactly.

p.s. Bleh, I cant give your rep now because it says that I have to spread some around. Guess you are the one that helped me the last time :p I will give you rep for this when I can.
 
Last edited by a moderator:

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,202
I aint touching jass (its jass in sc2 editor too, right?).
Its Galaxy script...

This actually WORKED! Thanks +rep :p . The action that I was doing before was supposed to combine them all in one, but I guess not exactly.
Thats one of the reasons I avoid GUI. It abstracts one too much away from the actual mechanics of the script.
 
Status
Not open for further replies.
Top