issue_comments: 296500956
This data as json
html_url | issue_url | id | node_id | user | created_at | updated_at | author_association | body | reactions | performed_via_github_app | issue |
---|---|---|---|---|---|---|---|---|---|---|---|
https://github.com/ACEmulator/ACE/pull/278#issuecomment-296500956 | https://api.github.com/repos/ACEmulator/ACE/issues/278 | 296500956 | MDEyOklzc3VlQ29tbWVudDI5NjUwMDk1Ng== | 37453 | 2017-04-24T00:40:16Z | 2017-04-24T00:44:09Z | CONTRIBUTOR | Adapted @Lidefeath's selected target smite command to allow you to moveTo a selected target, only works for players and creatures: ``` public static void MoveTo(Session session, params string[] parameters) { if (session.Player.SelectedTarget != 0) { var target = new ObjectGuid(session.Player.SelectedTarget); var wo = LandblockManager.GetWorldObject(session, target); var newMotion = new ServerControlMotion(MotionStance.Standing, wo); session.Network.EnqueueSend(new GameMessageUpdatePosition(session.Player)); session.Network.EnqueueSend(new GameMessageUpdateMotion(session.Player, wo, newMotion, MovementTypes.MoveToObject)); } else { var distance = 10.0f; if ((parameters?.Length > 0)) distance = Convert.ToInt16(parameters[0]); var loot = LootGenerationFactory.CreateTrainingWand(session.Player); LootGenerationFactory.Spawn(loot, session.Player.Location.InFrontOf(distance)); session.Player.TrackObject(loot); var newMotion = new ServerControlMotion(MotionStance.Standing, loot); session.Network.EnqueueSend(new GameMessageUpdatePosition(session.Player)); session.Network.EnqueueSend(new GameMessageUpdateMotion(session.Player, loot, newMotion, MovementTypes.MoveToObject)); } } ``` | {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} | 223669620 |