package kaka.cakelight.mode;
import kaka.cakelight.Color;
-import kaka.cakelight.Console;
import kaka.cakelight.LedFrame;
import kaka.cakelight.util.SimplexNoise3D;
private final Color primary, secondary;
private SimplexNoise3D noise = new SimplexNoise3D(0);
- public static Console.Command getCommand() {
- return new Console.Command() {
- public String[] getNames() {
- return new String[] {"n", "noise"};
- }
-
- public void activate(Console console, String[] args) {
- if (args.length == 3) { // cmd + col1 + col2
- console.getCakelight().setMode(new TwoColorNoiseMode(
- parseColor(args[1]),
- parseColor(args[2])
- ));
- }
- }
- };
- }
-
public TwoColorNoiseMode(Color primary, Color secondary) {
this.primary = primary;
this.secondary = secondary;