|
|
@@ -173,8 +173,14 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
|
|
|
//开始录屏提示框
|
|
|
void showSucessInfo(status) {
|
|
|
- MyDialog.showDialog(context, '您已经完成比赛了吗,确认完成,那就点击下方完成竞赛按钮,上传本次成绩,祝您赢取大奖', title: '完成比赛', submitText: '我已完成比赛', onsubmit: () async {
|
|
|
-
|
|
|
+ MyDialog.showDialog(context, '',
|
|
|
+ textList: [
|
|
|
+ {"value": '您已经完成杀戮目标了吗?确定请点击', "isImportant": false},
|
|
|
+ {"value": '“我已完成比赛”', "isImportant": true},
|
|
|
+ {"value": '按钮。上传本次成绩,最后的名次稍后公布。祝您取得好成绩!', "isImportant": false}
|
|
|
+ ],
|
|
|
+ title: '完成比赛',
|
|
|
+ submitText: '我已完成比赛', onsubmit: () async {
|
|
|
HttpManager.post('playerInfo/update', data: {'id': playerInfo.id, 'statusFlag': status, 'endTime': DateTime.now().millisecondsSinceEpoch});
|
|
|
bool success = await ScreenStreamPlugin.stop();
|
|
|
|
|
|
@@ -363,7 +369,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
);
|
|
|
},
|
|
|
pageBuilder: (BuildContext context, _, __) {
|
|
|
- return CompetitionInformation(houseInfo);
|
|
|
+ return CompetitionInformation();
|
|
|
}));
|
|
|
}
|
|
|
|
|
|
@@ -411,6 +417,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
};
|
|
|
|
|
|
Future.delayed(Duration.zero, () async {
|
|
|
+ // showSucessInfo(3);
|
|
|
getRoomInfo('first');
|
|
|
userInfo = StoreProvider.of<AppState>(context).state.userInfo;
|
|
|
// showStart();
|
|
|
@@ -584,7 +591,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
);
|
|
|
},
|
|
|
pageBuilder: (BuildContext context, _, __) {
|
|
|
- return CompetitionInformation(houseInfo);
|
|
|
+ return CompetitionInformation();
|
|
|
}));
|
|
|
},
|
|
|
),
|
|
|
@@ -611,32 +618,51 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
Container(
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15),
|
|
|
child: Row(
|
|
|
- // mainAxisAlignment: MainAxisAlignment.center,
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
children: <Widget>[
|
|
|
- Image.asset(
|
|
|
- 'images/icon_renshu.png',
|
|
|
- width: 20,
|
|
|
- ),
|
|
|
- Text(
|
|
|
- (houseInfo != null ? (houseInfo.playerNumber ?? 0).toString() : '0') +
|
|
|
- '/' +
|
|
|
- (houseInfo != null ? houseInfo.maxNumber.toString() : '0'),
|
|
|
- style: TextStyle(fontSize: 14, fontWeight: FontWeight.w500, color: Color(0xFFB1B2C0)),
|
|
|
+ Row(
|
|
|
+ children: <Widget>[
|
|
|
+ Image.asset(
|
|
|
+ 'images/icon_renshu.png',
|
|
|
+ ),
|
|
|
+ Text(
|
|
|
+ (houseInfo != null ? (houseInfo.playerNumber ?? 0).toString() : '0') +
|
|
|
+ '/' +
|
|
|
+ (houseInfo != null ? houseInfo.maxNumber.toString() : '0'),
|
|
|
+ style: TextStyle(fontSize: 14, fontWeight: FontWeight.w500, color: Color(0xFFB1B2C0)),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
),
|
|
|
- Container(
|
|
|
- width: 30,
|
|
|
+
|
|
|
+ Row(
|
|
|
+ children: <Widget>[
|
|
|
+ Image.asset(
|
|
|
+ 'images/house2.png',
|
|
|
+ ),
|
|
|
+ Text('X${houseInfo.bonus}',
|
|
|
+ style: TextStyle(fontSize: 14, fontWeight: FontWeight.w500, color: Color(0xFFB1B2C0)),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
),
|
|
|
- Text.rich(TextSpan(children: [
|
|
|
- TextSpan(text: "模式 ", style: TextStyle(color: Colors.white30, fontSize: 14)),
|
|
|
- TextSpan(text: houseInfo.houseType == 0 ? '评分模式' : '吃鸡模式', style: TextStyle(color: Colors.white70, fontSize: 14)),
|
|
|
- ])),
|
|
|
- Container(
|
|
|
- width: 30,
|
|
|
+ // Container(
|
|
|
+ // width: 30,
|
|
|
+ // ),
|
|
|
+ Row(
|
|
|
+ children: <Widget>[
|
|
|
+ Image.asset(
|
|
|
+ 'images/icon_jisha.png',
|
|
|
+ ),
|
|
|
+ Text('在游戏中击败${houseInfo.killnumber}人',
|
|
|
+ style: TextStyle(fontSize: 14, fontWeight: FontWeight.w500, color: Color(0xFFB1B2C0)),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
),
|
|
|
- Text.rich(TextSpan(children: [
|
|
|
- TextSpan(text: "房间ID ", style: TextStyle(color: Colors.white30, fontSize: 14)),
|
|
|
- TextSpan(text: houseInfo.houseCode != null ? houseInfo.houseCode : '', style: TextStyle(color: Colors.white70, fontSize: 14)),
|
|
|
- ])),
|
|
|
+
|
|
|
+
|
|
|
+ // Container(
|
|
|
+ // width: 10,
|
|
|
+ // ),
|
|
|
+
|
|
|
],
|
|
|
),
|
|
|
),
|
|
|
@@ -662,95 +688,115 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
child: playerInfo != null
|
|
|
? Column(
|
|
|
children: <Widget>[
|
|
|
- ( playerInfo.statusFlag!=7&&playerInfo.statusFlag!=9&&!playerInfo.dataError)? Container(
|
|
|
- margin: EdgeInsets.symmetric(vertical: 10, horizontal: 15),
|
|
|
- padding: EdgeInsets.all(15),
|
|
|
- height: 80,
|
|
|
- decoration: BoxDecoration(
|
|
|
- color: Color(0xFF3A3E61),
|
|
|
- borderRadius: BorderRadius.only(
|
|
|
- topRight: Radius.circular(8), bottomLeft: Radius.circular(8), bottomRight: Radius.circular(8))),
|
|
|
- child: Column(
|
|
|
- crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text('和平精英游戏结果', style: TextStyle(color: Colors.white54, fontSize: 13)),
|
|
|
- Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text.rich(TextSpan(children: [
|
|
|
- TextSpan(text: "名次 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- TextSpan(
|
|
|
- text: '${myRank}',
|
|
|
- style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14)),
|
|
|
- ])),
|
|
|
- Text.rich(TextSpan(children: [
|
|
|
- TextSpan(text: "时长 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- TextSpan(
|
|
|
- text: playerInfo.liveTime != null ? '${playerInfo.liveTime}' : '0',
|
|
|
- style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14)),
|
|
|
- ])),
|
|
|
- Text.rich(TextSpan(children: [
|
|
|
- TextSpan(text: "评分 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- TextSpan(
|
|
|
- text: '${playerInfo.score}',
|
|
|
- style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14)),
|
|
|
- ])),
|
|
|
- ],
|
|
|
- )
|
|
|
- ],
|
|
|
- ),
|
|
|
- ):Container(),
|
|
|
+ // ( playerInfo.statusFlag!=7&&playerInfo.statusFlag!=9&&!playerInfo.dataError)?
|
|
|
Container(
|
|
|
- margin: EdgeInsets.symmetric(vertical: 10, horizontal: 15),
|
|
|
- padding: EdgeInsets.all(15),
|
|
|
- height: 140,
|
|
|
- decoration: BoxDecoration(
|
|
|
- color: Color(0xFF3A3E61),
|
|
|
- borderRadius: BorderRadius.only(
|
|
|
- topRight: Radius.circular(8), bottomLeft: Radius.circular(8), bottomRight: Radius.circular(8))),
|
|
|
- child: Column(
|
|
|
- crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text('比赛结果', style: TextStyle(color: Colors.white54, fontSize: 13)),
|
|
|
- Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text("参数成员 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- Text("${houseInfo.playerNumber}人 ",
|
|
|
- style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
- ],
|
|
|
- ),
|
|
|
- Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text("是否吃鸡 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- Text(playerInfo.ranking == 1 ? '是' : '否',
|
|
|
- style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
- ],
|
|
|
- ),
|
|
|
- Row(
|
|
|
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
- children: <Widget>[
|
|
|
- Text("获得奖牌 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
- img != ''
|
|
|
- ? Row(
|
|
|
- children: <Widget>[
|
|
|
- prefix1.Image.asset(
|
|
|
- img,
|
|
|
- width: 20,
|
|
|
- ),
|
|
|
- Text("+1",
|
|
|
+ width: double.infinity,
|
|
|
+ margin: EdgeInsets.symmetric(horizontal: 15, vertical: 10),
|
|
|
+ padding: EdgeInsets.symmetric(vertical: 10),
|
|
|
+ height: 40,
|
|
|
+ decoration:
|
|
|
+ BoxDecoration(color: Color(0xFFD4504B).withOpacity(0.1), borderRadius: BorderRadius.all(Radius.circular(4))),
|
|
|
+ child: Text(
|
|
|
+ (playerInfo.statusFlag != 7 && playerInfo.statusFlag != 9 && !playerInfo.dataError)
|
|
|
+ ? (playerInfo.houseRank < 3 ? '恭喜您,您获得了第${playerInfo.houseRank}名!' : '很遗憾您未能进入前三名,下次加油!')
|
|
|
+ : '很遗憾您本次上传的比赛结果解析失败',
|
|
|
+ style: prefix0.TextStyle(
|
|
|
+ color: Color(0xFFD4504B),
|
|
|
+ fontSize: 15,
|
|
|
+ ),
|
|
|
+ textAlign: TextAlign.center,
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ (playerInfo.statusFlag != 7 && playerInfo.statusFlag != 9 && !playerInfo.dataError)
|
|
|
+ ? Container(
|
|
|
+ margin: EdgeInsets.symmetric(vertical: 10, horizontal: 15),
|
|
|
+ padding: EdgeInsets.all(15),
|
|
|
+ height: 140,
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ color: Color(0xFF3A3E61),
|
|
|
+ borderRadius: BorderRadius.only(
|
|
|
+ topRight: Radius.circular(8), bottomLeft: Radius.circular(8), bottomRight: Radius.circular(8))),
|
|
|
+ child: Column(
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: <Widget>[
|
|
|
+ Text('比赛结果', style: TextStyle(color: Colors.white54, fontSize: 13)),
|
|
|
+ Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: <Widget>[
|
|
|
+ Text("参数成员 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
+ Text("${houseInfo.playerNumber}人 ",
|
|
|
+ style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: <Widget>[
|
|
|
+ Text("我的排名 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
+ Text('${playerInfo.houseRank}',
|
|
|
+ style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
+ children: <Widget>[
|
|
|
+ Text("获得奖牌 ", style: TextStyle(color: Colors.white, fontSize: 14)),
|
|
|
+ img != ''
|
|
|
+ ? Row(
|
|
|
+ children: <Widget>[
|
|
|
+ Image.asset(
|
|
|
+ img,
|
|
|
+ width: 20,
|
|
|
+ ),
|
|
|
+ Text("+1",
|
|
|
+ style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
+ ],
|
|
|
+ )
|
|
|
+ : Text("无",
|
|
|
style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
- ],
|
|
|
- )
|
|
|
- : Text("无", style: TextStyle(color: Color(0xFFFFB726), fontWeight: FontWeight.w500, fontSize: 14))
|
|
|
- ],
|
|
|
+ ],
|
|
|
+ )
|
|
|
+ ],
|
|
|
+ ),
|
|
|
+ )
|
|
|
+ : Container(
|
|
|
+ margin: EdgeInsets.symmetric(vertical: 10, horizontal: 15),
|
|
|
+ padding: EdgeInsets.all(15),
|
|
|
+ height: 239,
|
|
|
+ width: double.infinity,
|
|
|
+ decoration: BoxDecoration(
|
|
|
+ color: Color(0xFF3A3E61),
|
|
|
+ borderRadius: BorderRadius.only(
|
|
|
+ topRight: Radius.circular(8), bottomLeft: Radius.circular(8), bottomRight: Radius.circular(8))),
|
|
|
+ child: Column(
|
|
|
+ crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
+ children: <Widget>[
|
|
|
+ Text(
|
|
|
+ '造成此情况等原因可能是:',
|
|
|
+ style: TextStyle(color: Colors.white54, fontSize: 13),
|
|
|
+ ),
|
|
|
+ Container(
|
|
|
+ height: 10,
|
|
|
+ ),
|
|
|
+ Text(
|
|
|
+ '1、没有实际进行游戏比赛 ',
|
|
|
+ style: TextStyle(color: Colors.white, fontSize: 13),
|
|
|
+ ),
|
|
|
+ Text(
|
|
|
+ '2、使用作弊手段进行游戏 ',
|
|
|
+ style: TextStyle(color: Colors.white, fontSize: 13),
|
|
|
+ ),
|
|
|
+ Text(
|
|
|
+ '3、手机性能或电量过低,在运行和平精英游戏时自动将我们平台APP从后台进程中退掉 ',
|
|
|
+ style: TextStyle(color: Colors.white, fontSize: 13),
|
|
|
+ ),
|
|
|
+ Text(
|
|
|
+ '4、游戏时间过长,没有在最大时间内返回平台APP点击结束游戏 ',
|
|
|
+ style: TextStyle(color: Colors.white, fontSize: 13),
|
|
|
+ ),
|
|
|
+ ],
|
|
|
+ ),
|
|
|
)
|
|
|
- ],
|
|
|
- ),
|
|
|
- )
|
|
|
],
|
|
|
)
|
|
|
: Container(),
|
|
|
@@ -806,7 +852,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
Container(
|
|
|
margin: EdgeInsets.only(left: 6),
|
|
|
child: Text(
|
|
|
- '×1',
|
|
|
+ '×${houseInfo.bonus}',
|
|
|
style: TextStyle(color: Colors.white, fontSize: 16, fontWeight: FontWeight.w500),
|
|
|
),
|
|
|
),
|
|
|
@@ -853,7 +899,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
Container(
|
|
|
margin: EdgeInsets.only(left: 6),
|
|
|
child: Text(
|
|
|
- '×1',
|
|
|
+ '×${houseInfo.bonus}',
|
|
|
style: TextStyle(color: Colors.white, fontSize: 16, fontWeight: FontWeight.w500),
|
|
|
),
|
|
|
),
|
|
|
@@ -873,7 +919,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
height: 88,
|
|
|
- child: LinearButton(btntext: '房间已经开始,加入通道关闭', colorList: [Color(0xFFC99C09), Color(0xFFC7873E)], textColor: Color(0xFF252532))
|
|
|
+ child: LinearButton(btntext: '房间已经开始,加入通道关闭', colorList: [Color(0xFFB34A4A), Color(0xFFB34A4A)], textColor: Color(0xFF252532))
|
|
|
// RaisedButton(
|
|
|
// disabledColor: Color(0xFFC2524D),
|
|
|
// disabledTextColor: Color(0xFF252532),
|
|
|
@@ -939,14 +985,14 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
height: 88,
|
|
|
- child: LinearButton(btntext: '等待开始中', colorList: [Color(0xFFAF4946), Color(0xFFAF4946)], textColor: Color(0xFF252532)));
|
|
|
+ child: LinearButton(btntext: '等待开始中', colorList: [Color(0xFFB34A4A), Color(0xFFB34A4A)], textColor: Color(0xFF252532)));
|
|
|
}
|
|
|
} else if (isJoin && statusFlag == 8) {
|
|
|
return Container(
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
height: 88,
|
|
|
- child: LinearButton(btntext: '正在努力解析视频中', colorList: [Color(0xFFAF4946), Color(0xFFAF4946)], textColor: Color(0xFF252532))
|
|
|
+ child: LinearButton(btntext: '正在努力解析视频中', colorList: [Color(0xFFB34A4A), Color(0xFFB34A4A)], textColor: Color(0xFF252532))
|
|
|
// RaisedButton(
|
|
|
// disabledColor: Color(0xFFC2524D),
|
|
|
// disabledTextColor: Color(0xFF252532),
|
|
|
@@ -966,10 +1012,10 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
height: 88,
|
|
|
- child: LinearButton(btntext: '预计还有 ' + getSecondsMIn(_time) + ' 结算', colorList: [Color(0xFFAF4946), Color(0xFFAF4946)], textColor: Color(0xFF252532)),
|
|
|
+ child: LinearButton(btntext: '预计还有 ' + getSecondsMIn(_time) + ' 结算', colorList: [Color(0xFFB34A4A), Color(0xFFB34A4A)], textColor: Color(0xFF252532)),
|
|
|
);
|
|
|
} else if (statusFlag == 4 && tabIndex == 0) {
|
|
|
- if (isJoin && canAppeal && appealState == 0 &&playerInfo!=null&&(playerInfo.statusFlag==9||playerInfo.statusFlag==7||playerInfo.dataError)) {
|
|
|
+ if (isJoin && canAppeal && appealState == 0 && playerInfo != null && (playerInfo.statusFlag == 9 || playerInfo.statusFlag == 7 || playerInfo.dataError)) {
|
|
|
return Container(
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
@@ -993,7 +1039,7 @@ class RoomInfoState extends State<RoomInfo> with SingleTickerProviderStateMixin
|
|
|
width: double.infinity,
|
|
|
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 20),
|
|
|
height: 88,
|
|
|
- child: LinearButton(btntext: '已提交申诉', colorList: [Color(0xFFAF4946), Color(0xFFAF4946)], textColor: Color(0xFF252532)));
|
|
|
+ child: LinearButton(btntext: '已提交申诉', colorList: [Color(0xFFB34A4A), Color(0xFFB34A4A)], textColor: Color(0xFF252532)));
|
|
|
} else {
|
|
|
return Container();
|
|
|
}
|