-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFInvalidURL.as
More file actions
41 lines (33 loc) · 959 Bytes
/
FInvalidURL.as
File metadata and controls
41 lines (33 loc) · 959 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package Framework
{
import Framework.FG;
import Framework.Utils.FInternet;
import Framework.GUI.Buttons.FRectButton;
import Framework.GUI.FText;
public class FInvalidURL extends FScene
{
public function FInvalidURL():void
{
super();
}
override public function Create():void
{
super.Create();
var b:FRectButton = new FRectButton(0, 0, 150, 40, "Play " + FG.gameName, goToGame);
b.CenterX().CenterY();
Add(b);
var t:FText = new FText(0, 0, "Hey! It looks like somebody copied this game without my permission. Click the button below to go to \n\n"+FG.gameURL+"\n\nand play the game at my site. Thanks, and have fun!");
t.textAlign = FText.ALIGN_CENTER;
t.UpdateFormat();
t.CenterX().CenterY(-100);
Add(t);
graphics.beginFill(0xFFFFFF);
graphics.drawRect(0, 0, FG.width, FG.height);
graphics.endFill();
}
private function goToGame():void
{
FInternet.GoToURL("http://"+FG.gameURL);
}
}
}