from otree.api import ( models, widgets, BaseConstants, BaseSubsession, BaseGroup, BasePlayer, Currency as c, currency_range, ) author = 'Yang Zhong' doc = """ Nonogram """ #One game per person class Constants(BaseConstants): name_in_url = 'nonogram_nodist' players_per_group = None num_rounds = 3 class Subsession(BaseSubsession): pass class Group(BaseGroup): pass class Player(BasePlayer): no_distraction_time_spent = models.FloatField() no_distraction_points = models.IntegerField(min=-1000) no_distraction_score_on_display = models.IntegerField(min=-1000) no_distraction_total_green = models.IntegerField() no_distraction_total_gray = models.IntegerField() no_distraction_total_wrong = models.IntegerField() no_distraction_total_right = models.IntegerField() no_distraction_wrong_green = models.IntegerField() #correct should be green no_distraction_wrong_gray = models.IntegerField() #correct should be gray no_distraction_right_green = models.IntegerField() no_distraction_right_gray = models.IntegerField() no_distraction_board_history = models.LongStringField() #if each cell is correct or not (1 for correct color, 0 for wrong color) no_distraction_time_between_moves = models.LongStringField() no_distraction_solve_order = models.LongStringField() total_wrong_adding_no_distraction = models.IntegerField() final_points_no_distraction = models.FloatField(max=30, min=0) final_payoff_no_distraction = models.FloatField(max=30, min=0) no_distraction_game_finished = models.IntegerField() no_distraction_adding_numbers1_correct = models.IntegerField() no_distraction_adding_numbers1_time_spent = models.FloatField() no_distraction_adding_numbers2_correct = models.IntegerField() no_distraction_adding_numbers2_time_spent = models.FloatField() no_distraction_adding_numbers3_correct = models.IntegerField() no_distraction_adding_numbers3_time_spent = models.FloatField() no_distraction_adding_numbers4_correct = models.IntegerField() no_distraction_adding_numbers4_time_spent = models.FloatField() no_distraction_adding_numbers5_correct = models.IntegerField() no_distraction_adding_numbers5_time_spent = models.FloatField() q1 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label= "I felt stressed while playing Nonogram.", widget=widgets.RadioSelectHorizontal ) q2 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label="I felt happy while playing Nonogram.", widget=widgets.RadioSelectHorizontal ) q3 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label= "I felt angry while playing Nonogram.", widget=widgets.RadioSelectHorizontal ) q4 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label= "I felt stressed while playing the adding-numbers game.", widget=widgets.RadioSelectHorizontal ) q5 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label= "I felt happy while playing the adding-numbers game.", widget=widgets.RadioSelectHorizontal ) q6 = models.StringField( choices=["Strongly Disagree", "Disagree", "Slightly Disagree", "Neutral", "Slightly Agree", "Agree", "Strongly Agree"], label= "I felt angry while playing the adding-numbers game.", widget=widgets.RadioSelectHorizontal )