Maya Training

Introduction to Hard Surface Modeling

Maya Training

Interiors and Furniture Vol 1 & 2 - Modeling & Cloth

Maya Training

Shading, Lighting and Rendering the Bedroom in MR

Maya Training

Robot volume one - Modeling with animation in mind

Maya Training

Spach-Alspaugh House the complete courseware

Maya Training

Burt The Cartoon Dinosaur Vol 01 - Modeling

New Maya Training

Robot Volume 02 - Hybrid Rigging
You are here > Home > SimplyMaya Community Forums
Loading

Welcome to Simply Maya

Please Sign in or Sign up for an account

Member Login

Lost your password?

Not a member yet? Sign Up!

Old 15-07-2006, 01:47 AM   #1
lordeugenius
Registered User
 
lordeugenius's Avatar
 
Join Date: Jul 2006
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default X-Ray question

Hi! I have a question, if you can help me please: how can i insert the x-ray button into the custom tab in shelf, i know that for the other buttons you must press ctrl+shift and left mouse button but this doesn't work for x-ray. Please help!!! I appreciate.
lordeugenius is offline   Reply With Quote
Old 15-07-2006, 08:12 AM   #2
jsprogg
Lifetime Member
 
jsprogg's Avatar
 
Join Date: Feb 2004
Location: Chicago
Posts: 1,706
Thanks: 0
Thanked 85 Times in 77 Posts
Default

Ok this should get you going

Copy & past this to the script editor then middle mouse button drag to your shelf.

string $sel[];
int $temp[];
int $value;

$sel = `ls -sl -dag -ap -typ surfaceShape`;

for ($obj in $sel){
$temp = `displaySurface -q -xRay $obj`;
$value = $temp[0];
if ($value == 1)
displaySurface -xRay 0 $obj;
else
displaySurface -xRay 1 $obj;
}
jsprogg is offline   Reply With Quote
Old 15-07-2006, 11:55 AM   #3
lordeugenius
Registered User
 
lordeugenius's Avatar
 
Join Date: Jul 2006
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default

nope, not working, it gives me a sintax error
lordeugenius is offline   Reply With Quote
Old 15-07-2006, 12:40 PM   #4
13th_resident
Subscriber
 
13th_resident's Avatar
 
Join Date: Feb 2006
Location: London
Posts: 703
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i made a post on how to make add the x-ray onto your shelf.
click me

cheers
__________________
A pint of example is worth a gallon of advice!!
13th_resident is offline   Reply With Quote
Old 15-07-2006, 08:25 PM   #5
lordeugenius
Registered User
 
lordeugenius's Avatar
 
Join Date: Jul 2006
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks man but doesn't work either, now it doesn't give me any errors but nothing's happening. I'm going crazy!
lordeugenius is offline   Reply With Quote
Old 16-07-2006, 03:29 AM   #6
portermalone
Subscriber
 
Join Date: May 2005
Posts: 56
Thanks: 0
Thanked 0 Times in 0 Posts
Default

go to the download section of this website and download the x-ray script from danny. Then open that .mel script with notepad or something and copy the code. Go into maya and open your script editor. In the bottom window of the script editor paste the code you copied from the .mel scrpit. Highlight the script you just pasted in the bottom window of the script editor. Move your mouse over the highlighted script, middle mouse button click and hold over the script, drag the script to the shelf and let go of the middle mouse button. You should now have a button that says MEL this is your x-ray button. You can change the icon and name to match kurts, or make it what ever you want after that.


Good luck
portermalone is offline   Reply With Quote
Old 16-07-2006, 12:48 PM   #7
lordeugenius
Registered User
 
lordeugenius's Avatar
 
Join Date: Jul 2006
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
Default

:headbang: Not working, i did exactly what you wrote and nothing, i don't know what to do, I quit, thanks for everything guys, I appreciate.
lordeugenius is offline   Reply With Quote
Old 17-07-2006, 11:25 AM   #8
pixelsoul
Subscriber
 
pixelsoul's Avatar
 
Join Date: Dec 2004
Posts: 307
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I remember there was a script which you can add to your toolbar you can even toggle off and on for each object.
pixelsoul is offline   Reply With Quote

A little bit about who we are
Links you might find useful
Catch up with SimplyMaya
SimplyMaya specialises in Maya tutorials. We offer over 1,000 individual Maya training videos, ranging from basic Maya tutorials through to intermediate Maya tutorials. Our tutorials are created by instructors with industry experience and are designed to get you up and running in Maya quickly without making it seem like hard work.

Copyright © 1999-2015 SimplyMaya - vBulletin® Copyright © 2000-2015, Jelsoft Enterprises Ltd.