【发布时间】:2016-02-08 16:43:13
【问题描述】:
我正在更新我的文本冒险引擎并想为故事的每个部分添加背景。目前的问题是让背景出现在它们各自的部分。
public var parts:Object =
{
"0":
{
"text":"You're name is David, a agoraphobic 24 year old. It's 12:32 AM, you were woken abruptly by glass smashing inside your house.",
"choices":
{
"response1":
{
"text":"Investigate",
"nextPart":"1"
},
"response2":
{
"text":"Ignore it. You need your beauty sleep.",
"nextPart":"2"
}
},
},
我会添加什么,以便我可以在每个部分显示背景。
这是我目前拥有的背景(在部分之后定义)
[Embed(source = "../Backgrounds/old-bedroom.png")]
public var Background1:Class
public var Background1PNG:BitmapData
public var BG1:Bitmap = new Background1
public var bR:Sprite = new Sprite();
[Embed(source = "../Backgrounds/img010.jpg")]
public var Background2:Class
public var Background2PNG:BitmapData
public var BG2:Bitmap = new Background2
public var lR:Sprite = new Sprite();
【问题讨论】:
标签: arrays actionscript-3