Closed DrDelay closed 8 years ago
I was actually looking into the same issue. For some reason it doesnt use the full namespace for TeamColor
, but it uses it for other stuff like \POGOProtos\Data\Player\PlayerAvatar
. Not sure why, though. I am looking into the code for protoc-gen-php
to see if I can figure it out. Worst case scenario we can always write a script that replaces these Enums with their full namespaces. Not very clean, but that should work.
Regarding the compilation: did you do sudo apt-get install libprotobuf-dev protobuf-compiler
first?
Oh and if that doesn't work you can run ./install-protobuf.sh
When the Data classes use consts from BadgeType , Gender , ... (I tried GetPlayer) a PHP fatal error arises because they are in another namespace (
\POGOProtos\Enums
). If I manually adduse POGOProtos\Enums\TeamColor;
etc. to the top of the affected files this problem is solved, but I guess the class generation should somehow do this automatically.I would try to look for a way myself too, but I can't get pass this error compiling the protoc-gen-php tool:
Since you have it working, any chance you know what I'm doing wrong there?