Originally Posted by
DrakeFish
I'm unsure if this is what you want, but here's what I quickly found from the LUA API you provided. All the following offsets are based on 0x00400000.
RealID Friends Count: 0xF32108
RealID Friends Array ptr: 0xF3210C
The realid structure in this array is 0x338 bytes long, and you can find the the friend's name at 0x10. I would guess from the function code that the ID is the first value you find in that structure, it seems to be somekind of personal index as the values are very small. Have fun.
On a side note, if you couldn't find the real ID friends names in memory (and if you use CE), make sure that you check the Writable/Executable checkboxes depending on what you need (just "half-check" them all to be sure to scan whole memory).