URL Request Tutorial

Url Code: 300 Not Completed

A lot of people are asking me that how the URL trigger works. By far with the collaboration with Nyove, we had finally found out a way to making the server read our request and give us output.

Keywords that PB2 supports to export to your server

  1. map_id

  2. user_uid

  3. user_login

Understanding URL Trigger Action

To first understand, we need to understand how HTTP Requests work.

When you type a URL into the address bar and enter, what your computer doing is actually sending a HTTP request to the indicated URL. Think of HTTP Request as just data requesting for webpage. The URL actually refers to some web server, and this web server will return you a HTML file. HTML file are just file your google chrome can be used to display.

Example :

  1. I type www.google.com and hit enter.

  2. My computer sends a HTTP request to www.google.com, which is a web server in google.

  3. The web server responds by sending back a file to me.

  4. Google chrome reads the file and displays it according (A web page is displayed)

When you send a HTTP request to a server, you can put in variables into the request and then send it over to the server. The server may process the variables and return a customized file depending on the variable.

Example :

  1. My computer sends a HTTP request to www.youtube.com, with a variable of v=NFTemk99fLU embedded in the request.

  2. The web server processes the variable and knows that I am requesting for a certain video.

  3. The web server sends back a file containing the video I requested (in the URL)

  4. Google chrome reads the customized file and displays it.

  5. My requested video is now displayed.

Defining Errors from URL request

There also few possible error codes that will replace ''loading...'' once some error will happen:

  • error 1 - Unable to get right to send requests to PB2 server

  • error 3 - IO Error

  • error 4 - URL requests are not supported on player's computer (should not really happen)

  • error 5 - Player who sent request has his account disabled on PB2 website

  • not logged in - Player who sent request is not logged into any account

  • Error: URL needs to start with http:// or https:// (got URL instead)

Variable 'B' will get contents of requested URL if no error happened.

https://www.plazmaburst2.com/pb2/server.php?rq=srvrs -> server check

https://www.plazmaburst2.com/date.php -> grab the date (requires additional parameters to make it work)

Last updated