Quote:
Originally Posted by Dusan01
|
Hello Dusan01,
I think the best option is to use an api to retrieve the weather status, of course, that will depend on your level of scripting but it's not that hard,
Use the
http://www.previsaodotempo.org/api api to retrieve the weather status of all major cities around the world and upstate cities in Brazil (because it is a Brazilian api, if you know some other api feel free to use it).
Use the HTTP
https://sampwiki.blast.hk/wiki/HTTP class to make a request to the api endpoint, like so:
To see a live example of what is returned and understand a lil bit more from these requests just try to access these "links" above in your browser and, sure, you can change the city variable to whatever you wish.
Use the DJson
https://sampforum.blast.hk/showthread.php?tid=48439 package to handle the response format (json) inside Pawn.
Best regards.