mirror of
https://github.com/project-redbud/FunGame-Server.git
synced 2025-12-05 00:06:03 +00:00
BUG修复,开启2.0-dev
This commit is contained in:
parent
0e361b5be9
commit
d3cf91e014
@ -1421,7 +1421,7 @@ namespace Milimoe.FunGame.Server.Controller
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
subResult = false;
|
subResult = false;
|
||||||
buyResult.Add($"购买失败,原因:需要花费 {totalPrice} {General.GameplayEquilibriumConstant.InGameMaterial},但是您只有 {user.Inventory.Credits} {General.GameplayEquilibriumConstant.InGameMaterial}。");
|
buyResult.Add($"购买失败,原因:需要花费 {totalPrice} {General.GameplayEquilibriumConstant.InGameMaterial},但是您只有 {user.Inventory.Materials} {General.GameplayEquilibriumConstant.InGameMaterial}。");
|
||||||
}
|
}
|
||||||
if (subResult)
|
if (subResult)
|
||||||
{
|
{
|
||||||
@ -1652,10 +1652,11 @@ namespace Milimoe.FunGame.Server.Controller
|
|||||||
{ "targets", targets },
|
{ "targets", targets },
|
||||||
{ "useCount", useCount }
|
{ "useCount", useCount }
|
||||||
};
|
};
|
||||||
bool used = item.UseItem(args);
|
bool used = item.UseItem(user, args);
|
||||||
if (used)
|
if (used)
|
||||||
{
|
{
|
||||||
SQLHelper.UpdateInventory(user.Inventory);
|
SQLHelper.UpdateInventory(user.Inventory);
|
||||||
|
result = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (result)
|
if (result)
|
||||||
@ -1698,6 +1699,7 @@ namespace Milimoe.FunGame.Server.Controller
|
|||||||
user.Inventory.Credits += reward;
|
user.Inventory.Credits += reward;
|
||||||
item.EntityState = EntityState.Deleted;
|
item.EntityState = EntityState.Deleted;
|
||||||
SQLHelper.UpdateInventory(user.Inventory);
|
SQLHelper.UpdateInventory(user.Inventory);
|
||||||
|
result = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (result)
|
if (result)
|
||||||
@ -2017,14 +2019,13 @@ namespace Milimoe.FunGame.Server.Controller
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (msg != "")
|
if (msg == "")
|
||||||
{
|
{
|
||||||
offer = SQLHelper.GetOffer(offerId);
|
offer = SQLHelper.GetOffer(offerId);
|
||||||
if (offer != null)
|
if (offer != null)
|
||||||
{
|
{
|
||||||
SQLHelper.Commit();
|
SQLHelper.Commit();
|
||||||
resultData.Add("offer", offer);
|
resultData.Add("offer", offer);
|
||||||
msg = "";
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user