fred45
04-29-2003, 09:20 AM
this is my code crazy I'm sure but thats probably why I'm here i will explain what I'm trying to do at the end of the thread. Thanks
global proc buildLLwin ( string $win)
{
string $LocLabel = "Location";
int $postNUM = 0;
string $flip = `rotate -r 0 180 0`
global float $Pos75;
$Pos75 = 7.5;
global float $Neg75 = -7.5;
global float $Pos165 = 16.5;
global float $Neg165 = -16.5;
global float $Pos255 = 25.5;
global float $Neg255 = -25.5;
//clear $Sel_Set;
window -t "Location! Location!" $win;
columnLayout;
rowColumnLayout -nc 2;
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg255 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg165 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg75 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg75 0 $Neg165");
//Across the road the building must be rotated 180 degrees
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg255 0 $Pos75; $flip;");
button -l "Close" -c ("deleteUI " + $win);
}
Maya doesn't think that $Neg75 is a variable this I believe is because the command in the button is being called externally and the variable doesn't exsist outside the proc.(maybe??) This I tried to fix by making the variables global but maya tells me I'm not aloud to do this! And now my brain is fryed and I everything I thought I knew I don't please help me from running backwards. Thanks
Matthew Blair
Student
CGC Melbourne
global proc buildLLwin ( string $win)
{
string $LocLabel = "Location";
int $postNUM = 0;
string $flip = `rotate -r 0 180 0`
global float $Pos75;
$Pos75 = 7.5;
global float $Neg75 = -7.5;
global float $Pos165 = 16.5;
global float $Neg165 = -16.5;
global float $Pos255 = 25.5;
global float $Neg255 = -25.5;
//clear $Sel_Set;
window -t "Location! Location!" $win;
columnLayout;
rowColumnLayout -nc 2;
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg255 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg165 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg75 0 $Neg75");
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg75 0 $Neg165");
//Across the road the building must be rotated 180 degrees
button -l ($LocLabel + ($postNUM++)) -c ("move -a -ws $Neg255 0 $Pos75; $flip;");
button -l "Close" -c ("deleteUI " + $win);
}
Maya doesn't think that $Neg75 is a variable this I believe is because the command in the button is being called externally and the variable doesn't exsist outside the proc.(maybe??) This I tried to fix by making the variables global but maya tells me I'm not aloud to do this! And now my brain is fryed and I everything I thought I knew I don't please help me from running backwards. Thanks
Matthew Blair
Student
CGC Melbourne
