Author Topic: Making an object partially transparent?  (Read 2907 times)

Offline PayThePiedPiper

  • Curious Wanderer
  • *
  • Posts: 18
  • Floof-O-Meter: 3
    • View Profile
    • Join the Farcaster on DeviantArt!
Making an object partially transparent?
« on: January 09, 2015, 07:28:59 pm »
I downloaded some awesome sign and picture meshes but I'm looking to make a rectangular type of sign. Is there anyway to do so?

I was under the thought that with a cube mesh and a half transparent image created in gimp that it could work but that was a very bad fail. Is there anyway to make a writable sign that's rectangular? Any help appreciated. I just hope I explained what I'm trying to do correctly.
Join along with The Farcaster Musum crew and take part in 53 weeks of unique maps!

Offline Ingredient

  • ~Dead men tell no tales~
  • Ancient Silver Mane
  • *****
  • Posts: 3,662
  • Country: 00
  • Floof-O-Meter: 366
    • Ingredient91
    • View Profile
Re: Making an object partially transparent?
« Reply #1 on: January 10, 2015, 01:00:40 am »
For a transparent or partially transparent material make sure you're using a code such as below in the .material file:

Code: [Select]
material NAMEMat
{
transparency_casts_shadows off
receive_shadows off
technique
{
pass
{
ambient 0.75 0.75 0.75 1
diffuse 0.1 0.1 0.1 1
cull_hardware none
cull_software none

alpha_rejection greater_equal 128

texture_unit
{
texture IMAGE.png
}
}
}
}

What kind of sign are you trying to make? Did you want the rectangular sign to have a transparent background or something? I'm not sure how you want your sign to look, if you would be able to provide a brief description or image I would be able to provide more assistance :)
Will be inactive due to work and exams.

Offline PayThePiedPiper

  • Curious Wanderer
  • *
  • Posts: 18
  • Floof-O-Meter: 3
    • View Profile
    • Join the Farcaster on DeviantArt!
Re: Making an object partially transparent?
« Reply #2 on: January 10, 2015, 01:47:53 am »
Things are just never as easy as I anticipate xD

I was definably not using any type of code in my mat files so now I feel silly. What I'm trying to achieve though is something along the lines of this;

So the image against the wall is the file I was attempting to edit. Everything below the Red line I was trying to make transparent so I could achieve a plaque-like image if that makes any sense.


I don't know. Maybe I'm just way over-thinking this.
Join along with The Farcaster Musum crew and take part in 53 weeks of unique maps!

Offline Ingredient

  • ~Dead men tell no tales~
  • Ancient Silver Mane
  • *****
  • Posts: 3,662
  • Country: 00
  • Floof-O-Meter: 366
    • Ingredient91
    • View Profile
Re: Making an object partially transparent?
« Reply #3 on: January 10, 2015, 02:06:28 am »
Alright, I think I know what you mean -although I'm not sure what you mean by "plaque-like" ^^"

Well, I would open that image in your art program. For example GIMP or Photoshop. Open the Layers window and create a transparent layer underneath the image, so when you use the eraser tool it shows a transparent background.

For semi transparent you would change the opacity of the eraser tool to 30%. Select a soft brush, something that looks like this:



(I'd suggest the soft brush for a "fading effect")

Change the size so it's nearly as big as half the image and work upwards towards the line.

When you save the image remember to save it as a .png image so it matches the code in the .material file.

I hope this is what you meant xD
Will be inactive due to work and exams.

Offline PayThePiedPiper

  • Curious Wanderer
  • *
  • Posts: 18
  • Floof-O-Meter: 3
    • View Profile
    • Join the Farcaster on DeviantArt!
Re: Making an object partially transparent?
« Reply #4 on: January 10, 2015, 04:11:36 am »
Thanks so much for the help Ingredient! I will be trying this out immediately.
Join along with The Farcaster Musum crew and take part in 53 weeks of unique maps!

Offline Ingredient

  • ~Dead men tell no tales~
  • Ancient Silver Mane
  • *****
  • Posts: 3,662
  • Country: 00
  • Floof-O-Meter: 366
    • Ingredient91
    • View Profile
Re: Making an object partially transparent?
« Reply #5 on: January 10, 2015, 07:56:10 am »
No worries! Let me know how it goes :3
Will be inactive due to work and exams.

Offline PayThePiedPiper

  • Curious Wanderer
  • *
  • Posts: 18
  • Floof-O-Meter: 3
    • View Profile
    • Join the Farcaster on DeviantArt!
Re: Making an object partially transparent?
« Reply #6 on: January 14, 2015, 01:21:10 am »
Super late on posting this but your advice worked beautifully! Thank you so so much for all your help Ingredient!
Join along with The Farcaster Musum crew and take part in 53 weeks of unique maps!

Offline Ingredient

  • ~Dead men tell no tales~
  • Ancient Silver Mane
  • *****
  • Posts: 3,662
  • Country: 00
  • Floof-O-Meter: 366
    • Ingredient91
    • View Profile
Re: Making an object partially transparent?
« Reply #7 on: January 14, 2015, 04:45:45 am »
You're very welcome! Glad I was able to help :)
« Last Edit: January 14, 2015, 05:45:10 am by Ingredient »
Will be inactive due to work and exams.