| | |
| | | lastQuestionID = gameWorld.GetDictByKey(FamilyPartyFB_QuestionID % familyID)
|
| | | if lastQuestionID:
|
| | | #还有题未答
|
| | | if tick - gameWorld.GetDictByKey(FamilyPartyFB_QuestionTick % familyID) > IpyGameDataPY.GetFuncCfg('FairyCorrectAnswer')*1000:
|
| | | maxSecond = IpyGameDataPY.GetFuncCfg('FairyCorrectAnswer')
|
| | | if tick - gameWorld.GetDictByKey(FamilyPartyFB_QuestionTick % familyID) > maxSecond*1000:
|
| | | ipyData = IpyGameDataPY.GetIpyGameData('QuestionBank', lastQuestionID)
|
| | | if ipyData:
|
| | | answer = ipyData.GetAnswer()
|
| | | answer = answer.replace('[', '')
|
| | | answer = answer.replace(']', '')
|
| | | PlayerControl.FamilyNotify(familyID, 'Party_Correct', [GameWorld.GbkToCode(answer)])
|
| | | PlayerControl.FamilyNotify(familyID, 'Party_Correct', [maxSecond, GameWorld.GbkToCode(answer)])
|
| | | else:
|
| | | continue
|
| | | answerTick = gameWorld.GetDictByKey(FamilyPartyFB_AnswerTick % familyID)
|
| | |
| | | ChContent = GameWorld.CodeToGBK(ChContent)
|
| | | ChContent = ChContent.strip()
|
| | | isRight = ChContent in answerList
|
| | | # if curPlayer.GetMapID() != ChConfig.Def_FBMapID_FamilyParty:
|
| | | # if isRight:
|
| | | # PlayerControl.FamilyNotify(curFamilyid, 'FamilyPleaseIntoParty')
|
| | | # PlayerControl.NotifyCode(curPlayer, 'FamilyNoIntoParty')
|
| | | # return
|
| | | if curPlayer.GetMapID() != ChConfig.Def_FBMapID_FamilyParty:
|
| | | if isRight:
|
| | | PlayerControl.FamilyNotify(curFamilyid, 'FamilyPleaseIntoParty')
|
| | | PlayerControl.NotifyCode(curPlayer, 'FamilyNoIntoParty')
|
| | | return
|
| | |
|
| | | playerID = curPlayer.GetID()
|
| | | GameWorld.DebugLog(" answer=%s ChContent=%s"%(answerList, ChContent), playerID)
|