Add Asset Packet
This packet is used to send the client the URL of an online content repository, if available.
This commit is contained in:
		
							parent
							
								
									bea9fc1a05
								
							
						
					
					
						commit
						8a9bb6dc69
					
				@ -501,6 +501,16 @@ public:
 | 
			
		||||
  // The file name of the log file in base/logs.
 | 
			
		||||
  QString log_filename;
 | 
			
		||||
 | 
			
		||||
  /**
 | 
			
		||||
   * @brief A QString of an URL that defines the content repository
 | 
			
		||||
   *        send by the server.
 | 
			
		||||
   *
 | 
			
		||||
   * @details Introduced in Version 2.9.2.
 | 
			
		||||
   *        Addresses the issue of contenturl devlivery for WebAO
 | 
			
		||||
   *        without relying on someone adding the link manually.
 | 
			
		||||
   */
 | 
			
		||||
  QString asset_url;
 | 
			
		||||
 | 
			
		||||
  void initBASS();
 | 
			
		||||
  static void load_bass_opus_plugin();
 | 
			
		||||
  static void CALLBACK BASSreset(HSTREAM handle, DWORD channel, DWORD data,
 | 
			
		||||
 | 
			
		||||
@ -703,6 +703,16 @@ void AOApplication::server_packet_received(AOPacket *p_packet)
 | 
			
		||||
    w_courtroom->on_authentication_state_received(authenticated);
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
 //AssetURL Packet
 | 
			
		||||
  else if (header == "ASS") {
 | 
			
		||||
    if (f_contents.size() > 1) { // This can never be more than one link.
 | 
			
		||||
      goto end;
 | 
			
		||||
    }
 | 
			
		||||
    QUrl t_asset_url = QUrl::fromPercentEncoding(f_contents.at(0).toUtf8());
 | 
			
		||||
    if (t_asset_url.isValid())
 | 
			
		||||
    asset_url = t_asset_url.toString();
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
end:
 | 
			
		||||
 | 
			
		||||
  delete p_packet;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user