Author Topic: Yellow Rainbow Player  (Read 1404 times)

how do you combine the green and blue colors? because it's cycling through green colors, then blue colors, instead of just doing yellow colors, that and what's the node for head skin?
Code: [Select]
//Rainbow Shirt
//by boomlinde
//Edited by NiXiLL and Ethan. Edited for yellow by phflack.

if (!$RainbowPlayerBindings)
{
   $remapDivision[$remapCount] = "Rainbow Player";
   $remapName[$remapCount] = "Activate/Deacticate";
   $remapCmd[$remapCount] = "RainbowPlayerToggle";
   $remapCount++;
   $RainbowPlayerBindings=true;
}

$RainbowPlayerCount=0;
$RainbowPlayerFlag=0;
$RainbowPlayerTempPack=$pref::Avatar::PackColor;
$RainbowPlayerTempHat=$pref::Avatar::HatColor;
$RainbowPlayerTempLHand=$pref::Avatar::LHandColor;
$RainbowPlayerTempRHand=$pref::Avatar::RHandColor;
$RainbowPlayerTempHeadskin=$pref::Player::HeadskinColor;
$RainbowPlayerTempHead=$pref::Player::HeadColor;
function RainbowPlayerToggle(%val)
{
  if(%val) {
    if($RainbowPlayerFlag==0)
    {
        $RainbowPlayerFlag=1;
        $RainbowPlayerTempPack=$pref::Avatar::PackColor;
      $RainbowPlayerTempHat=$pref::Avatar::HatColor;
      $RainbowPlayerTempLHand=$pref::Avatar::LHandColor;
      $RainbowPlayerTempRHand=$pref::Avatar::RHandColor;
      $RainbowPlayerTempHeadskin=$pref::Avatar::HeadskinColor;
      $RainbowPlayerTempTorso=$pref::Avatar::TorsoColor;
      $RainbowPlayerTempLArm=$pref::Avatar::LArmColor;
      $RainbowPlayerTempRArm=$pref::Avatar::RArmColor;
      $RainbowPlayerTempHip=$pref::Avatar::HipColor;
        RainbowPlayerLoop();
    }
   else if($RainbowPlayerFlag==1)
    {
        $RainbowPlayerFlag=0;
        cancel($RainbowPlayer);
        $pref::Avatar::PackColor=$RainbowPlayerTempPack;
      $pref::Avatar::HatColor=$RainbowPlayerTempHat;
      $pref::Avatar::LHandColor=$RainbowPlayerTempLHand;
      $pref::Avatar::RHandColor=$RainbowPlayerTempRHand;
      $pref::Avatar::HeadskinColor=$RainbowPlayerTempHeadskin;
      $pref::Avatar::TorsoColor=$RainbowPlayerTempTorso;
      $pref::Avatar::LArmColor=$RainbowPlayerTempLArm;
      $pref::Avatar::RArmColor=$RainbowPlayerTempRArm;
      $pref::Avatar::HipColor=$RainbowPlayerTempHip;
        clientcmdupdateprefs();
    }
  }
}
function rainbowreset() {
cancel($RainbowPlayer);
$pref::Avatar::PackColor=$RainbowPlayerTempPack;
$pref::Avatar::HatColor=$RainbowPlayerTempHat;
$pref::Avatar::LHandColor=$RainbowPlayerTempLHand;
$pref::Avatar::RHandColor=$RainbowPlayerTempRHand;
$pref::Avatar::HeadskinColor=$RainbowPlayerTempHeadskin;
$pref::Avatar::TorsoColor=$RainbowPlayerTempTorso;
$pref::Avatar::LArmColor=$RainbowPlayerTempLArm;
$pref::Avatar::RArmColor=$RainbowPlayerTempRArm;
$pref::Avatar::HipColor=$RainbowPlayerTempHip;
clientcmdupdateprefs();
}
function RainbowPlayerLoop()
{
        if($RainbowPlayerCount > 63) $RainbowPlayerCount=0;
        //Grejer
        $R=0+0*mSin($RainbowPlayerCount*3.14/16.0);
        $G=0.75+0.25*mSin($RainbowPlayerCount*3.14/16.0+21.0);
        $B=0.75+0.25*mSin($RainbowPlayerCount*3.14/16.0+42.0);
        $pref::Avatar::PackColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::PackColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::HatColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::LHandColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::RHandColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::HeadskinColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::TorsoColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::LArmColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::HipColor=$R SPC $G SPC $B SPC "1";
      $pref::Avatar::RArmColor=$R SPC $G SPC $B SPC "1";
        clientcmdupdateprefs();
        $RainbowPlayerCount++;
        $RainbowPlayer=schedule(1000,0,RainbowPlayerLoop);
}

The anti-funky shirt campaign started for a reason.

The anti-funky shirt campaign started for a reason.
i just wanted a slow tiny change in color, not what they used to use the the schedules

I'd rather you didn't. Help section or not, I do not support this at all.

then again, i wouldn't use it that much anywho, just wondering how

It would be a little difficult, seeing how (in computers) yellow is a mix of red and green.

oh... i thought it was green and blue :o

It would be a little difficult, seeing how (in computers) yellow is a mix of red and green.
'Cause of RGB being the 'primary' colors.

oh, wait a second, we're mixing light? not like paint colors?
because for the paint colors, it's like the hex codes, RGB mixed, GB to make yellow, but for light it's different somehow which i forgot
edit: just looked at the avatar color stuff, the color code for default yellow is
Code: [Select]
$Avatar::Color1 = "0.900 0.900 0.000 1.000";which i expect is red and green combined?
doubleedit: ok, mixing red and green worked, now i just need to edit the values soem more to get nicer yellows, and what's the node for the face called? i thought it was headskin but it didn't work
« Last Edit: March 02, 2010, 03:44:37 PM by phflack »

head

Or maybe Foreskin... Hehe
« Last Edit: March 09, 2010, 02:56:58 AM by Darkhaz »

GB to make yellow
Green + Blue = Cyan. How do you get yellow?

Green + Blue = Cyan. How do you get yellow?
with the paint colors? i think... not sure how i got green and blue

I have an old version of the rainbow player. It's kinda broken cause it doesn't gradually change/ GDR into the new color, it just instantaneously changes to a different color.

head

Foreskin
thanks man
I have an old version of the rainbow player. It's kinda broken cause it doesn't gradually change/ GDR into the new color, it just instantaneously changes to a different color.
at the bottom you can edit how long until it switches colors