Skip to content
This repository has been archived by the owner on Feb 13, 2023. It is now read-only.

Commit

Permalink
added cross-world dx9
Browse files Browse the repository at this point in the history
  • Loading branch information
Stateford committed Nov 16, 2017
1 parent 3fb990c commit 82ee6b6
Show file tree
Hide file tree
Showing 14 changed files with 79 additions and 13 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Changelog
All notable changes to this project will be documented in this file.

##[1.0.0]
- Cross-world party support for DX9

## [0.0.6]
### Added
- Cross-world party support for DX11
Expand Down
10 changes: 2 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,11 @@ This program reads from process memory. Use at your own risk!
This program reads the names of party members by memory and opens their username in a search page in your default browser.

#### EXAMPLE
![](https://media.giphy.com/media/xUOxfkTf6NHqzHwgyQ/giphy.gif)

[Youtube](https://youtu.be/r9TKVYfq_b0)

#### Known Issues
- Doesn't update cross-world parties on DX9
- Lists previous members in the party list until someone new overwrites their position (thank SE for this, still looking for solution)
![](https://i.imgur.com/anW8rD2.png)
[Youtube](https://youtu.be/4OjrkHsZ1fM)

#### TODO
----------------
- Cross-world Parties for DX9
- Add stats directly to program
- UI

Expand Down
2 changes: 2 additions & 0 deletions main.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#include "src/menu.h"
#include <Windows.h>

int main()
{
SetConsoleTitle(TEXT("FFXIV Party Logs"));
Menu menu;
menu.start();

Expand Down
5 changes: 3 additions & 2 deletions src/arch/arch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,15 +75,16 @@ void Arch::filterAllies()

}


void Arch::updateNames(Process* proc, int &partyMembers)
{
for (auto &p : allies_)
{
ReadProcessMemory(proc->getHandle(), (void*)(exe_->getAddress() + p->address_), &p->name_, 80, 0);
p->updateName(proc, exe_);
}
for(auto &p : alliesCW_)
{
ReadProcessMemory(proc->getHandle(), (void*)(p->address_), &p->name_, 80, 0);
p->updateName(proc, exe_);
}

filterAllies();
Expand Down
1 change: 1 addition & 0 deletions src/arch/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include "../player/player.h"
#include "../player/you.h"
#include "../player/ally.h"
#include "../player/allyCW.h"

class Arch
{
Expand Down
4 changes: 2 additions & 2 deletions src/arch/x64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ void x64::createAllies(Process* proc)

ReadProcessMemory(proc->getHandle(), (void*)address, &address, sizeof(DWORD64), 0);
address += 0x2E8;
alliesCW_.push_back(new Ally(address));
alliesCW_.push_back(new AllyCW(address));


for(int i = 0; i < 6; i++)
{
alliesCW_.push_back(new Ally(address += 0x48));
alliesCW_.push_back(new AllyCW(address += 0x48));
}
}

Expand Down
18 changes: 17 additions & 1 deletion src/arch/x86.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ x86::~x86()

void x86::createAllies(Process* proc)
{
allies_.reserve(8);
// dx9 32-bit offsets
allies_.push_back(new YOU(0x115E431));
allies_.push_back(new Ally(0x117AA30));
Expand All @@ -47,6 +46,22 @@ void x86::createAllies(Process* proc)
allies_.push_back(new Ally(0x117B4D0));
allies_.push_back(new Ally(0x117B6F0));
allies_.push_back(new Ally(0x117B910));


alliesCW_.push_back(allies_[0]); // YOU

DWORD address = exe_->getAddress();
address += 0x010287A4;

ReadProcessMemory(proc->getHandle(), (void*)address, &address, sizeof(DWORD64), 0);
address += 0x2E0;
alliesCW_.push_back(new AllyCW(address));

for (int i = 0; i < 6; i++)
{
alliesCW_.push_back(new AllyCW(address += 0x48));
}

}


Expand All @@ -58,4 +73,5 @@ void x86::updateNumberOfPartyMembers(Process *proc, int &partyMembers)
void x86::checkCrossWorldParty(Process* proc)
{
// do nothing for the time being
ReadProcessMemory(proc->getHandle(), (void*)(exe_->getAddress() + 0x1179BE4), &inCrossWorldParty_, 1, 0);
}
5 changes: 5 additions & 0 deletions src/player/ally.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,8 @@ void Ally::display()
{
std::cout << name_ << "\n";
}

void Ally::updateName(Process* proc, Module* exe)
{
ReadProcessMemory(proc->getHandle(), (void*)(exe->getAddress() + address_), &name_, 80, 0);
}
1 change: 1 addition & 0 deletions src/player/ally.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ class Ally : public Player
Ally(DWORD64);
~Ally();
void display();
void updateName(Process*, Module*);
};
22 changes: 22 additions & 0 deletions src/player/allyCW.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#include "allyCW.h"
#include <iostream>

AllyCW::AllyCW(DWORD64 address)
{
address_ = address;
}

AllyCW::~AllyCW()
{

}

void AllyCW::display()
{
std::cout << name_ << "\n";
}

void AllyCW::updateName(Process* proc, Module* exe)
{
ReadProcessMemory(proc->getHandle(), (void*)(address_), &name_, 80, 0);
}
12 changes: 12 additions & 0 deletions src/player/allyCW.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#pragma once

#include "player.h"

class AllyCW : public Player
{
public:
AllyCW(DWORD64);
~AllyCW();
void display();
void updateName(Process*, Module*);
};
3 changes: 3 additions & 0 deletions src/player/player.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
#include <map>
#include <string>
#include <Windows.h>
#include "../process/module.h"
#include "../process/process.h"

class Player
{
Expand All @@ -16,6 +18,7 @@ class Player
DWORD64 address_;
char name_[80];
virtual void display() = 0;
virtual void updateName(Process*, Module*) = 0;
bool characterCheck();
void charRequest(std::wstring, std::vector<std::wstring>, std::wstring, std::wstring&, int&);
bool getCharId();
Expand Down
5 changes: 5 additions & 0 deletions src/player/you.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,8 @@ void YOU::display()
{
std::cout << "YOU (" << name_ << ")" << "\n";
}

void YOU::updateName(Process* proc, Module* exe)
{
ReadProcessMemory(proc->getHandle(), (void*)(exe->getAddress() + address_), &name_, 80, 0);
}
1 change: 1 addition & 0 deletions src/player/you.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ class YOU : public Player
YOU(DWORD64);
~YOU();
void display();
void updateName(Process*, Module*);
};

0 comments on commit 82ee6b6

Please sign in to comment.