yesterday studied very much since hmm plugin has some issue.
turns out i implemented stun wrong since not knowing how stun works and then i had to implement some additional details like implementing additional routines there but initial test hadnt worked but i believe i would make it work. i had to check out intrinsic details of webrtc library from search engine suggestions for how to use ip allocator for stun setup.
but initial test of it and self coded router ping to the module were done such changes to keep stun working even if stun server is closed from webrtc side which what needs to be done just get public ip from stun then close webrtc then ping yourself the ip port from plugin with a task there that runs every 5 seconds for the udp ports.
but maybe works maybe firewall related issue.
i carried game server port to 8888 from 7777 (since this plugin has some stun logic and i thought lets not use 7777 in case there is port forwarding at router side) and also i set a static port of 8889 to clnt opent udp side receiver port. (that required reiimplementing some network module class).
and then i did got stun ips for 2 ports from stun servers via webrtc native libs then closed it and initiated ping task to continue pinging the router port with keep-alive packet. but then somehow initial test hadnt worked out.
maybe its because somehow the network interface the unreal game server opens 0.0.0.0 ip and the network interface port allocator of the stun port gatherer of peer connection of webrtc native lib were different network interfaces. dunno. or maybe the unreal game server's 8888 internal computer side port were blocked by firewall maybe. dunno why it hadnt worked out in first test. but might have some issue might need modifications etc etc. but i guess i might make it work this method of using webrtc to get a stun ip then asap initiating at plugin side a task to continue pinging the ip with keep-alive packages and then so.
hmm so my intiial method were very stupidly wrong. it used the public router ip in unreal engine side game server ip port which of course hadnt worked out :) (I coded that because i hadnt knew it were the router's public ip and not the computer's ip since hadnot thought of how stun might work idiotly and hadnt investigated either very much of such details and coded it very stupidly like that initially :) ) tomorrow fixed that but initial test hadnt worked out. but would wishfully somehow fix it.
Yorumlar
Yorum Gönder