105 posts
Posted 08 November 2017 - 04:28 PM
Is it possible to get some sort of unique identifier for a server a program is running on? (Like an IP & port combination)
I guess I could use a php page which returns an IP, but multiple servers on the same IP would still be an issue in that case.
Edited on 08 November 2017 - 03:30 PM
3057 posts
Location
United States of America
Posted 08 November 2017 - 04:45 PM
Not from within computercraft.
477 posts
Location
Germany
Posted 08 November 2017 - 07:30 PM
As KingofGames said it's not possible, you can only get the IP address.
But if you want to do that you don't need to write your own script there are already sites like
this
105 posts
Posted 08 November 2017 - 11:18 PM
As KingofGames said it's not possible, you can only get the IP address.
But if you want to do that you don't need to write your own script there are already sites like
this
Yeah I am aware, but I'd prefer hosting it myself given the ide aI have in mind, but it would require being able to uniquely identify a server, this way virtual hosts hosting multiple servers on one IP would be an issue.
2427 posts
Location
UK
Posted 09 November 2017 - 11:15 AM
Could you use something about the world on the server to disambiguate shared IPs??
105 posts
Posted 09 November 2017 - 08:05 PM
Could you use something about the world on the server to disambiguate shared IPs??
If there was a way to identify a world with CC, yes. But I don't think there is.
2427 posts
Location
UK
Posted 09 November 2017 - 09:33 PM
Could you use something about the world on the server to disambiguate shared IPs??
If there was a way to identify a world with CC, yes. But I don't think there is.
I was thinking of using the GPS position, it's unlikely that two computers would have the same location in two different worlds, the program will need players to know which world this is to tell the computer that.