- Home /
Unity Web Player in Facebook: How to set the application name ?
We created a Facebook Application by using Unity Web Player.
The bar on the right side of the FB screen shows the caption "User x is using Unity Web Player | Webplayer"
Is it possible to change this to the application name?
For testing purposes: http://apps.facebook.com/buildville
I had a look at parametrizing the embedUnity-Call (http://unity3d.com/support/documentation/Manual/Working%20with%20UnityObject.html), but there seems not to be an additional parameter.
The HTML script starts:
<head>
<title>BuildVille</title>
<meta http-equiv="CACHE-CONTROL" content="NO-CACHE">
<script type="text/javascript" src="facebookUnity.js"></script>
<script type="text/javascript" src="http://webplayer.unity3d.com/download_webplayer-3.x/3.0/uo/UnityObject.js"></script>
<script type="text/javascript">
<!--
var uid;
function setUID(puid) {
uid = puid;
}
function GetUnity() {
if (typeof unityObject != "undefined") {
return unityObject.getObjectById("unityPlayer");
}
return null;
}
if (typeof unityObject != "undefined") {
unityObject.firstFrameCallback= function() {
GetUnity().SendMessage( "FacebookController", "SetUID", "" +uid );
checkAndSendRequestId();
}
unityObject.embedUnity("unityPlayer", "WebPlayer.unity3d", 720, 540, params);
}
-->
</script>
Answer by Waz · Aug 30, 2011 at 11:27 AM
That string is normally in the default HTML generated when you build a Unity WebPlayer - as the HTML document title, nothing to do with the embedded unity object.
I have changed the document title ... but this did not help I added the script to the question.
In the meantime it worked with no other action then changing the title ... maybe a cache issue?