Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 07:59 AM |
If there anyway to flip an image, like if an image if facing left, can you make it face right using code? If so what would I use to do this, it's a surfacegui.
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 08:03 AM |
change it's rotation
i'm not any more should not the panda and? |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 11:39 AM |
that would make it upside down
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 11:43 AM |
no
rotation is between 360 degrees
i'm not any more should not the panda and? |
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 11:44 AM |
You can do it, but you need to know the original resolution of the image. Then you just do ImageLabel.ImageRectSize = Vector2.new(-Resolution, 0) |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 12:04 PM |
filiptibell, So ImageRectSize allows me to make a ImageLabel face the opposite way? Not all the images are the same size, if there wayway to get their size from the site?
|
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 12:30 PM |
I'll give 1k group funds for someone to explain to be how I can do this.
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 12:34 PM |
You want it rotated? So, like Instead of it facing upwards, you tilt it so the top is at the right side and the bottom is at the left side? |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 12:40 PM |
Let's put it this way, you have an image of an arrow and by default it's facing left, this arrow is. Let's say you want to make this arrow face right, how would you that using only code? I have uploaded 850+ images in my game and I need to all be able to face both ways when I need them to, It's taken me almost 2 days straight to get all these images uploaded, I will not edit them and reupload them.
If you would like an example of what I need exactly, let me know I'll show you in game.
|
|
|
| Report Abuse |
|
|
Froast
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 3134 |
|
|
| 17 Dec 2016 12:46 PM |
| ROBLOX does not give you enough control over the image to do this (I've dealt with this problem myself), I'm afraid you have no other option but to flip the images on your own and upload them. |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 01:09 PM |
Has anyone suggested this to someone who will do it, I can't post on the dev forums so I can suggest this but it't be a great thing to have. There should be a drop down for this, to face your image, left,right,up or down depending on how you want it.
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 01:10 PM |
ROBLOX doesn't have enough code to do that, You could try making an image by like hopping in Paint.NET real quick then rotate the image by 90 degrees twice. |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 01:11 PM |
You should read replies before you post, your post is meaningless expect to add to your post count.
|
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Dec 2016 01:13 PM |
you have to get the individual pixels of the bitmap
stackoverflow . com /questions/2647376/correct-flip-mirror-of-pixels-of-an-image
|
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 01:19 PM |
Would c++ even work in game tho, I've never tried or used c++
|
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Dec 2016 01:24 PM |
no, thats just an example. Ask @kodran how to do it
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 01:37 PM |
I think that you might be able to find the answer here: https://www.roblox.com/games/512977261/Christmas-In-Space-Christmas-Edition
It has proven to reveal many glorious things to me. Hope this helps. |
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 01:41 PM |
@everyone saying you can't
It is possible. Check my reply.
What I mentioned flips the image horizontally. You can apply the same thing except on the Y axis if you want to flip it vertically instead. |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 09:03 PM |
filiptibell, that does not work. My image is 110x110 and I did ImageLabel.ImageRectSize = Vector2.new(-110, 0) it just made my image disappear.
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 09:05 PM |
| have you also tried setting imagerectoffset to 110 when doing so? |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 09:06 PM |
I've never looked into this, do I have to make the size the same as the offset?
|
|
|
| Report Abuse |
|
|
|
| 17 Dec 2016 09:08 PM |
Here's the method.
Offset = (width, 0) Size = (width * -1, height) |
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 09:21 PM |
This is what I got, is this correct? Because it still doesn't work. local this = PK.SurfaceGui.ImageLabel this.ImageRectSize = Vector2.new(this.AbsoluteSize.X * -1,this.AbsoluteSize.Y) this.ImageRectOffset = Vector2.new(-this.AbsoluteSize.X, 0)
|
|
|
| Report Abuse |
|
|
Briicks
|
  |
| Joined: 03 Apr 2015 |
| Total Posts: 1796 |
|
|
| 17 Dec 2016 09:23 PM |
I where my mistake, it works. Thanks :D join my primary group if you want that robux and let me know when you do.
|
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Dec 2016 09:28 PM |
this is literally what he means
prntscr . com /dks96v
|
|
|
| Report Abuse |
|
|