# pain
if $ARGS[0] = 'calc':

    paintmp1 = func('shortgs','modul',pain['head'],pain['hair'],pain['ears'],pain['eyebrows'],pain['eyes'],pain['cheeks'],pain['nose'],pain['mouth'])
    paintmp2 = func('shortgs','modul',pain['tummy'],pain['pubic'],pain['vaginal'],pain['labia'],pain['clitoris'],pain['urethra'],pain['cervix'],pain['lips'])
    paintmp3 = func('shortgs','modul',pain['throat'],pain['asscheeks'],pain['asshole'],pain['hips'],pain['thighs'],pain['legL'],pain['legR'],pain['feet'])
    paintmp4 = func('shortgs','modul',pain['toes'],pain['shoulders'],pain['armL'],pain['armR'],pain['hands'],pain['fingers'],pain['chest'],pain['breasts'])
    paintmp5 = func('shortgs','modul',pain['tongue'],pain['neck'],pain['back'],pain['nipples'],pain['ribs'],vgape * 2, agape * 4,spanked * 24)

    pain['total'] = func('shortgs','modul',paintmp1,paintmp2,paintmp3,paintmp4,paintmp5)

    if pain['total'] > 100: pain['total'] = 100
    pain['damage'] = pain['total']

else
    !For checking pain and when applicable triggering arousal.
    !ARGS[0] magnitude of pain inflicted 1 is very light, 9 is the maximum value in the given way of causing pain
    !$ARGS[1] should equal the body part being hurt from any of the following:
    !BobyPart 'head', 'hair', 'ears', 'eyebrows', 'eyes', 'cheeks', 'nose', 'mouth', 'lips', 'tongue', 'throat', 'neck', 'back',
    !'asscheeks', 'asshole', 'hips', 'thighs', 'legL', 'legR', 'feet', 'toes', 'shoulders', 'armL', 'armR', 'handL', 'handR',
    !'fingers', 'chest', 'breasts', 'nipples', 'ribs', 'tummy', 'pubic', 'vaginal', 'labia', 'clitoris', 'urethra', 'cervix',
    !'wrists', 'ankles'
    !$ARGS[2] The action the participant has performed on Sveta (some of these can cause arousal if Sveta is into pain)
    !Acts: 'pierce', 'slap', 'spank', 'pinch', 'bite', 'burn', 'freeze', 'hit', 'kick', 'Slam', 'shock', 'bind', 'stretch'
    !'tear', 'break', 'twist', 'ache', 'cramp', 'labor', 'choke', 'fall', 'pull'
    !Format to use: gs 'pain', n, 'BobyPart', 'Act'
    !For pain to multiple body parts, use multiple calls

    pain[1] = min(ARGS[0]+ARGS[1]+ARGS[2],9)
    if pain[1]<1: exit

    pain[2] = 0
    if arrpos('$ARGS', 'slap') >= 0:    pain[2] = 1
    if arrpos('$ARGS', 'bind') >= 0:    pain[2] = 1
    if arrpos('$ARGS', 'spank') >= 0:   pain[2] = 3 & spank += 1
    if arrpos('$ARGS', 'choke') >= 0:   pain[2] = 3
    if arrpos('$ARGS', 'shock') >= 0:   pain[2] = 4
    if arrpos('$ARGS', 'twist') >= 0:   pain[2] = 4
    if arrpos('$ARGS', 'pull') >= 0:    pain[2] = 4	
    if arrpos('$ARGS', 'fall') >= 0:    pain[2] = 4
    if arrpos('$ARGS', 'labor') >= 0:   pain[2] = 4
    if arrpos('$ARGS', 'pinch') >= 0:   pain[2] = 5
    if arrpos('$ARGS', 'stretch') >= 0: pain[2] = 6
    if arrpos('$ARGS', 'slam') >= 0:    pain[2] = 6
    if arrpos('$ARGS', 'burn') >= 0:    pain[2] = 7
    if arrpos('$ARGS', 'freeze') >= 0:  pain[2] = 7
    if arrpos('$ARGS', 'hit') >= 0:     pain[2] = 7
    if arrpos('$ARGS', 'pierce') >= 0:  pain[2] = 8
    if arrpos('$ARGS', 'bite') >= 0:    pain[2] = 8
    if arrpos('$ARGS', 'tear') >= 0:    pain[2] = 9
    if arrpos('$ARGS', 'ache') >= 0:    pain[2] = 9
    if arrpos('$ARGS', 'kick') >= 0:    pain[2] = 10
    if arrpos('$ARGS', 'break') >= 0:   pain[2] = 10
    if arrpos('$ARGS', 'cramp') >= 0:   pain[2] = 10
    if pain[2]<1: exit

    pain[3] = 0
    if arrpos('$ARGS', 'hair') >= 0:      pain[3] = 1  & $painPart = 'hair'
    if arrpos('$ARGS', 'asscheeks') >= 0: pain[3] = 2  & $painPart = 'asscheeks'
    if arrpos('$ARGS', 'feet') >= 0:      pain[3] = 2  & $painPart = 'feet'
    if arrpos('$ARGS', 'shoulders') >= 0: pain[3] = 2  & $painPart = 'shoulders'
    if arrpos('$ARGS', 'wrists') >= 0:    pain[3] = 2  & $painPart = 'wrists'
    if arrpos('$ARGS', 'ankles') >= 0:    pain[3] = 2  & $painPart = 'ankles'
    if arrpos('$ARGS', 'armL') >= 0:      pain[3] = 2  & $painPart = 'armL'
    if arrpos('$ARGS', 'armR') >= 0:      pain[3] = 2  & $painPart = 'armR'
    if arrpos('$ARGS', 'cheeks') >= 0:    pain[3] = 3  & $painPart = 'cheeks'
    if arrpos('$ARGS', 'legL') >= 0:      pain[3] = 3  & $painPart = 'legL'
    if arrpos('$ARGS', 'legR') >= 0:      pain[3] = 3  & $painPart = 'legR'
    if arrpos('$ARGS', 'hands') >= 0:     pain[3] = 3  & $painPart = 'hands'
    if arrpos('$ARGS', 'mouth') >= 0:     pain[3] = 4  & $painPart = 'mouth'
    if arrpos('$ARGS', 'jaw') >= 0:       pain[3] = 4  & $painPart = 'jaw'
    if arrpos('$ARGS', 'thighs') >= 0:    pain[3] = 4  & $painPart = 'thighs'
    if arrpos('$ARGS', 'toes') >= 0:      pain[3] = 4  & $painPart = 'toes'
    if arrpos('$ARGS', 'fingers') >= 0:   pain[3] = 4  & $painPart = 'fingers'
    if arrpos('$ARGS', 'nose') >= 0:      pain[3] = 5  & $painPart = 'nose'
    if arrpos('$ARGS', 'back') >= 0:      pain[3] = 5  & $painPart = 'back'
    if arrpos('$ARGS', 'ribs') >= 0:      pain[3] = 5  & $painPart = 'ribs'
    if arrpos('$ARGS', 'hips') >= 0:      pain[3] = 5  & $painPart = 'hips'
    if arrpos('$ARGS', 'head') >= 0:      pain[3] = 6  & $painPart = 'head'
    if arrpos('$ARGS', 'ears') >= 0:      pain[3] = 6  & $painPart = 'ears'
    if arrpos('$ARGS', 'eyebrows') >= 0:  pain[3] = 6  & $painPart = 'eyebrows'
    if arrpos('$ARGS', 'lips') >= 0:      pain[3] = 6  & $painPart = 'lips'
    if arrpos('$ARGS', 'throat') >= 0:    pain[3] = 6  & $painPart = 'throat'
    if arrpos('$ARGS', 'tummy') >= 0:     pain[3] = 6  & $painPart = 'tummy'
    if arrpos('$ARGS', 'pubic') >= 0:     pain[3] = 6  & $painPart = 'pubic'
    if arrpos('$ARGS', 'urethra') >= 0:   pain[3] = 6  & $painPart = 'urethra'
    if arrpos('$ARGS', 'tongue') >= 0:    pain[3] = 7  & $painPart = 'tongue'
    if arrpos('$ARGS', 'neck') >= 0:      pain[3] = 7  & $painPart = 'neck'
    if arrpos('$ARGS', 'chest') >= 0:     pain[3] = 7  & $painPart = 'chest'
    if arrpos('$ARGS', 'eyes') >= 0:      pain[3] = 8  & $painPart = 'eyes'
    if arrpos('$ARGS', 'breasts') >= 0:   pain[3] = 8  & $painPart = 'breasts'
    if arrpos('$ARGS', 'vaginal') >= 0:   pain[3] = 8  & $painPart = 'vaginal'
    if arrpos('$ARGS', 'labia') >= 0:     pain[3] = 8  & $painPart = 'labia'
    if arrpos('$ARGS', 'cervix') >= 0:    pain[3] = 8  & $painPart = 'cervix'
    if arrpos('$ARGS', 'asshole') >= 0:   pain[3] = 9  & $painPart = 'asshole'
    if arrpos('$ARGS', 'nipples') >= 0:   pain[3] = 9  & $painPart = 'nipples'
    if arrpos('$ARGS', 'clitoris') >= 0:  pain[3] = 10 & $painPart = 'clitoris'
    if pain[3]<1: exit

    curpain = (pain[1] * pain[2] * pain[3]) /10
    prevpain = pain[$painPart]

    pain[$painPart] = func( 'shortgs','modul',prevpain,curpain)

    if pain[$painPart] > 100: pain[$painPart] = 100

    killvar 'prevpain'
    killvar 'curpain'
    killvar '$painPart'

    !arousal calculation
    !arousal += (pain[1] * pain[2]) * pain[3] * masochism['pref'] / 1000
end

--- pain ---------------------------------

