mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-06-09 22:14:39 +02:00
Implemented more of the Guildleve Director. Correct script is now autoloaded based on leveplate. Players are now added to the contentgroup on leve start. Moved animation and stuff to C# side of things. Cleaned up code.
This commit is contained in:
parent
c42f1a08de
commit
875b76634a
9 changed files with 292 additions and 55 deletions
|
@ -600,7 +600,7 @@ namespace FFXIVClassic_Map_Server
|
|||
if (player.currentContentGroup != null)
|
||||
{
|
||||
player.currentContentGroup.RemoveMember(player.actorId);
|
||||
player.SetCurrentContentGroup(null, player);
|
||||
player.SetCurrentContentGroup(null);
|
||||
|
||||
if (oldZone is PrivateAreaContent)
|
||||
((PrivateAreaContent)oldZone).CheckDestroy();
|
||||
|
@ -762,11 +762,6 @@ namespace FFXIVClassic_Map_Server
|
|||
|
||||
}
|
||||
|
||||
public ContentGroup CreateContentGroup(Director director)
|
||||
{
|
||||
return CreateContentGroup(director, null);
|
||||
}
|
||||
|
||||
public ContentGroup CreateContentGroup(Director director, params Actor[] actors)
|
||||
{
|
||||
if (director == null)
|
||||
|
@ -795,6 +790,62 @@ namespace FFXIVClassic_Map_Server
|
|||
}
|
||||
}
|
||||
|
||||
public ContentGroup CreateContentGroup(Director director, List<Actor> actors)
|
||||
{
|
||||
if (director == null)
|
||||
return null;
|
||||
|
||||
lock (groupLock)
|
||||
{
|
||||
uint[] initialMembers = null;
|
||||
|
||||
if (actors != null)
|
||||
{
|
||||
initialMembers = new uint[actors.Count];
|
||||
for (int i = 0; i < actors.Count; i++)
|
||||
initialMembers[i] = actors[i].actorId;
|
||||
}
|
||||
|
||||
groupIndexId = groupIndexId | 0x3000000000000000;
|
||||
|
||||
ContentGroup contentGroup = new ContentGroup(groupIndexId, director, initialMembers);
|
||||
mContentGroups.Add(groupIndexId, contentGroup);
|
||||
groupIndexId++;
|
||||
if (initialMembers != null && initialMembers.Length != 0)
|
||||
contentGroup.SendAll();
|
||||
|
||||
return contentGroup;
|
||||
}
|
||||
}
|
||||
|
||||
public ContentGroup CreateGLContentGroup(Director director, List<Actor> actors)
|
||||
{
|
||||
if (director == null)
|
||||
return null;
|
||||
|
||||
lock (groupLock)
|
||||
{
|
||||
uint[] initialMembers = null;
|
||||
|
||||
if (actors != null)
|
||||
{
|
||||
initialMembers = new uint[actors.Count];
|
||||
for (int i = 0; i < actors.Count; i++)
|
||||
initialMembers[i] = actors[i].actorId;
|
||||
}
|
||||
|
||||
groupIndexId = groupIndexId | 0x2000000000000000;
|
||||
|
||||
GLContentGroup contentGroup = new GLContentGroup(groupIndexId, director, initialMembers);
|
||||
mContentGroups.Add(groupIndexId, contentGroup);
|
||||
groupIndexId++;
|
||||
if (initialMembers != null && initialMembers.Length != 0)
|
||||
contentGroup.SendAll();
|
||||
|
||||
return contentGroup;
|
||||
}
|
||||
}
|
||||
|
||||
public void DeleteContentGroup(ulong groupId)
|
||||
{
|
||||
lock (groupLock)
|
||||
|
@ -802,7 +853,6 @@ namespace FFXIVClassic_Map_Server
|
|||
if (mContentGroups.ContainsKey(groupId) && mContentGroups[groupId] is ContentGroup)
|
||||
{
|
||||
ContentGroup group = (ContentGroup)mContentGroups[groupId];
|
||||
group.SendDeletePackets();
|
||||
mContentGroups.Remove(groupId);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue