a
    Žiq  ã                   @   sr   d Z ddlZddlmZmZmZ ddd„Zddd„Zdd	d
„Zddd„Z	ddd„Z
ddd„Zddd„Zg d¢ZdS )a˜  
Health & Wellness Issue Events (Negative)
Health-related negative events and wellness setbacks

Events:
- injuryFromAccident: Injury from accident requiring recovery (ages 5-100, messageEvent)
- chronicPain: Developing chronic pain (ages 25-100, messageEvent)
- dentalEmergency: Severe tooth pain requiring emergency dental work (ages 10-100, messageEvent)
- seriousIllness: Serious health condition diagnosis (ages 20-100, messageEvent)
- weightGain: Significant weight gain (ages 16-100, messageEvent)
- sleepDeprivation: Extended period of poor sleep (ages 14-100, messageEvent)
- addictionProblem: Developing unhealthy dependency (ages 16-100, questionEvent)
é    N)ÚmessageFunctionÚquestionFunctionÚanswerOptionÚmessagec                 C   sŒ   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|rz| j  |¡ | j jd8  _| j jd8  _| j jd	8  _t||| |d
dS )z.Injury from accident requiring time to recoverÚinjuryFromAccidenté   éd   é   éè  z<You got injured in an accident. You'll need time to recover.é   é(   é   i,  ©Ú	moneyCost©	ÚeventsÚcÚageYearsÚrandomÚaddÚhealthÚenergyÚ	happinessr   ©ÚplayerÚtypeÚfnameÚcheckr   © r   ú7/var/www/lichun.app/lichun/ws/events/negative/health.pyr      s    2r   c                 C   sˆ   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|rz| j  |¡ | j jd8  _| j jd8  _| j jd8  _t||| |ƒS )	z:Developing chronic pain that makes daily activities harderÚchronicPainé   r   r	   éÐ  zAYou've developed chronic pain that makes daily activities harder.r   é   ©	r   r   r   r   r   r   r   r   r   r   r   r   r   r    "   s    2r    c                 C   s|   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|rj| j  |¡ | j jd8  _| j jd8  _t||| |d	d
S )z1Severe tooth pain requiring emergency dental workÚdentalEmergencyé
   r   r	   iÜ  z2Severe tooth pain! You need emergency dental work.r!   r   iô  r   )r   r   r   r   r   r   r   r   r   r   r   r   r%   1   s    2r%   c                 C   sŒ   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|rz| j  |¡ | j jd8  _| j jd8  _| j jd8  _t||| |d	d
S )z@Diagnosis of a serious health condition requiring long treatmentÚseriousIllnessr   r   r	   é¸  z\You've been diagnosed with a serious health condition. Treatment will be long and difficult.r   é#   r"   r   r   r   r   r   r   r'   ?   s    2r'   c                 C   sÂ   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|r´| j  |¡ | j jd8  _t| jdƒrx| j jd	8  _n| j jd
8  _| j j	d8  _	t| jdƒr´| j j
d7  _
t||| |ƒS )z8Significant weight gain affecting comfort and self-imageÚ
weightGainé   r   r	   r
   zTYou've gained significant weight. Your clothes don't fit and you feel uncomfortable.r   Ú
confidencer!   r#   r&   Úweight)r   r   r   r   r   r   Úhasattrr,   Úsocialr   r-   r   r   r   r   r   r*   N   s    2r*   c                 C   sˆ   d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}|rz| j  |¡ | j jd8  _| j jd8  _| j jd	8  _t||| |ƒS )
z2Extended period of poor sleep affecting everythingÚsleepDeprivationé   r   r	   i   zCYou haven't been sleeping well for weeks. Everything is harder now.r   r   r#   r$   r   r   r   r   r0   d   s    2r0   Fc                 C   s&  d}|| j vo4| jjdko4| jjdko4dt ¡ d k}d}tddd	d
dtddddtddƒg}|dkrxt||| ||ƒS |dkr"|d |d jkr²| j d¡ | j j	d7  _	np|d |d jkrâ| j d¡ | j j	d8  _	n@|d |d jkr"| j d¡ | j j
d
8  _
| j j	d
8  _	dS )z1Developing an unhealthy dependency affecting lifeÚaddictionProblemr+   r   r	   r(   zCYou've developed an unhealthy dependency. It's affecting your life.zSeek professional helpÚ0r
   r   )r   Ú
energyCostzTry to quit aloneÚ1é2   )r4   zIgnore the problemÚ2ÚanswerÚoptionr   z‡You seek professional help to address your dependency. It's difficult and expensive, but you're taking the right steps toward recovery.r&   zuYou try to quit on your own. It's incredibly difficult and emotionally draining, but you're determined to break free.r   é   zaYou ignore the problem and continue as before. Your health and happiness continue to deteriorate.N)ÚaskedQuestionsr   r   r   r   r   r9   ÚmessageQueueÚappendr   r   )r   r   r   Úresponser   r   ÚanswerOptionsr   r   r   r2   s   s(    2ý
r2   )r   r    r%   r'   r*   r0   r2   )r   )r   )r   )r   )r   )r   )r   FF)Ú__doc__r   Zevents.baser   r   r   r   r    r%   r'   r*   r0   r2   Ú__all__r   r   r   r   Ú<module>   s   






