fighting_room.wxml 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <view class='header'>
  2. <view class='animated lightSpeedIn-left '>
  3. <image src='{{userInfo_me.avatarUrl}}'></image>
  4. <view style='font-size:26rpx'>{{userInfo_me.nickName}}</view>
  5. <view wx:if="{{game_over}}">
  6. <text style='font-size:80rpx'>{{scoreMyself}}</text>分</view>
  7. </view>
  8. <view class='countdown animated rubberBand' wx:if="{{game_over ? false : true}}">{{countdown}}</view>
  9. <view class='animated lightSpeedIn-right'>
  10. <image src='{{userInfo_others.avatarUrl}}'></image>
  11. <view style='font-size:26rpx'>{{userInfo_others.nickName}}</view>
  12. <view wx:if="{{game_over}}">
  13. <text style='font-size:80rpx'>{{score_others}}</text>分 </view>
  14. </view>
  15. </view>
  16. <view class='summarize animated flipInX' wx:if="{{game_over}}">
  17. <image src="../../imgs/{{win==2? 'PK_equal': win==1?'PK_success' : 'PK_fail'}}.svg" style='width:300rpx;height:300rpx;'></image>
  18. </view>
  19. <view class='body' wx:if="{{game_over ? false : true}}">
  20. <view class='animated animated_zoomIn {{zoomIn}} {{zoomOut}}' wx:if="{{question ? false : true}}">
  21. <image src='../../imgs/VS.svg' style='width:600rpx;height:600rpx;'></image>
  22. </view>
  23. <view class='title animated zoomIn'>{{question.ask}}</view>
  24. <view class='content animated fadeIn' wx:if="{{question}}">
  25. <view>
  26. <view>{{scoreMyself}}</view>
  27. <view class='process'>
  28. <view class='process_son' style='height: {{scoreMyself/500*100}}%;'></view>
  29. </view>
  30. </view>
  31. <view style='width:80%;' class='animated {{animate_showChoice}}' wx:if="{{animate_showChoice}}">
  32. <view wx:for="{{question.answer}}" bindtap='answer' data-index="{{index}}" data-right="{{item.right}}" class="{{index==clickIndex&&clickIndex!=='' ? answerColor : ''}} {{index==status_users_others.userChoose&&status_users_others.userChoose!=='' ? status_users_others.answerColor : ''}} {{item.right ? animate_rightAnswer:''}} answer">
  33. <view class="invisible {{index==clickIndex&&clickIndex!==''&&answerColor=='right' ? 'sign' : ''}}">○</view>
  34. <view class="invisible {{index==clickIndex&&clickIndex!==''&&answerColor=='error' ? 'sign' : ''}}">×</view>
  35. <view style='width:100%;'>{{item.answer}}</view>
  36. <view class="invisible {{index==status_users_others.userChoose&&status_users_others.userChoose!==''&&status_users_others.answerColor=='right' ? 'sign' : ''}}" style='left: 88%;'>○</view>
  37. <view class="invisible {{index==status_users_others.userChoose&&status_users_others.userChoose!==''&&status_users_others.answerColor=='error' ? 'sign' : ''}}" style='left: 88%;'>×</view>
  38. </view>
  39. </view>
  40. <view>
  41. <view>{{score_others}}</view>
  42. <view class='process'>
  43. <view class='process_son' style='height: {{score_others/500*100}}%;'></view>
  44. </view>
  45. </view>
  46. </view>
  47. </view>
  48. <view class='body_summarize animated flipInX' wx:if="{{game_over ? true : false}}">
  49. <view class='exp'>
  50. <image src='../../imgs/exp.svg'></image>
  51. <view style='margin-left:20rpx;'>{{win===2 ? '+0' : win===1 ?'+10':'-10'}}</view>
  52. </view>
  53. <view>
  54. <button bindtap='continue_fighting'>继续挑战</button>
  55. <button open-type='share'>炫耀成绩</button>
  56. </view>
  57. </view>