更新最新框架
This commit is contained in:
@@ -36,7 +36,7 @@ public static class ChatChannelCenterComponentSystem
|
||||
}
|
||||
|
||||
//查数据库
|
||||
channel = await self.Scene.World.DataBase.Query<ChatChannel>(channelId, true);
|
||||
channel = await self.Scene.World.Database.Query<ChatChannel>(channelId, true);
|
||||
if (channel != null)
|
||||
{
|
||||
self.Channels.Add(channel.Id, channel);
|
||||
@@ -58,7 +58,7 @@ public static class ChatChannelCenterComponentSystem
|
||||
channel.CreateTime = TimeHelper.Now;
|
||||
self.Channels.Add(channel.Id, channel);
|
||||
//保存到数据库
|
||||
await self.Scene.World.DataBase.Save(channel);
|
||||
await self.Scene.World.Database.Save(channel);
|
||||
|
||||
return channel;
|
||||
}
|
||||
|
||||
@@ -114,7 +114,7 @@ public static class ChatUnitManageComponentSystem
|
||||
{
|
||||
if (socialUnit.GetComponent<T>() == null)
|
||||
{
|
||||
var mailComponent = await socialUnit.Scene.World.DataBase.Query<T>(socialUnit.Id, true);
|
||||
var mailComponent = await socialUnit.Scene.World.Database.Query<T>(socialUnit.Id, true);
|
||||
if (mailComponent == null)
|
||||
{
|
||||
//如果没有邮件组件
|
||||
|
||||
@@ -16,7 +16,7 @@ public static class MailConversationHelper
|
||||
public static async FTask<MailConversation> LoadDataBase(Scene scene, long firstId, long secondId)
|
||||
{
|
||||
var conversation =
|
||||
await scene.World.DataBase.First<MailConversation>(d => d.FirstId == firstId && d.SecondId == secondId);
|
||||
await scene.World.Database.First<MailConversation>(d => d.FirstId == firstId && d.SecondId == secondId);
|
||||
if (conversation == null)
|
||||
{
|
||||
return null;
|
||||
@@ -33,6 +33,6 @@ public static class MailConversationHelper
|
||||
/// <param name="id"></param>
|
||||
public static async FTask DeleteDataBase(Scene scene,long id)
|
||||
{
|
||||
await scene.World.DataBase.Remove<MailConversation>(id);
|
||||
await scene.World.Database.Remove<MailConversation>(id);
|
||||
}
|
||||
}
|
||||
@@ -48,7 +48,7 @@ public static class MailComponentSystem
|
||||
});
|
||||
}
|
||||
|
||||
await self.Scene.World.DataBase.Save(self);
|
||||
await self.Scene.World.Database.Save(self);
|
||||
Log.Info($"MailComponent Add id:{self.Id} mailId:{mail.Id} count:{self.Mails.Count}");
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@ public static class MailComponentSystem
|
||||
});
|
||||
}
|
||||
|
||||
await self.Scene.World.DataBase.Save(self);
|
||||
await self.Scene.World.Database.Save(self);
|
||||
Log.Info($"MailComponent Remove id:{self.Id} mailId:{mail.Id} count:{self.Mails.Count}");
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ public static class MailConversationSystem
|
||||
if (forceSave)
|
||||
{
|
||||
self.UpdateTime = TimeHelper.Now;
|
||||
await self.Scene.World.DataBase.Save(self);
|
||||
await self.Scene.World.Database.Save(self);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -84,7 +84,7 @@ public static class MailManageComponentSystem
|
||||
public static async FTask<List<MailConversation>> GetConversations(this MailManageComponent self, long id)
|
||||
{
|
||||
List<MailConversation> players =
|
||||
await self.Scene.World.DataBase.QueryByPageOrderBy<MailConversation>(
|
||||
await self.Scene.World.Database.QueryByPageOrderBy<MailConversation>(
|
||||
d => d.FirstId == id || d.SecondId == id, 1, 50,
|
||||
d => d.UpdateTime);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user