Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support displaying CTF scores #103

Merged
merged 2 commits into from
Sep 15, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions titanfall2-rp/Titanfall2Api.MpGameStats.cs
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,26 @@ public CaptureTheFlag(Titanfall2Api tf2Api)
{
_tf2Api = tf2Api;
}

/// <summary>
/// Get the score of team 1. Whether this is your team or the enemy's doesn't always stay the same.
/// I'm not sure why. This is something that I need some help figuring out.
/// </summary>
/// <returns>the score of team 1</returns>
public int GetTeam1Score()
{
return _tf2Api._sharp!.Memory.Read<int>(_tf2Api._engineDllBaseAddress + 0x1121814C);
}

/// <summary>
/// Get the score of team 2. Whether this is your team or the enemy's doesn't always stay the same.
/// I'm not sure why. This is something that I need some help figuring out.
/// </summary>
/// <returns>the score of team 2</returns>
public int GetTeam2Score()
{
return _tf2Api._sharp!.Memory.Read<int>(_tf2Api._engineDllBaseAddress + 0x11218CA0);
}
}

public class LastTitanStanding
Expand Down