forked from SoDOff-Project/sodoff
Fix Mutt Textures not immediately Updating (#12)
* Math Blaster Mutts will now correctly have their textures changed immediately out of the incubator.
This commit is contained in:
parent
8336e16fec
commit
4e02ee19b4
@ -634,7 +634,8 @@ public class ContentController : Controller {
|
|||||||
return Ok(false);
|
return Ok(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (petData.Texture != null && petData.Texture.StartsWith("RS_SHARED/Larva.unity3d/LarvaTex") && petData.GrowthState.GrowthStateID>4) {
|
petData = UpdateDragon(dragon, petData);
|
||||||
|
if (petData.Texture != null && petData.Texture.StartsWith("RS_SHARED/Larva.unity3d/LarvaTex") && petData.GrowthState.GrowthStateID > 4) {
|
||||||
petData.Texture = "RS_SHARED/" + petData.PetTypeID switch {
|
petData.Texture = "RS_SHARED/" + petData.PetTypeID switch {
|
||||||
5 => "EyeClops.unity3d/EyeClopsBrainRedTex", // EyeClops
|
5 => "EyeClops.unity3d/EyeClopsBrainRedTex", // EyeClops
|
||||||
6 => "RodeoLizard.unity3d/BlueLizardTex", // RodeoLizard
|
6 => "RodeoLizard.unity3d/BlueLizardTex", // RodeoLizard
|
||||||
@ -644,8 +645,8 @@ public class ContentController : Controller {
|
|||||||
_ => "null" // Anything with any other ID shouldn't exist.
|
_ => "null" // Anything with any other ID shouldn't exist.
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
dragon.RaisedPetData = XmlUtil.SerializeXml(petData);
|
||||||
|
|
||||||
dragon.RaisedPetData = XmlUtil.SerializeXml(UpdateDragon(dragon, petData));
|
|
||||||
ctx.Update(dragon);
|
ctx.Update(dragon);
|
||||||
ctx.SaveChanges();
|
ctx.SaveChanges();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user