from otree.api import ( models, widgets, BaseConstants, BaseSubsession, BaseGroup, BasePlayer, Currency as c, currency_range, ) author = 'Wubeshet' doc = """ my first application """ class Constants(BaseConstants): name_in_url = 'trust' players_per_group = 2 num_rounds = 1 endowment = c(10) multiplication_factor = 3 class Subsession(BaseSubsession): pass class Group(BaseGroup): sent_amount = models.CurrencyField() sent_back_amount = models.CurrencyField() sent_amount = models.CurrencyField( choices=currency_range(0, Constants.endowment, c(1)), ) class Player(BasePlayer): sent_amount = models.CurrencyField() sent_back_amount = models.CurrencyField()