mirror of
https://github.com/ClassiCube/MCGalaxy.git
synced 2025-09-23 04:32:50 -04:00
RainbowDrawOp doesn't hardcode length, split up /help model
This commit is contained in:
parent
87bcda2da6
commit
b439e02eeb
@ -76,9 +76,17 @@ namespace MCGalaxy.Commands.CPE {
|
||||
public override void Help(Player p) {
|
||||
Player.Message(p, "%T/model [name] [model] %H- Sets the model of that player.");
|
||||
Player.Message(p, "%T/model bot [name] [model] %H- Sets the model of that bot.");
|
||||
Player.Message(p, "%HType %T/help model models %Hfor a list of models.");
|
||||
}
|
||||
|
||||
public override void Help(Player p, string message) {
|
||||
if (message.CaselessEq("models")) {
|
||||
Player.Message(p, "%HAvailable models: %SChibi, Chicken, Creeper, Giant, Humanoid, Pig, Sheep, Spider, Skeleton, Zombie, Head, Sitting");
|
||||
Player.Message(p, "%HTo set a block model, use a block ID for the model name.");
|
||||
Player.Message(p, "%HFor setting a scaled model, put \"|[scale]\" after the model name. (e.g. pig|0.5)");
|
||||
} else {
|
||||
Help(p);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -103,18 +103,19 @@ namespace MCGalaxy.Drawing.Ops {
|
||||
stepZ = 1;
|
||||
}
|
||||
|
||||
int i = 12;
|
||||
int repeat = RainbowBrush.blocks.Length;
|
||||
int i = repeat - 1;
|
||||
ExtBlock block = default(ExtBlock);
|
||||
brush = new RainbowBrush();
|
||||
|
||||
for (ushort y = p1.Y; y <= p2.Y; y++) {
|
||||
i = (i + stepY) % 13;
|
||||
i = (i + stepY) % repeat;
|
||||
int startZ = i;
|
||||
for (ushort z = p1.Z; z <= p2.Z; z++) {
|
||||
i = (i + stepZ) % 13;
|
||||
i = (i + stepZ) % repeat;
|
||||
int startX = i;
|
||||
for (ushort x = p1.X; x <= p2.X; x++) {
|
||||
i = (i + stepX) % 13;
|
||||
i = (i + stepX) % repeat;
|
||||
if (!Level.IsAirAt(x, y, z)) {
|
||||
// Need this because RainbowBrush works on world coords
|
||||
Coords.X = (ushort)i; Coords.Y = 0; Coords.Z = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user