-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add experimental implementations of commands
- Loading branch information
1 parent
c9ef17e
commit 8b2e841
Showing
87 changed files
with
1,406 additions
and
742 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
UdpHosts/GameServer/Systems/Aptitude/Commands/Impact/TeleportInstanceCommand.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
using AeroMessages.Matrix.V25; | ||
using GameServer.Data.SDB.Records.customdata; | ||
using GameServer.Entities.Character; | ||
using GameServer.Test; | ||
|
||
namespace GameServer.Aptitude; | ||
|
||
public class TeleportInstanceCommand : Command, ICommand | ||
{ | ||
private TeleportInstanceCommandDef Params; | ||
|
||
public TeleportInstanceCommand(TeleportInstanceCommandDef par) | ||
: base(par) | ||
{ | ||
Params = par; | ||
} | ||
|
||
public bool Execute(Context context) | ||
{ | ||
if (Params.ZoneId == 0) | ||
{ | ||
return true; | ||
} | ||
|
||
foreach (var target in context.Targets) | ||
{ | ||
if (target is not CharacterEntity { Player: NetworkPlayer networkPlayer }) | ||
{ | ||
continue; | ||
} | ||
|
||
networkPlayer.NetChannels[ChannelType.Matrix].SendMessage(new ExitZone()); | ||
|
||
networkPlayer.EnterZone(DataUtils.GetZone(Params.ZoneId)); | ||
} | ||
|
||
return true; | ||
} | ||
} |
19 changes: 0 additions & 19 deletions
19
UdpHosts/GameServer/Systems/Aptitude/Commands/Impact/Todo/TeleportInstanceCommand.cs
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.