[DiscordArchive] ```c
[DiscordArchive] ```c
Archived author: MaxtorCoder • Posted: 2025-08-15T21:19:07.607000+00:00
Original source
```c
void __fastcall sub_1434C6040(blz::unordered_map$int32_t$blz::pair$int_const$JamTraitConfig *a1, __int64 a2, int *a3)
{
blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig **m_buckets; // r11
unsigned __int64 v5; // rdx
unsigned __int64 m_bucket_count; // rbx
unsigned __int64 v7; // rax
blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig **v8; // r8
blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig *v9; // rax
blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig **i; // rcx
__int128 v11; // [rsp+0h] [rbp-28h]
blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig **v12; // [rsp+10h] [rbp-18h]
m_buckets = a1->m_buckets;
if ( m_buckets )
{
v5 = *a3;
m_bucket_count = a1->m_bucket_count;
v7 = 0xC4CEB9FE1A85EC53uLL * ((0xFF51AFD7ED558CCDuLL * (v5 ^ (v5 >> 0x21))) ^ ((0xFF51AFD7ED558CCDuLL * (v5 ^ (v5 >> 0x21))) >> 0x21));
v8 = &m_buckets[(v7 ^ (v7 >> 0x21)) & (a1->m_bucket_count - 1)];
v9 = *v8;
for ( i = v8; v9; v9 = v9->next )
{
if ( (_DWORD)v5 == v9->val.first )
{
break;
}
i = &v9->next;
}
if ( !*i )
{
v8 = &m_buckets[m_bucket_count];
}
*(_QWORD *)&v11 = *i;
v12 = &m_buckets[m_bucket_count];
*((_QWORD *)&v11 + 1) = v8;
}
else
{
*((_QWORD *)&v11 + 1) = 8 * a1->m_bucket_count;
v12 = (blz::chained_hash_node$blz::pair$int32_t$blz::pair$int_const$JamTraitConfig **)*((_QWORD *)&v11 + 1);
*(_QWORD *)&v11 = 0;
}
*(_OWORD *)a2 = v11;
*(_QWORD *)(a2 + 0x10) = v12;
}
```
I assume that `a2` her is the iterator then?
Archived author: Tea • Posted: 2025-08-15T21:21:26.841000+00:00
Original source
yes, return type isnt void
Archived author: Tea • Posted: 2025-08-15T21:21:30.024000+00:00
Original source
this is .find()
Archived author: MaxtorCoder • Posted: 2025-08-15T21:23:56.578000+00:00
Original source
Makes sense
Archived author: MaxtorCoder • Posted: 2025-08-15T21:25:10.160000+00:00
Original source
If I do `blz::unordered_map<int, JamTraitConfig>` btw I get an incorrect accessor
![[Image: image.png?ex=690c697c&is=690b17fc&hm=b77...cde8e6cb8&]](https://cdn.discordapp.com/attachments/376457124726702080/1406025981961048175/image.png?ex=690c697c&is=690b17fc&hm=b77fb88c77a9b0c882d5328312fec768c8e9deadd8b676322bf097ccde8e6cb8&)
Archived author: MaxtorCoder • Posted: 2025-08-15T21:25:16.815000+00:00
Original source
As seen here
![[Image: image.png?ex=690c697c&is=690b17fc&hm=b77...cde8e6cb8&]](https://cdn.discordapp.com/attachments/376457124726702080/1406025981961048175/image.png?ex=690c697c&is=690b17fc&hm=b77fb88c77a9b0c882d5328312fec768c8e9deadd8b676322bf097ccde8e6cb8&)
Archived author: MaxtorCoder • Posted: 2025-08-15T21:25:33.210000+00:00
Original source
It goes into `LoadoutName` instead of just the `JamTraitConfig` instance
Archived author: MaxtorCoder • Posted: 2025-08-15T21:26:22.692000+00:00
Original source
```c
struct blz::pair$int32_t$JamTraitConfig // sizeof=0x19C
{ // XREF: blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig/r
int32_t first;
JamTraitConfig second;
};
struct __declspec(align(8)) blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig // sizeof=0x1A8
{
blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig *next;
blz::pair$int32_t$JamTraitConfig val;
// padding byte
// padding byte
// padding byte
// padding byte
};
struct blz::unordered_map::iterator$int32_t$JamTraitConfig // sizeof=0x18
{ // XREF: blz::pair$blz::unordered_map::iterator$int32_t$JamTraitConfig$bool/r
blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig *node;
blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig **bucket;
blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig **end;
};
struct blz::pair$blz::unordered_map::iterator$int32_t$JamTraitConfig$bool // sizeof=0x20
{
blz::unordered_map::iterator$int32_t$JamTraitConfig first;
bool second;
// padding byte
// padding byte
// padding byte
// padding byte
// padding byte
// padding byte
// padding byte
};
struct blz::unordered_map$int32_t$JamTraitConfig // sizeof=0x20
{
unsigned __int64 m_bucket_count;
blz::chained_hash_node$blz::pair$int32_t$JamTraitConfig **m_buckets;
unsigned __int64 m_entry_count;
float m_max_load_factor;
// padding byte
// padding byte
// padding byte
// padding byte
};
```
Structs from IDA, I am not sure if this is incorrect then
Archived author: Tea • Posted: 2025-08-15T21:27:43.655000+00:00
Original source
JamTraitConfig has a vector in it right? for entries
Archived author: MaxtorCoder • Posted: 2025-08-15T21:27:50.410000+00:00
Original source
Yeah