stat.qsrc 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972
  1. # stat
  2. !!This is error catching to prevent stat from running too early
  3. if opPRE > 0: exit
  4. if Enable_Android = 0:
  5. clr
  6. !only clear status and renew object in non-Android mode
  7. gs 'obj_din', 'old'
  8. end
  9. if daystart_start < 100:
  10. pl '<BR>Did you start at the <a href="exec:daystart_start = 239 & gs ''time'' & gs''stat''">end of August</a> or <a href="exec:daystart_start = 153 & gs ''time'' & gs''stat''">beginning of June</a>?'
  11. exit
  12. end
  13. $BACKIMAGE = ''
  14. view
  15. rand1 = rand(0,100)
  16. $stat_msg=''
  17. if daystage = 1:
  18. $daystage['desc'] = 'dawn'
  19. elseif daystage = 2:
  20. $daystage['desc'] = 'mid_day'
  21. elseif daystage = 3:
  22. $daystage['desc'] = 'sunset'
  23. elseif daystage = 4:
  24. $daystage['desc'] = 'early_night'
  25. elseif daystage = 5:
  26. $daystage['desc'] = 'mid_night'
  27. elseif daystage = 6:
  28. $daystage['desc'] = 'pre_dawn'
  29. end
  30. if $start_type[1] ! 'nomagic': magik_exp = orgasm + magik_adj
  31. if insleep = 0: gs 'stat_sklattrib'
  32. if cheatVars['std'] = 1: dynamic $cheatmenu['std_cure']
  33. if cheatVars['inf_willpower'] = 1: pcs_willpwr = willpowermax
  34. if stat['vaginal'] = 0 and stat['vaginal_fist'] = 0 and stat['vaginal_dildo'] = 0 and stat['vaginal_strap'] = 0:
  35. stat['think_virgin'] = 1
  36. else
  37. stat['think_virgin'] = 0
  38. end
  39. if (analplay >= 2 and pcs_ass <= 10) or (analplay >= 4 and pcs_ass <= 15) or (analplay >= 8 and pcs_ass <= 20): pcs_ass += 1 & analplay = 0
  40. !!This is a temporary stop-gap measure for the accomadation skill and will be removed
  41. if succubusflag = 1 and sucskill >= 4:
  42. if pain['throat'] > 0: pain['throat'] = 0 & sucexcess -= 1
  43. if pain['asshole'] > 0: pain['asshole'] = 0 & sucexcess -= 1
  44. if pain['vaginal'] > 0: pain['vaginal'] = 0 & sucexcess -= 1
  45. if vgape > 0: vgape = 0 & vgapetime = 0 & sucexcess -= 1
  46. if agape > 0: agape = 0 & agapetime = 0 & sucexcess -= 1
  47. end
  48. !!mouth cleaning for drinks
  49. if pcs_hydra > hydra_check:
  50. cumspclnt = 2
  51. gs 'cum_cleanup'
  52. end
  53. !!cosmetic tattoo
  54. if cosmetic_tattoo > 0:
  55. if pcs_makeup ! (cosmetic_tattoo+1): pcs_makeup = (cosmetic_tattoo+1)
  56. end
  57. !!!CHEATS!!!
  58. if cheatVars['work'] = 1: work = 0
  59. if cheatWorkKiskis = 1: young_shop_miss = 0
  60. if cheatVars['always_brushed'] = 1: pcs_hairbsh = 1
  61. ! Moved from cheats to settings under 'Enema realism'
  62. if cheatVars['enema'] = 1: klismaday = daystart & klismaday1 = 1
  63. if cheatVars['makeup_smear'] = 1 and cosmetic_tattoo = 0 and pcs_makeup = 0: pcs_makeup = 1
  64. if cheatVars['no_sweat'] = 1 and pcs_sweat > 0: pcs_sweat = 0
  65. if cheatVars['hunger'] = 1 and pcs_energy < 60: pcs_energy = 60
  66. if cheatVars['no_leghair'] = 1:
  67. if pcs_leghair > 0: pcs_leghair = 0
  68. end
  69. if cheatVars['thirst'] = 1 and pcs_hydra < 60: pcs_hydra = 60
  70. if cheatVars['sleep'] = 1:
  71. if pcs_sleep < 35: pcs_sleep = 35
  72. end
  73. if cheatBandit = 1 and npc_horny['A66'] < 19: npc_horny['A66'] = 19
  74. if alko > 0 and frost > 0: frost = 0
  75. if lernSkill >= 8: gs 'exp_gain', 'intel', 1 & lernSkill = 0
  76. if lern >= 10: gs 'exp_gain', 'intel', 1 & lern = 0
  77. shameless = guy + stat['bj'] + stat['anal'] + stat['hj'] + ((slutty + gang) * 2)
  78. moneySUM = money + (karta - bankDebtLimit) + stolmoney
  79. cumSUM = cumsumbod/40
  80. if husbizvradd > 5:izvratH = 1
  81. if husbharmin > 10:harakHusb = 0
  82. if husband = 0:
  83. husbizvradd = 0
  84. husbharmin = 0
  85. husbandMark = 0
  86. houseslut = 0
  87. end
  88. if food_loc > 0 and $food_loc <> $loc: killvar 'food_loc'
  89. if gopota >= 20 and gnewQW = 1:gnewQW = 2
  90. if workDisk = 4 and week > 5:workDisk = 1
  91. if workDisk = 3 and week > 5:workDiskAtkPlayer = 1
  92. if bfa < 0: bfa = 0
  93. if pcs_vag > 36: pcs_vag = 36
  94. if pcs_throat > 36: pcs_throat = 36
  95. if pcs_ass > 36: pcs_ass = 36
  96. if cheatVars['no_periods'] = 1 or succubusflag = 1:
  97. !!Succubus cannot get pregnant
  98. mesec = 0
  99. FocH = 0
  100. EggRH = 0
  101. Ovulate = 0
  102. fertegg = 0
  103. UnfertEgg = 0
  104. PregChem = 0
  105. preg = 0
  106. LutH = 0
  107. RecovH = 0
  108. babyembryo = 0
  109. cycle = 1
  110. end
  111. if succubusflag = 1 and succublvl > 2 and rape > rape_count:
  112. !!High Level Succubus cannot get raped
  113. orgasm += 1
  114. rape = rape_count
  115. pcs_mood = 100
  116. end
  117. if pcs_horny < 50 and cheatVars['always_horny'] = 1: pcs_horny = 50
  118. manamax = (pcs_intel * pcs_magik) + pcs_magik * 100 + pcs_vital * 10 + rikudo
  119. !! Set the massage displayed each time the magik attribute is increased.
  120. if $start_type[1] ! 'nomagic':
  121. if pcs_magik > magikhigh:
  122. magikhigh = pcs_magik
  123. rikudo += pcs_magik * 100
  124. $stat_msg += '<BR><b>You feel like a strength has been revealed within you, and you gush with magic, lifting you to a new energy level.</b>'
  125. !! This will be replaced when a more advanced physical system is made
  126. if (pcs_magik mod 2 ! 0) and pcs_eyesize < 2: pcs_eyesize += 1
  127. if (pcs_magik mod 2 = 0) and pcs_lashes < 2: pcs_lashes += 1
  128. end
  129. else
  130. !!This is for error catching but also broke manamax calc which is why its now above this
  131. killvar 'pcs_magik'
  132. killvar 'rikudo'
  133. killvar 'pcs_splcstng'
  134. end
  135. if pcs_dom < 0: SUB = SUB - pcs_dom & pcs_dom = 0
  136. if SUB < 0: pcs_dom = pcs_dom - SUB & SUB = 0
  137. if pcs_dom > 100: pcs_dom = 100
  138. if SUB > 100: SUB = 100
  139. if SUB >= pcs_dom and pcs_dom > 0:SUB = SUB - pcs_dom & pcs_dom = 0
  140. if pcs_dom >= SUB and SUB > 0:pcs_dom = pcs_dom - SUB & SUB = 0
  141. if pcs_horny < 0: pcs_horny = 0
  142. if pcs_inhib < 0:
  143. pcs_inhib = 0
  144. elseif pcs_inhib > 100:
  145. pcs_inhib = 100
  146. end
  147. healthmax = (pcs_vital * 10 + pcs_stren * 5)
  148. stammax = (30* (2 * pcs_vital + pcs_agil + pcs_stren) +1000)/ 13 - pregchem/10
  149. speed = (2 * (pcs_stren + pcs_agil) + pcs_vital) / 5 - pregchem/100
  150. if healthmax < 1: healthmax = 1
  151. if willpowermax < 50: willpowermax = 50
  152. if stammax < 1: stammax = 1
  153. if manamax < 1: manamax = 1
  154. !pre-calc max value for later display
  155. if fairycurse >= daystart and fairyshoo > 0: pcs_horny = 90
  156. if min_arousal > pcs_horny: pcs_horny = min_arousal
  157. if Enable_lockhorny > 0 and pcs_horny < Enable_lockhorny - 1: pcs_horny = Enable_lockhorny - 1
  158. if pcs_horny < 0: pcs_horny = 0
  159. if pcs_health > healthmax: pcs_health = healthmax
  160. if pcs_willpwr > willpowermax: pcs_willpwr = willpowermax
  161. if pcs_stam > stammax: pcs_stam = stammax
  162. if pcs_mana > manamax: pcs_mana = manamax
  163. if pcs_mood > 100: pcs_mood = 100
  164. !!set hair flow free
  165. if hbraids > 5 and pcs_hairbsh = 0: hbraids -= rand(3,5) & pcs_hairbsh = 1
  166. if pcs_hairbsh <= 0:
  167. if hscrunchw <> 0: hscrunchw = 0
  168. if hpingripw <> 0: hpingripw = 0
  169. if hpigtail <> 0: hpigtail = 0
  170. if hbraids <> 0: hbraids = 0
  171. end
  172. !!Add mood_trauma to events to lower max mood for a period of time
  173. if mood_trauma > 0:
  174. mood_max_calc = 100 - (mood_trauma * 5)
  175. mood_max = max(10, mood_max_calc)
  176. if pcs_mood > mood_max: pcs_mood = mood_max
  177. killvar 'mood_max_calc'
  178. elseif mood_trauma < 0:
  179. mood_trauma = 0
  180. end
  181. if hypnoAddict = 1 and pcs_horny < 30:
  182. pcs_horny = 30
  183. elseif hypnoAddict = 2 and pcs_horny < 50:
  184. pcs_horny = 50
  185. end
  186. if cumloc[0] = 1 or cumloc[3] = 1 or hypnoAddict = 0:
  187. killvar 'missCum'
  188. elseif missCum > timeTresh:
  189. if pcs_horny < 90: pcs_horny = 90
  190. if preziktype = 0 or preziktype = 2:
  191. if mc_inventory['normal_condoms'] > 0 and mc_inventory['sabotaged_condoms'] < rand(2,3): dynamic $din_Do_Condom_Counts, 4
  192. if preziktype <> 2 and mc_inventory['sabotaged_condoms'] > 0: dynamic $din_Do_Condom_Counts, 3
  193. end
  194. end
  195. !!!!!!!!!!!
  196. !!!TIME!!!
  197. !!!!!!!!!!!
  198. gs 'time'
  199. ! Execute time based
  200. if prevtotmin ! totminut:
  201. gs 'spellTimer', prevtotmin, totminut
  202. end
  203. !! deodorant
  204. if deodorant_on = 1 and totminut > deodorant_time: gs 'sweat', 'remove_deo'
  205. !! exercise tracking
  206. if stat['last_workout_trig'] = 1:
  207. stat['last_workout_trig'] = 0
  208. stat['last_workout'] = totminut
  209. end
  210. !!painkiller
  211. if pain['killer'] > 0:
  212. if pain['killer'] = 1: pain_timer = totminut - 2
  213. pain['killer'] = totminut - pain_timer
  214. if pain['killer'] >= 243: pain['killer'] = 0
  215. end
  216. !!Gaping of vagina recovery time
  217. !! [1] stored gape value
  218. !! [3] timer
  219. !! [4] time between each reduction in gape
  220. if agape[4] = 0: agape[4] = 10
  221. if vgape[4] = 0: vgape[4] = 10
  222. if vgape > vgape[1]:
  223. vgape[3] = totminut
  224. vgape[1] = vgape
  225. if vgape > 2:
  226. if rand(0,9) > 1:
  227. vshrink = max(1, vshrink - 1)
  228. else
  229. vaginaMin += 1
  230. vgape[4] += 1
  231. end
  232. end
  233. elseif vgape > vaginaMin / 10:
  234. if totminut - vgape[3] - vaginaMin > vgape[4]:
  235. vgape -= 1
  236. vgape[1] = vgape
  237. vgape[3] = totminut
  238. end
  239. end
  240. !!Gaping of anus recovery time
  241. if agape > agape[1]:
  242. agape[3] = totminut
  243. agape[1] = agape
  244. if agape > 2:
  245. if rand(0,9) > 1:
  246. ashrink = max(1, ashrink - 1)
  247. else
  248. anusMin += 1
  249. agape[4] += 1
  250. end
  251. end
  252. elseif agape > anusMin / 10:
  253. if totminut - agape[3] - anusMin > agape[4]:
  254. agape -= 1
  255. agape[1] = agape
  256. agape[3] = totminut
  257. end
  258. end
  259. !!Recovery from spanking - will be superseded by pain system
  260. if spanked > 0:
  261. if spankedtime = 0: spankedtime = totminut
  262. if (spankedtime + 2040) <= totminut:spanked -= 1 & spankedtime = 0
  263. elseif spankedtime ! 0:
  264. killvar 'spankedtime'
  265. end
  266. !! Orgasmic cooldown
  267. if orgasmic ! 0:
  268. if orgasmic < totminut - 10: orgasmic = 0 & pcs_horny = 0
  269. end
  270. !!!!!!!!!!!!!!! Heels pain and skill gain
  271. !! This compares the player heels skill to the skill required to wear any heels the player
  272. !! currently wears. If the skill needed is greater than the player currently possesses,
  273. !! the pain in the feet increases and the player earns heels skill. If the skill required
  274. !! is lower, the player might still get experience, depending on how much greater the
  275. !! player skill is.
  276. !! Variables
  277. !! pcs_heels is the main heels skill
  278. !! heels_exp is used when the player gains experience using heels
  279. !! heels_deg is used when the player neglects their heels
  280. !! PShoHeels tracks the height of the heels currently worn
  281. !! heelsminut tracks when the heels skill was last changed
  282. !! heelsRequiredskill substitutes PShoHeels to allow comparison with pcs_heels
  283. !! heelsSkilldiff tracks difference between the players current and skill required by heels
  284. !! Required skill for various heel sizes
  285. !! 1 flats - 0
  286. !! 2 low heel - 5
  287. !! 3 Mid heel - 15
  288. !! 4 High heel - 25
  289. !! 5 ultra high heel - 40
  290. !! 6 fetish heel - 60
  291. !! Only run if at least X minutes have passed since last time
  292. if heelsminut > totminut: heelsminut = totminut & !! fix for time cheat
  293. if totminut >= heelsminut + 30:
  294. killvar 'tmp'
  295. heelstime = totminut-heelsminut
  296. heelsminut = totminut
  297. !! Only check experience and pain gain and if the player wears heels, flats give nothing
  298. if PShoHeels > 1:
  299. if PShoHeels = 2:
  300. heelsRequiredskill = 5
  301. elseif PShoHeels = 3:
  302. heelsRequiredskill = 15
  303. elseif PShoHeels = 4:
  304. heelsRequiredskill = 25
  305. elseif PShoHeels = 5:
  306. heelsRequiredskill = 40
  307. elseif PShoHeels = 6:
  308. heelsRequiredskill = 60
  309. end
  310. !! stat is called a lot, there should be a limit to how much exp and pain you can accumulate...
  311. !! If the player skill is below the required skill, give heel_exp and apply ache
  312. if pcs_heels < heelsRequiredskill:
  313. heelsSkilldiff = heelsRequiredskill - pcs_heels
  314. if heelsSkilldiff <= 5:
  315. tmp = rand(min(3,heelstime/30),min(6,heelstime/15))
  316. if pain['feet'] < 40: gs 'pain', rand(heelstime/30,heelstime/15), 'feet', 'ache'
  317. elseif heelsSkilldiff <= 10:
  318. tmp = rand(min(5,heelstime/20),min(9,heelstime/10))
  319. if pain['feet'] < 50: gs 'pain', rand(heelstime/25,heelstime/12), 'feet', 'ache'
  320. elseif heelsSkilldiff <= 15:
  321. tmp = rand(min(7,heelstime/15),min(12,heelstime/8))
  322. if pain['feet'] < 60: gs 'pain', rand(heelstime/20,heelstime/10), 'feet', 'ache'
  323. elseif heelsSkilldiff <= 20:
  324. tmp = rand(min(9,heelstime/10),min(15,heelstime/5))
  325. if pain['feet'] < 70: gs 'pain', rand(heelstime/15,heelstime/8), 'feet', 'ache'
  326. else
  327. tmp = rand(min(12,heelstime/5),min(20,heelstime/2))
  328. if pain['feet'] < 80: gs 'pain', rand(heelstime/10,heelstime/5), 'feet', 'ache'
  329. end
  330. !! Player skill is equal to or higher than the required skill
  331. !! Maybe have excessive skill result in no gain, or even a degrading skill?
  332. else
  333. heelsSkilldiff = pcs_heels - heelsRequiredskill
  334. gs 'pain', max(0, rand(heelstime/10,heelstime/5) - heelsSkilldiff), 'feet', 'ache'
  335. if heelsSkilldiff <= 5:
  336. tmp = rand(-2,0) + rand(min(8,heelstime/6),min(12,heelstime/3))
  337. elseif heelsSkilldiff <= 10:
  338. tmp = rand(-3,0) + rand(min(6,heelstime/10),min(9,heelstime/5))
  339. elseif heelsSkilldiff <= 15:
  340. tmp = rand(-4,0) + rand(min(5,heelstime/15),min(7,heelstime/10))
  341. elseif heelsSkilldiff <= 20:
  342. tmp = rand(-5,0) + rand(min(4,heelstime/20),min(6,heelstime/15))
  343. else
  344. tmp = rand(-6,0) + rand(min(3,heelstime/30),min(4,heelstime/20))
  345. end
  346. end
  347. !! If not wearing heels, degrade heels skill
  348. else
  349. tmp = rand(heelstime/30,heelstime/15)*-1
  350. end
  351. if tmp > 0:
  352. gs 'exp_gain', 'heels', tmp
  353. elseif tmp < 0:
  354. heels_deg += tmp
  355. end
  356. killvar 'tmp'
  357. killvar 'heelstime'
  358. killvar 'heelsSkilldiff'
  359. killvar 'heelsRequiredskill'
  360. end
  361. !!!!!!!!!!!!!!! End heels
  362. ! Determine Incoming Telephone Calls and SMS
  363. if prevtotmin ! totminut:
  364. gs 'telefon', 'IncomingCheck', prevtotmin, totminut
  365. gs 'telefon', 'IncomingSMSCheck'
  366. end
  367. if minut < 10:
  368. $nilmin = '0'
  369. else
  370. $nilmin = ''
  371. end
  372. if kid > 0:
  373. i = arrsize('yearkid')
  374. :LoopKidAgeCounter
  375. if i >= 0:
  376. if yearkid[i] = year + 1 and monthkid[i] = month and daykid[i] = day: msg'It is <<$kidname[i]>>''s birthday today.'
  377. i -= 1
  378. jump 'LoopKidAgeCounter'
  379. end
  380. end
  381. if bimbolevel > 0:
  382. if bimbowithdrawal = 0:
  383. $bimbostatus = '<font color = #FF1493>You''re, like, super hawt today.</font>'
  384. $bimbo_tooltip = 'You''re, like, super hawt today.'
  385. elseif bimbowithdrawal = 1:
  386. $bimbostatus = '<font color="green">You feel, like, kind of lame today.</font>'
  387. $bimbo_tooltip = 'You feel, like, kind of lame today.'
  388. elseif bimbowithdrawal < 4:
  389. $bimbostatus = '<font color="grey">You feel, like, totally lame today.</font>'
  390. $bimbo_tooltip = 'You feel, like, totally lame today.'
  391. elseif bimbowithdrawal < 6:
  392. if pcs_mood > 50: pcs_mood -= 10
  393. $bimbostatus = '<font color="red">You really feel, like, awful today.</font>'
  394. $bimbo_tooltip = 'You really feel, like, awful today.'
  395. elseif bimbowithdrawal >= 6:
  396. if pcs_mood > 10: pcs_mood -= 10
  397. $bimbostatus= '<font color="red"><b>You feel that, like, horrible today!</b></font>'
  398. $bimbo_tooltip = 'You feel that, like, horrible today!'
  399. end
  400. else
  401. bimbowithdrawal = 0
  402. $bimbostatus = ''
  403. end
  404. if gothlevel > 0:
  405. $gothstatus = ''
  406. $goth_tooltip = ''
  407. else
  408. $gothstatus = ''
  409. end
  410. if punklevel > 0:
  411. $punkstatus = ''
  412. $punk_tooltip = ''
  413. else
  414. $punkstatus = ''
  415. end
  416. !
  417. ! WD: Triggers every 15 minutes if not sleeping
  418. ! Update to remove long iterations on loading saves from previous versions
  419. ! Do Nothing if sleeping, invalid Trig15Minute value or more than 6 hours 16 minute pass
  420. if InSleep ! 0 or Trig15Minute > totminut or (totminut - Trig15Minute) >= 376:
  421. set Trig15Minute = totminut
  422. ! More than 15 minutes since last check
  423. else
  424. if (totminut - Trig15Minute) >= 15:
  425. ! begin Loop
  426. :Trig15MinuteLoop
  427. ! Horny Actions
  428. if pcs_horny > 100:
  429. Trig15Minute = totminut
  430. else
  431. Trig15Minute += 15
  432. ! WD: Fix vibrator arousal to trigger every 15 minutes, moved from 'time' location
  433. if vibratorin = 1:pcs_horny += rand(1, 5)
  434. ! WD: Fixed Piecing arousal to trigger every 15 minutes, instead of once per day
  435. if pcs_horny < 70:
  436. hornystat = 0
  437. if pcs_piercings['ears'] > 0: hornystat += 1
  438. if pcs_piercings['nose'] > 0: hornystat += 1
  439. if pcs_piercings['brow'] > 0: hornystat += 1
  440. if pcs_piercings['lip'] > 0: hornystat += 1
  441. if pcs_piercings['tongue'] > 0: hornystat += 1
  442. if pcs_piercings['navel'] > 0: hornystat += 1
  443. if pcs_piercings['nipples'] > 0: hornystat += 4
  444. if pcs_piercings['pussy'] > 0: hornystat += 4
  445. pcs_horny += (hornyStat + 2) / 4
  446. end
  447. ! WD: Clothing
  448. if PCloStyle = 4 and pcs_horny < 70: pcs_horny += rand(0, 2)
  449. if (PCloSkirt > 5 or PCloPants > 5) and pcs_horny < 50: pcs_horny += rand(0, 1)
  450. if PCloTopCut = 4 and pcs_horny < 50: pcs_horny += rand(0, 1)
  451. end
  452. !!SECTION: Bimbo (15 minute interval update checks)
  453. if bimbolevel > 0:
  454. if (pcs_mood < 100): pcs_mood += (pcs_mood / 100) * max(0, rand(-bimbowithdrawal, bimbolevel))
  455. if pcs_horny < max(0, 30 - bimbowithdrawal * bimbolevel): pcs_horny = max(0, 30 - bimbowithdrawal * bimbolevel)
  456. if pcs_horny < 100: pcs_horny += max(0, rand(bimbowithdrawal/-2, bimbolevel))
  457. end
  458. !!SECTION: Commando trait (15 minute interval update checks)
  459. if $clothingworntype ! 'nude':
  460. if $pantyworntype = 'none':
  461. !! Addition to trait exp/lvls
  462. if pcs_traits['commando_lvl'] = 0:
  463. if PCloSkirt > 0:
  464. pcs_traits['commando_exp'] += 2
  465. else
  466. pcs_traits['commando_exp'] += 1
  467. end
  468. if pcs_traits['commando_exp'] >= 1000:
  469. pcs_traits['commando_exp'] = 50
  470. pcs_traits['commando_lvl'] = 1
  471. msg'You have gained the Commando trait! You have become accustomed to the idea you don''t have to wear panties all the time and can now comfortably wear skirts without panties. Pants are still a little itchy though...'
  472. end
  473. elseif pcs_traits['commando_lvl'] = 1:
  474. pcs_traits['commando_exp'] += 2
  475. if pcs_traits['commando_exp'] >= 1000:
  476. pcs_traits['commando_exp'] = 50
  477. pcs_traits['commando_lvl'] = 2
  478. msg'You have gained the 2nd level of the Commando trait! You have become very comfortable without panties and the raw insides of your pants no longer irritate your pussy.'
  479. end
  480. elseif pcs_traits['commando_lvl'] = 2:
  481. mosol = 0
  482. pcs_traits['commando_exp'] += 2
  483. if pcs_traits['commando_exp'] >= 1000:
  484. pcs_traits['commando_exp'] = 500
  485. pcs_traits['commando_lvl'] = 3
  486. msg'You have gained the 3rd level of the Commando trait! You have become so accustomed to going commando that any kind of underwear over your hips just feels <i>wrong</i>. You suffer mood penalties while wearing panties.'
  487. end
  488. elseif pcs_traits['commando_lvl'] = 3:
  489. pcs_traits['commando_exp'] += 1
  490. end
  491. elseif pcs_traits['commando_lvl'] > 0:
  492. !!Reduction from exp/lvls
  493. if pcs_traits['commando_lvl'] = 3:
  494. pcs_traits['commando_exp'] -= 1
  495. pcs_mood -= 1
  496. if pcs_traits['commando_exp'] <= 0:
  497. pcs_traits['commando_exp'] = 500
  498. pcs_traits['commando_lvl'] = 2
  499. msg'You have lost the 3rd level of the Commando trait! You are now only comfortable not wearing panties and will not suffer irritation from wearing pants while going commando.'
  500. end
  501. else
  502. pcs_traits['commando_exp'] -= 1
  503. if pcs_traits['commando_exp'] <= -0:
  504. pcs_traits['commando_exp'] = 900
  505. pcs_traits['commando_lvl'] -= 1
  506. end
  507. end
  508. end
  509. !!{
  510. if $braworntype = 'none':
  511. end}
  512. end
  513. !! This is the Succubus non-direct injection (pun intented) sex to sexnutrition and the sexnutrition conversion handling
  514. if succubusflag = 1:
  515. if hypnoAddict > 0: dynamic $RestTherapyVariables
  516. if pcs_horny < 50: pcs_horny = 50
  517. if pcs_horny < 100: pcs_horny += succublvl
  518. if succhungry > 0:
  519. pcs_energy -= succhungry * succublvl
  520. pcs_hydra -= succhungry * succublvl
  521. pcs_sleep -= succhungry * succublvl
  522. end
  523. if arrsize('sparrvol') > 0:
  524. suctempi = -1
  525. :SuccAbsorbLoop
  526. suctempi += 1
  527. if suctempi <= 1 or suctempi = 3 or suctempi = 4 or suctempi >= 8:
  528. suctemparr = arrpos('sparrloc',suctempi)
  529. if suctemparr >= 0 and sparrloc[suctemparr] = suctempi and sparrvol[suctemparr] > 0:
  530. scfeed = succublvl + rand(1,4)
  531. sexnutrition += 30 * scfeed
  532. succubxp += 5
  533. cumsumbod -= sparrvol[suctemparr]
  534. ! msg "we've got xp!" + sparrloc[suctemparr]
  535. sucabscum = 1
  536. gs 'cum_cleanup', 'cleandeposit', suctemparr
  537. cumloc[suctempi] = 0
  538. !debug code $stat_msg += '<BR>Absorb ext <<sexnutrition>>'
  539. end
  540. end
  541. if suctempi < 17:jump 'SuccAbsorbLoop'
  542. cumspclnt = 20 & gs 'cum_cleanup'
  543. end
  544. if suclezsex < lesbian:
  545. sexnutrition += succublvl * 20
  546. suclezsex = lesbian
  547. succubxp += 5
  548. sucabslez = 1
  549. end
  550. if sexnutrition > 0:
  551. if sucskill >= 3 and succublvl >= 2: sexnutrition += (sexnutrition * 2) / 10
  552. if sucabslez = 1 and sucabscum = 1:
  553. $sucabs1 = 'absorbed energy from the woman you had sex with'
  554. $sucabs2 = ' and you '
  555. $sucabs3 = 'absorb the semen in your body'
  556. elseif sucabscum = 1:
  557. $sucabs3 = 'absorb the semen in your body'
  558. elseif sucabslez = 1:
  559. $sucabs1 = 'absorbed energy from the woman you had sex with'
  560. else
  561. !!Debug code
  562. $stat_msg += '<BR>SOMETHING HAPPENED!'
  563. end
  564. $stat_msg += '<BR>You <<$sucabs1>><<$sucabs2>><<$sucabs3>>, gaining nourishment.'
  565. sucabslez = 0 & sucabscum = 0
  566. $sucabs1 = '' & $sucabs2 = '' & $sucabs3 = ''
  567. if (pcs_mood < 100): pcs_mood += ((pcs_mood / 100) * 5)
  568. if pcs_energy > 100: entemp = (pcs_energy - 100)
  569. if sucexcess < 0 and sexnutrition > 20 and pcs_energy > 30:
  570. if sexnutrition - 20 >= (0 - sucexcess) * 2:
  571. sexnutrition += sucexcess * 2
  572. sucexcess = 0
  573. else
  574. sucexcess += (sexnutrition - 20) / 2
  575. sexnutrition = 20
  576. end
  577. end
  578. pcs_energy += sexnutrition / 2
  579. pcs_hydra += sexnutrition
  580. pcs_sleep += sexnutrition / 20
  581. if succhungry > 0: succhungry = 0
  582. sexnutrition = 0
  583. if pcs_energy > 100: sucexcess += (pcs_energy - entemp - 100) & pcs_energy = 100 + entemp & killvar 'entemp'
  584. end
  585. end
  586. !! safeguards to prevent bimbolevel from going above or below its intended limits
  587. bimbolevel = max(0, min(bimbolevel, 3))
  588. ! do loop
  589. if (totminut - Trig15Minute) >= 15: jump 'Trig15MinuteLoop'
  590. end
  591. end
  592. !!!!!!!!!!!!!
  593. !!!ENERGY!!!
  594. !!!!!!!!!!!!!
  595. if succubusflag = 1:
  596. if pcs_energy < 0:
  597. if fat >= 1:
  598. if cheatVars['fat'] = 0: fat -= 2
  599. pcs_energy += 8 + succublvl
  600. else
  601. pcs_energy += 8 + succublvl
  602. sucexcess -= (8 + succublvl) * (6 - succublvl)
  603. end
  604. end
  605. if pcs_health < 0:
  606. pcs_health = 10
  607. sucexcess -= 25 * (9 - succublvl)
  608. end
  609. if pcs_willpwr < 0:
  610. pcs_willpwr = 10
  611. sucexcess -= 20 * (9 - succublvl)
  612. sucpowzeroed = 4
  613. end
  614. end
  615. if pcs_sleep < 0:
  616. pcs_sleep = 0
  617. pcs_mood -= 5
  618. end
  619. if pcs_energy < 0:
  620. pcs_energy = 0
  621. pcs_health -= 5
  622. if pcs_mass['body'] = 0 and pcs_stren + pcs_vital > 0:
  623. stren_deg -= 1
  624. vital_deg -= 1
  625. pcs_energy += 8
  626. elseif pcs_mass['body'] = 0 and pcs_stren + pcs_vital <= 0:
  627. gs 'gameover', 'check', 3
  628. $stat_msg += '<br><font color=red><b>You starved to death, but Cheat Mode keeps you Alive.</b></font>'
  629. fat = 1
  630. elseif pcs_mass['body'] > 0:
  631. if cheatVars['fat'] = 0: fat -= 1
  632. pcs_energy += 8
  633. end
  634. end
  635. if pcs_hydra <= 0:
  636. pcs_hydra = 1
  637. pcs_health -= 5
  638. end
  639. !!Set hydra_check value
  640. hydra_check = pcs_hydra
  641. if pcs_mood <= 0:
  642. pcs_mood = 1
  643. pcs_health -= 5
  644. end
  645. if pcs_health < 0:
  646. gs 'gameover', 'check', 1
  647. $stat_msg += '<br><font color=red><b>You died from injuries, but Cheat Mode keeps you Alive.</b></font>'
  648. pcs_health = 0
  649. end
  650. if pcs_willpwr <= 0 :
  651. !this will set willpower to 0 correctly; then check mana =1 for insane-gameover(pcs_willpwr=0&mana=1).
  652. if pcs_mood <= 1:
  653. gs 'gameover', 'check', 2
  654. $stat_msg += '<br><font color=red><b>You are insane, but Cheat Mode keeps you Alive.</b></font>'
  655. !pcs_mood already checked for >=1 in line 1113 if pcs_mood <= 0, no need to set another one
  656. end
  657. pcs_willpwr = 0
  658. end
  659. !!cars-increase/depressed mood after orgasm/rape
  660. if rape > 0 and rape ! rape_count and orgasm = orgasm_count:
  661. pcs_mood = 10
  662. rape_count = rape
  663. rape_day = daystart
  664. elseif orgasm > 0 and orgasm ! orgasm_count:
  665. pcs_mood = 100
  666. orgasm_count = orgasm
  667. elseif rape > 0 and rape ! rape_count and orgasm > 0 and orgasm ! orgasm_count:
  668. pcs_mood = 100
  669. orgasm_count = orgasm
  670. rape_count = rape
  671. rape_day = daystart
  672. end
  673. !! Drug stats
  674. gs 'drugs', 'stat'
  675. !!Health, Willpower, Auto Birth Control pregnancy check
  676. gs 'body', 'RegularUpdate'
  677. gs 'body', 'Update_Appearance'
  678. if pcs_health >= healthmax:
  679. $pcs_health = '<font color="green">You are very healthy.</font>'
  680. elseif pcs_health >= healthmax * 75 / 100:
  681. $pcs_health = '<font color=#0064FF>You are healthy.</font>'
  682. elseif pcs_health >= healthmax * 50 / 100:
  683. $pcs_health = '<font color="brown">You are not healthy.</font>'
  684. elseif pcs_health >= healthmax * 25 / 100:
  685. $pcs_health = '<font color="red">You are sick.</font>'
  686. else
  687. $pcs_health = '<font color="red">You are on the verge of death.</font>'
  688. end
  689. if pcs_willpwr >= willpowermax:
  690. $pcs_willpwr = '<font color="green">You feel in charge of your actions.</font>'
  691. elseif pcs_willpwr >= willpowermax * 75 / 100:
  692. $pcs_willpwr = '<font color=#0064FF>You are mostly in control.</font>'
  693. elseif pcs_willpwr >= willpowermax * 50 / 100:
  694. $pcs_willpwr = '<font color="brown">You might have to make some concessions.</font>'
  695. elseif pcs_willpwr >= willpowermax * 25 / 100:
  696. $pcs_willpwr = '<font color="red">You will have to toe the line.</font>'
  697. else
  698. $pcs_willpwr = '<font color="red">You are completely at other people''s mercy.</font>'
  699. end
  700. !!stop auto birth control pill taking if the player believes they are pregnant or are pregnant
  701. if thinkpreg = 1 or knowpreg = 1:
  702. if tabletkicheck = 1: tabletkicheck = 0
  703. if birth_control['remind_hour'] > 0:
  704. birth_control['remind_hour'] = 0
  705. if birth_control['remind_icon'] = 1: birth_control['remind_icon'] = 0
  706. end
  707. elseif birth_control['remind_hour'] > 0 and hour >= birth_control['remind_hour'] and hour <= birth_control['remind_hour'] + 1 and tabletkiday ! daystart:
  708. birth_control['remind_icon'] = 1
  709. else
  710. birth_control['remind_icon'] = 0
  711. end
  712. if tabletkicheck = 1 and tabletkichday < daystart and birth_control['auto_hour'] > 0 and hour >= birth_control['auto_hour'] and hour <= birth_control['auto_hour'] + 1 and InSleep = 0 and menu_off = 0 and $location_type ! 'event' and $location_type ! 'event_outdoors':
  713. gs 'fertility', 'auto_pill'
  714. end
  715. !! detected change in pillcon
  716. if pillcon ! birth_control['old_pillcon'] or pillcon2 ! birth_control['old_pillcon2']: gs 'fertility', 'update'
  717. gs 'cum_manage', 'cum_decay'
  718. !!Mood
  719. if cheatVars['mood'] = 0:
  720. maxmood = 100 - moodmodifier
  721. if pcs_mood > 100:
  722. pcs_mood = 100
  723. elseif pcs_mood < 0:
  724. pcs_mood = 0
  725. !! Asylum: basically this means clinically insane, like court-ordered committed, saliva dripping, blubbering... Ordinarily irreversible at this stage meaning Game Over, but cheat can help
  726. end
  727. else
  728. pcs_mood = 100
  729. mood_trauma = 0
  730. end
  731. if Gerpes >= 3 or Sifilis >= 21 or Triper > 2:
  732. $msg_extra = ' it is being reduced due to an STD'
  733. else
  734. killvar '$msg_extra'
  735. end
  736. if pcs_mood >= 80:
  737. $pcs_mood = '<font color="green">You are in a great mood<<$msg_extra>>.</font>'
  738. elseif pcs_mood >= 60:
  739. $pcs_mood = '<font color=#0064FF>You are in a good mood<<$msg_extra>>.</font>'
  740. elseif pcs_mood >= 40:
  741. $pcs_mood = '<font color="brown">You are in an OK mood<<$msg_extra>>.</font>'
  742. elseif pcs_mood >= 20:
  743. $pcs_mood = '<font color="orange">You are in a bad mood<<$msg_extra>>.</font>'
  744. elseif pcs_mood >= 5:
  745. $pcs_mood = '<font color="red">You are in a terrible mood<<$msg_extra>>.</font>'
  746. else
  747. $pcs_mood = '<font color="red">You are really depressed and need to improve your mood<<$msg_extra>>.</font>'
  748. end
  749. if pcs_energy >= 80:
  750. $pcs_energy = '<font color="green">You couldn''t eat one more bite.</font>'
  751. elseif pcs_energy >= 40:
  752. $pcs_energy = '<font color=#0064FF>You''re not really hungry, but a small snack would be very welcome.</font>'
  753. elseif pcs_energy >= 8:
  754. $pcs_energy = '<font color="brown">You are hungry.</font>'
  755. else
  756. $pcs_energy = '<font color="red">You are very hungry.</font>'
  757. end
  758. if pcs_hydra >= 80:
  759. $pcs_hydra = '<font color="green">You are not thirsty at all.</font>'
  760. elseif pcs_hydra >= 40:
  761. $pcs_hydra = '<font color=#0064FF>You are slightly thirsty.</font>'
  762. elseif pcs_hydra >= 8:
  763. $pcs_hydra = '<font color="brown">You are thirsty.</font>'
  764. else
  765. $pcs_hydra = '<font color="red">You are very thirsty.</font>'
  766. end
  767. if pcs_sleep >= 80:
  768. $pcs_sleep = '<font color="green">You are well rested.</font>'
  769. elseif pcs_sleep >= 40:
  770. $pcs_sleep = '<font color=#0064FF>You are slightly tired.</font>'
  771. elseif pcs_sleep >= 8:
  772. $pcs_sleep = '<font color="brown">You are tired.</font>'
  773. else
  774. $pcs_sleep = '<font color="red">You are very tired.</font>'
  775. end
  776. if workFabrika = 1 and week => 1 and week <= 5 and hour > 8 and age => 16 and age < 18 and FabrikaProgulDay ! day or workFabrika = 1 and week => 1 and week <= 5 and hour > 16 and age > 18 and FabrikaProgulDay ! day:
  777. !!absence from work in a factory in Pavlovsk
  778. FabrikaProgul += 1
  779. FabrikaProgulDay = day
  780. end
  781. if hotelRoom['pav'] > 0:
  782. if hotelRoomDays['pav'] - 1 = daystart:
  783. $stat_msg += '<BR>You have 1 night left on your Pavlosk hotel booking.'
  784. elseif hotelRoomDays['pav'] = daystart and hour < 11:
  785. $stat_msg += '<BR>Your room at the Pavlosk hotel has check out today at 11:00'
  786. elseif hotelRoomDays['pav'] = daystart:
  787. hotelRoom['pav'] = 0
  788. end
  789. end
  790. if hotelRoom['city'] > 0:
  791. if hotelRoomDays['city'] - 1 = daystart:
  792. $stat_msg += '<BR>You have 1 night left on your St Petersburg hotel booking.'
  793. elseif hotelRoomDays['city'] = daystart and hour < 11:
  794. $stat_msg += '<BR>Your room at the St Petersburg hotel has check out today at 11:00'
  795. elseif hotelRoomDays['city'] = daystart:
  796. hotelRoom['city'] = 0
  797. end
  798. end
  799. if hour >= 8 and hour < 14 and week < 6 and mid($start_type,1,2) = 'sg' and SchoolAtestat = 0 and kanikuli = 0 and schoolProgulDay ! daystart:
  800. !!absence from school
  801. schoolprogul += 1
  802. schoolProgulDay = daystart
  803. end
  804. if cumcondslip <= 0: cumcondslip_deep = 0
  805. !!Sex stat update
  806. stat['mast'] += mastr & mastr = 0
  807. stat['hj'] += hj & hj = 0
  808. stat['bj'] += bj & bj = 0
  809. stat['vaginal'] += sex & sex = 0
  810. stat['anal'] += anal & anal = 0
  811. stat['cuni'] += kuni & kuni = 0
  812. stat['anal_strap_give'] += pegging & pegging = 0
  813. !!Pain calculation
  814. gs 'pain', 'manage'
  815. !!update skills and attributes to pcs_ from there _lvl values plus adjustments based on condition
  816. gs 'stat_sklattrib_lvlset'
  817. !!Sleep variable cap
  818. if pcs_sleep > 100: pcs_sleep = 100
  819. if insleep = 0:
  820. gs 'outdoors', 'main'
  821. gs 'stat_display'
  822. end
  823. gs 'family_schedule'
  824. !!--------------------------Job Checks For Icons--------------------------------
  825. if (acting['shoot_day'] = daystart and actress_cast = 1) or (audition['day'] = daystart):
  826. acting['icon'] = 1
  827. else
  828. acting['icon'] = 0
  829. end
  830. if model_job_week < 2 and model['status'] = 1:
  831. model['icon'] = 1
  832. else
  833. model['icon'] = 0
  834. end
  835. if pfilmday[0] > 0:
  836. pornstar['icon'] = 1
  837. else
  838. pornstar['icon'] = 0
  839. end
  840. if hypnoSchedule = 1:
  841. if therapist_weekly_block = 0 and week = 4 and therapistday ! daystart and remindedtherapyday ! daystart:
  842. if menu_off = 0 and workDolg = 0:
  843. if (hour >= 18 and (minut > 45 or hour >= 19)) _
  844. and (hour < 20 and (minut < 15 or hour < 19)):
  845. gs 'therapist_reminder'
  846. end
  847. end
  848. end
  849. end
  850. --- stat ---------------------------------