| | 1 | | using System.Collections.Generic; |
| | 2 | |
|
| | 3 | | public class PlayerAvatarAnalytics |
| | 4 | | { |
| | 5 | | private readonly IAnalytics analytics; |
| | 6 | | private readonly Vector2IntVariable playerCoords; |
| | 7 | |
|
| 572 | 8 | | public PlayerAvatarAnalytics(IAnalytics analytics, |
| | 9 | | Vector2IntVariable playerCoords) |
| | 10 | | { |
| 572 | 11 | | this.analytics = analytics; |
| 572 | 12 | | this.playerCoords = playerCoords; |
| 572 | 13 | | } |
| | 14 | |
|
| | 15 | | public void ReportExpression(string expressionId) |
| | 16 | | { |
| 2 | 17 | | var location = playerCoords.Get(); |
| 2 | 18 | | analytics.SendAnalytic("used_emote", new Dictionary<string, string> |
| | 19 | | { |
| | 20 | | {"id", expressionId}, |
| | 21 | | {"parcel_location", $"{location.x},{location.y}"} |
| | 22 | | }); |
| 2 | 23 | | } |
| | 24 | | } |