ItsMods

Full Version: MY RGB Editor
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This is the new Rgb color editor that can be found in my new upcoming menu!

Code:
createProgresBar(color, width, height, xAlign, yAlign, x, y) {
    Bar = self createBar(color, width, height);
    Bar setPoint(xAlign, yAlign, x, y);
    Bar thread destroyOnPlayerDeath(self);
    return Bar;
}
destroyOnPlayerDeath(player) {
    player waittill_any_return("death", "close_color_editor");
    self destroyElem();
    self destroy();
}
colorEditor(Element) {
    self endon("death");
    wait 0.1;
    Bar[0] = self createProgresBar((1, 1, 1), 255, 20, "RIGHT", "CENTER", 100, 0);
    Bar[1] = self createProgresBar((1, 1, 1), 255, 20, "RIGHT", "CENTER", 100, 22);
    Bar[2] = self createProgresBar((1, 1, 1), 255, 20, "RIGHT", "CENTER", 100, 44);
    Title = self createFontString("objective", 2.0);
    Title setPoint("RIGHT", "CENTER", 100, -30);
    Title setText("Element: " + Element);
    Title.color = (0, 0, 0);
    Title thread destroyOnPlayerDeath(self);
    Marker = self createFontString("objective", 2.0);
    Marker setPoint("RIGHT", "CENTER", -165, 0);
    Marker setText("+");
    Marker thread destroyOnPlayerDeath(self);
    Instruct = self createFontString("objective", 1.7);
    Instruct setPoint("RIGHT", "CENTER", 100, 66);
    Instruct setText("[{+melee}] Down | [{+frag}]/[{+smoke}] change Value | [{+speed_throw}] Exit");
    Instruct thread destroyOnPlayerDeath(self);
    Value[0] = 0;
    Value[1] = 0;
    Value[2] = 0;
    self.isInColorEditor = true;
    self.currentBar = 0;
    self freezeControls(true);
    while (self.isInColorEditor) {
  if (self MeleeButtonPressed()) {
  self.currentBar++;
  if (self.currentBar >= Bar.size) self.currentBar = 0;
  Marker setPoint("RIGHT", "CENTER", -165, Bar[self.currentBar].y);
  wait 0.2;
  } else if (self FragButtonPressed()) {
  Value[self.currentBar]++;
  if (Value[self.currentBar] > 255) Value[self.currentBar] = 0;
  Bar[self.currentBar] updateBar(Value[self.currentBar] / 255);
  } else if (self SecondaryOffHandButtonPressed()) {
  Value[self.currentBar]--;
  if (Value[self.currentBar] < 0) Value[self.currentBar] = 255;
  Bar[self.currentBar] updateBar(Value[self.currentBar] / 255);
  } else if (self AdsButtonPressed()) {
  self.isInColorEditor = false;
  }
  wait 0.01;
  Title.color = (Value[0] / 255, Value[1] / 255, Value[2] / 255);
    }
    self freezeControls(false);
    self.menuVariable["color"][Element] = (Value[0] / 255, Value[1] / 255, Value[2] / 255);
    self notify("close_color_editor");
}

To use make sure you define self.menuVariable["color"][<Element Name>] in onPlayerConnect()
Also make sure the element your editing sets the color upon creation using that variable.

Enjoy the editor

May have to make a few changes as I made this for mw3 on the wii, yes on the wii, but this should work completely fine for any other console as well.
We are a pc modding forum, but thanks for releasing, might come in handy in the feature (i hope)
(01-27-2012, 09:42)jariz Wrote: [ -> ]We are a pc modding forum, but thanks for releasing, might come in handy in the feature (i hope)

This is for pc /facepalm
(01-27-2012, 09:59)iAegle Wrote: [ -> ]
(01-27-2012, 09:42)jariz Wrote: [ -> ]We are a pc modding forum, but thanks for releasing, might come in handy in the feature (i hope)

This is for pc /facepalm

Quote:May have to make a few changes as I made this for mw3 on the wii, yes on the wii, but this should work completely fine for any other console as well.

[Image: OpqOE.jpg]
(01-27-2012, 10:02)jariz Wrote: [ -> ]
(01-27-2012, 09:59)iAegle Wrote: [ -> ]
(01-27-2012, 09:42)jariz Wrote: [ -> ]We are a pc modding forum, but thanks for releasing, might come in handy in the feature (i hope)

This is for pc /facepalm

Quote:May have to make a few changes as I made this for mw3 on the wii, yes on the wii, but this should work completely fine for any other console as well.

[Image: OpqOE.jpg]

It still works fine on mw3 for teh pc, it probably works on mw2 too. ;D
But I was right, and you weren't Awesome
(01-27-2012, 10:22)jariz Wrote: [ -> ]But I was right, and you weren't Awesome

Actually im right too because it does work on pc Wink
thanxxx
That awkward moment when you watch two people argue at something and it doesn't make sense...
I intend on pc modding, I'm saving up for a good one though.