bdbcef4...18b4bac
commit 18b4bacd5bb645f36f62e77587af971cb789d37c Author: Daniel Asteljoki <daniel.asteljoki@gmail.com> Date: Fri Mar 8 13:04:51 2019 +0200 Added a beginner level sub commit eef09f7d07cde64d1f2f6971eda733505339a0c0 Author: itchyOwl <lauri.harkanen@gmail.com> Date: Thu Mar 7 19:05:14 2019 +0200 Remove the old sprite when recreating the sprite. commit a6c3ce00782882bc14f200f95abab0fa4d5d9a2d Author: itchyOwl <lauri.harkanen@gmail.com> Date: Thu Mar 7 19:04:51 2019 +0200 Fix gender specific wearables not refreshing when we change the gender. commit f606b801dac9e4cbb4238506ff4d73981709a2f8 Author: itchyOwl <lauri.harkanen@gmail.com> Date: Thu Mar 7 18:42:14 2019 +0200 Move some console commands from the shared project to the client. These should not be debug only, because they might be useful for modders too. commit 154251c183eacf37e92fa7b27bb6d57bb15797d8 Author: itchyOwl <lauri.harkanen@gmail.com> Date: Thu Mar 7 14:42:22 2019 +0200 Disable latchonto ai for now.
This commit is contained in:
@@ -149,7 +149,7 @@ namespace Barotrauma
|
||||
commands.SelectMany(c => c.names).ToArray(),
|
||||
new string[0]
|
||||
};
|
||||
}));
|
||||
}, isCheat: true));
|
||||
|
||||
|
||||
commands.Add(new Command("items|itemlist", "itemlist: List all the item prefabs available for spawning.", (string[] args) =>
|
||||
@@ -382,8 +382,9 @@ namespace Barotrauma
|
||||
banDuration = parsedBanDuration;
|
||||
}
|
||||
|
||||
GameMain.NetworkMember.BanPlayer(client.Name, reason, false, banDuration);
|
||||
});
|
||||
ShowQuestionPrompt("Reason for kicking \"" + client.Name + "\"?", (reason) =>
|
||||
{
|
||||
GameMain.NetworkMember.KickPlayer(client.Name, reason);
|
||||
});
|
||||
}));
|
||||
|
||||
@@ -980,98 +981,6 @@ namespace Barotrauma
|
||||
NewMessage("Set packet duplication to " + (int)(duplicates * 100) + "%.", Color.White);
|
||||
}));
|
||||
|
||||
commands.Add(new Command("flipx", "flipx: mirror the main submarine horizontally", (string[] args) =>
|
||||
{
|
||||
Submarine.MainSub?.FlipX();
|
||||
}));
|
||||
|
||||
commands.Add(new Command("gender", "Set the gender of the controlled character. Allowed parameters: Male, Female, None.", args =>
|
||||
{
|
||||
var character = Character.Controlled;
|
||||
if (character == null)
|
||||
{
|
||||
ThrowError("Not controlling any character!");
|
||||
return;
|
||||
}
|
||||
if (args.Length == 0)
|
||||
{
|
||||
ThrowError("No parameters provided!");
|
||||
return;
|
||||
}
|
||||
if (Enum.TryParse(args[0], true, out Gender gender))
|
||||
{
|
||||
character.Info.Gender = gender;
|
||||
character.ReloadHead();
|
||||
foreach (var limb in character.AnimController.Limbs)
|
||||
{
|
||||
foreach (var wearable in limb.WearingItems)
|
||||
{
|
||||
if (wearable.Gender != Gender.None && wearable.Gender != gender)
|
||||
{
|
||||
wearable.Gender = gender;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}));
|
||||
|
||||
commands.Add(new Command("race", "Set race of the controlled character. Allowed parameters: White, Black, Asian, None.", args =>
|
||||
{
|
||||
var character = Character.Controlled;
|
||||
if (character == null)
|
||||
{
|
||||
ThrowError("Not controlling any character!");
|
||||
return;
|
||||
}
|
||||
if (args.Length == 0)
|
||||
{
|
||||
ThrowError("No parameters provided!");
|
||||
return;
|
||||
}
|
||||
if (Enum.TryParse(args[0], true, out Race race))
|
||||
{
|
||||
character.Info.Race = race;
|
||||
character.ReloadHead();
|
||||
}
|
||||
}));
|
||||
|
||||
commands.Add(new Command("loadhead|head", "Load head sprite(s). Required argument: head id. Optional arguments: hair index, beard index, moustache index, face attachment index.", args =>
|
||||
{
|
||||
var character = Character.Controlled;
|
||||
if (character == null)
|
||||
{
|
||||
ThrowError("Not controlling any character!");
|
||||
return;
|
||||
}
|
||||
if (args.Length == 0)
|
||||
{
|
||||
ThrowError("No head id provided!");
|
||||
return;
|
||||
}
|
||||
if (int.TryParse(args[0], out int id))
|
||||
{
|
||||
int hairIndex, beardIndex, moustacheIndex, faceAttachmentIndex;
|
||||
hairIndex = beardIndex = moustacheIndex = faceAttachmentIndex = -1;
|
||||
if (args.Length > 1)
|
||||
{
|
||||
int.TryParse(args[1], out hairIndex);
|
||||
}
|
||||
if (args.Length > 2)
|
||||
{
|
||||
int.TryParse(args[2], out beardIndex);
|
||||
}
|
||||
if (args.Length > 3)
|
||||
{
|
||||
int.TryParse(args[3], out moustacheIndex);
|
||||
}
|
||||
if (args.Length > 4)
|
||||
{
|
||||
int.TryParse(args[4], out faceAttachmentIndex);
|
||||
}
|
||||
character.ReloadHead(id, hairIndex, beardIndex, moustacheIndex, faceAttachmentIndex);
|
||||
}
|
||||
}));
|
||||
|
||||
commands.Add(new Command("money", "", args =>
|
||||
{
|
||||
if (args.Length == 0) { return; }
|
||||
|
||||
Reference in New Issue
Block a user