stat.qsrc 31 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022
  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''daystart'' & gs''stat''">end of August</a> or <a href="exec:daystart_start = 153 & gs''daystart'' & 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 cheatHealth = 1: dynamic $cheatmenu['std_cure']
  33. if InfWillpwer = 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 cheatWork = 1:work = 0
  59. if cheatWorkKiskis = 1:young_shop_miss = 0
  60. if cheatHapri = 1:pcs_hairbsh = 1
  61. ! Moved from cheats to settings under 'Enema realism'
  62. if cheatKlisma = 0:klismaday = daystart & klismaday1 = 1
  63. if cheatNomakeup = 1 and cosmetic_tattoo = 0:
  64. if pcs_makeup = 0: pcs_makeup = 1
  65. end
  66. if cheatNoSweat = 1 and pcs_sweat > 0: pcs_sweat = 0
  67. if cheatNoEat = 1:
  68. if pcs_energy < 60: pcs_energy = 60
  69. end
  70. if cheatShaveLegs = 1:
  71. if pcs_leghair > 0: pcs_leghair = 0
  72. end
  73. if cheatNoDrink = 1:
  74. if pcs_hydra < 60: pcs_hydra = 60
  75. end
  76. if cheatNoSleep = 1:
  77. if pcs_sleep < 35: pcs_sleep = 35
  78. end
  79. if cheatBandit = 1 and npc_horny['A66'] < 19: npc_horny['A66'] = 19
  80. if alko > 0 and frost > 0: frost = 0
  81. if lernSkill >= 8: gs 'exp_gain', 'intel', 1 & lernSkill = 0
  82. if lern >= 10: gs 'exp_gain', 'intel', 1 & lern = 0
  83. shameless = guy + stat['bj'] + stat['anal'] + stat['hj'] + ((slutty + gang) * 2)
  84. moneySUM = money + karta + stolmoney
  85. cumSUM = cumsumbod/40
  86. if husbizvradd > 5:izvratH = 1
  87. if husbharmin > 10:harakHusb = 0
  88. if husband = 0:
  89. husbizvradd = 0
  90. husbharmin = 0
  91. husbandMark = 0
  92. houseslut = 0
  93. end
  94. if food_loc > 0 and $food_loc <> $loc: killvar 'food_loc'
  95. if gopota >= 20 and gnewQW = 1:gnewQW = 2
  96. if workDisk = 4 and week > 5:workDisk = 1
  97. if workDisk = 3 and week > 5:workDiskAtkPlayer = 1
  98. if bfa < 0: bfa = 0
  99. if pcs_vag > 36: pcs_vag = 36
  100. if pcs_throat > 36: pcs_throat = 36
  101. if pcs_ass > 36: pcs_ass = 36
  102. if cheatSlut = 1 or succubusflag = 1:
  103. !!Succubus cannot get pregnant
  104. mesec = 0
  105. FocH = 0
  106. EggRH = 0
  107. Ovulate = 0
  108. fertegg = 0
  109. UnfertEgg = 0
  110. PregChem = 0
  111. preg = 0
  112. LutH = 0
  113. RecovH = 0
  114. babyembryo = 0
  115. cycle = 1
  116. end
  117. if succubusflag = 1 and succublvl > 2 and rape > rape_count:
  118. !!High Level Succubus cannot get raped
  119. orgasm += 1
  120. rape = rape_count
  121. pcs_mood = 100
  122. end
  123. if pcs_horny < 50 and cheatHorny = 1: pcs_horny = 50
  124. !!These will be made obsolete with the combat system overhaul
  125. boxing = pcs_jab + pcs_punch + pcs_kick + pcs_def
  126. if boxing > 100: boxing = 100
  127. manamax = (pcs_intel * pcs_magik) + pcs_magik * 100 + pcs_vital * 10 + rikudo
  128. !! Set the massage displayed each time the magik attribute is increased.
  129. if $start_type[1] ! 'nomagic':
  130. if pcs_magik > magikhigh:
  131. magikhigh = pcs_magik
  132. rikudo += pcs_magik * 100
  133. $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>'
  134. !! This will be replaced when a more advanced physical system is made
  135. if (pcs_magik mod 2 ! 0) and pcs_eyesize < 2: pcs_eyesize += 1
  136. if (pcs_magik mod 2 = 0) and pcs_lashes < 2: pcs_lashes += 1
  137. end
  138. else
  139. !!This is for error catching but also broke manamax calc which is why its now above this
  140. killvar 'pcs_magik'
  141. killvar 'rikudo'
  142. killvar 'pcs_splcstng'
  143. end
  144. if pcs_dom < 0: SUB = SUB - pcs_dom & pcs_dom = 0
  145. if SUB < 0: pcs_dom = pcs_dom - SUB & SUB = 0
  146. if pcs_dom > 100: pcs_dom = 100
  147. if SUB > 100: SUB = 100
  148. if SUB >= pcs_dom and pcs_dom > 0:SUB = SUB - pcs_dom & pcs_dom = 0
  149. if pcs_dom >= SUB and SUB > 0:pcs_dom = pcs_dom - SUB & SUB = 0
  150. if pcs_horny < 0: pcs_horny = 0
  151. if pcs_inhib < 0:
  152. pcs_inhib = 0
  153. elseif pcs_inhib > 100:
  154. pcs_inhib = 100
  155. end
  156. healthmax = (pcs_vital * 10 + pcs_stren * 5)
  157. stammax = (30* (2 * pcs_vital + pcs_agil + pcs_stren) +1000)/ 13 - pregchem/10
  158. speed = (2 * (pcs_stren + pcs_agil) + pcs_vital) / 5 - pregchem/100
  159. if healthmax < 1: healthmax = 1
  160. if willpowermax < 50: willpowermax = 50
  161. if stammax < 1: stammax = 1
  162. if manamax < 1: manamax = 1
  163. !pre-calc max value for later display
  164. if fairycurse >= daystart and fairyshoo > 0: pcs_horny = 90
  165. if min_arousal > pcs_horny: pcs_horny = min_arousal
  166. if Enable_lockhorny > 0 and pcs_horny < Enable_lockhorny - 1: pcs_horny = Enable_lockhorny - 1
  167. if pcs_horny < 0: pcs_horny = 0
  168. if pcs_health > healthmax: pcs_health = healthmax
  169. if pcs_willpwr > willpowermax: pcs_willpwr = willpowermax
  170. if pcs_stam > stammax: pcs_stam = stammax
  171. if pcs_mana > manamax: pcs_mana = manamax
  172. if pcs_mood > 100: pcs_mood = 100
  173. !!set hair flow free
  174. if hbraids > 5 and pcs_hairbsh = 0: hbraids -= rand(3,5) & pcs_hairbsh = 1
  175. if pcs_hairbsh <= 0:
  176. if hscrunchw <> 0: hscrunchw = 0
  177. if hpingripw <> 0: hpingripw = 0
  178. if hpigtail <> 0: hpigtail = 0
  179. if hbraids <> 0: hbraids = 0
  180. end
  181. !!Add mood_trauma to events to lower max mood for a period of time
  182. if mood_trauma > 0:
  183. mood_max_calc = 100 - (mood_trauma * 5)
  184. mood_max = max(10, mood_max_calc)
  185. if pcs_mood > mood_max: pcs_mood = mood_max
  186. killvar 'mood_max_calc'
  187. elseif mood_trauma < 0:
  188. mood_trauma = 0
  189. end
  190. if hypnoAddict = 1 and pcs_horny < 30:
  191. pcs_horny = 30
  192. elseif hypnoAddict = 2 and pcs_horny < 50:
  193. pcs_horny = 50
  194. end
  195. if cumloc[0] = 1 or cumloc[3] = 1 or hypnoAddict = 0:
  196. killvar 'missCum'
  197. elseif missCum > timeTresh:
  198. if pcs_horny < 90: pcs_horny = 90
  199. if preziktype = 0 or preziktype = 2:
  200. if mc_inventory['normal_condoms'] > 0 and mc_inventory['sabotaged_condoms'] < rand(2,3): dynamic $din_Do_Condom_Counts, 4
  201. if preziktype <> 2 and mc_inventory['sabotaged_condoms'] > 0: dynamic $din_Do_Condom_Counts, 3
  202. end
  203. end
  204. !!!!!!!!!!!
  205. !!!TIME!!!
  206. !!!!!!!!!!!
  207. !! total amount of minutes since the start of the game
  208. if nminut ! minut or nhour ! hour:
  209. prevtotmin = totminut
  210. ! sync totminut with daystart
  211. totminut = daystart - 1
  212. ! Hours
  213. totminut = totminut * 24 + hour
  214. ! Minutes
  215. totminut = totminut * 60 + minut
  216. nminut = minut
  217. nhour = hour
  218. end
  219. ! Execute time based spells
  220. gs 'spellTimer', prevtotmin, totminut
  221. ! Determine Incoming Telephone Calls
  222. gs 'telefon', 'IncomingCheck', prevtotmin, totminut
  223. !! deodorant
  224. if deodorant_on = 1 and totminut > deodorant_time: gs 'sweat', 'remove_deo'
  225. !!painkiller
  226. if pain['killer'] > 0:
  227. if pain['killer'] = 1: pain_timer = totminut - 2
  228. pain['killer'] = totminut - pain_timer
  229. if pain['killer'] >= 243: pain['killer'] = 0
  230. end
  231. ! WD: 'daystart' Should start at 1
  232. if daystart = 0: daystart = 1
  233. !!Gaping of vagina recovery time
  234. !! [1] stored gape value
  235. !! [3] timer
  236. !! [4] time between each reduction in gape
  237. if agape[4] = 0: agape[4] = 10
  238. if vgape[4] = 0: vgape[4] = 10
  239. if vgape > vgape[1]:
  240. vgape[3] = totminut
  241. vgape[1] = vgape
  242. elseif vgape > 0:
  243. if (totminut - vgape[3])/vgape[4] >= 1: vgape -= 1
  244. vgape[1] = vgape
  245. else
  246. vgape[3] = 0
  247. end
  248. !!Gaping of anus recovery time
  249. if agape > agape[1]:
  250. agape[3] = totminut
  251. agape[1] = agape
  252. elseif agape > 0:
  253. if (totminut - agape[3])/agape[4] >= 1: agape -= 1
  254. if agape = 0: agape[3] = 0
  255. agape[1] = agape
  256. else
  257. agape[3] = 0
  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 - 30: 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. !! Hourly Changes
  363. if minut >= 60:
  364. :loopmin
  365. hour += 1
  366. minut -= 60
  367. gs 'hourly_events'
  368. if minut >= 60:jump 'loopmin'
  369. end
  370. !! End of Hourly Changes
  371. if hour >= 24: gs 'cikl'
  372. if minut < 10:
  373. $nilmin = '0'
  374. else
  375. $nilmin = ''
  376. end
  377. if kid > 0:
  378. i = arrsize('yearkid')
  379. :LoopKidAgeCounter
  380. if i >= 0:
  381. if yearkid[i] = year + 1 and monthkid[i] = month and daykid[i] = day: msg'It is <<$kidname[i]>>''s birthday today.'
  382. i -= 1
  383. jump 'LoopKidAgeCounter'
  384. end
  385. end
  386. if bimbolevel > 0:
  387. if bimbowithdrawal = 0:
  388. $bimbostatus = '<font color = #FF1493>You''re, like, super hawt today.</font>'
  389. $bimbo_tooltip = 'You''re, like, super hawt today.'
  390. elseif bimbowithdrawal = 1:
  391. $bimbostatus = '<font color="green">You feel, like, kind of lame today.</font>'
  392. $bimbo_tooltip = 'You feel, like, kind of lame today.'
  393. elseif bimbowithdrawal < 4:
  394. $bimbostatus = '<font color="grey">You feel, like, totally lame today.</font>'
  395. $bimbo_tooltip = 'You feel, like, totally lame today.'
  396. elseif bimbowithdrawal < 6:
  397. if pcs_mood > 50: pcs_mood -= 10
  398. $bimbostatus = '<font color="red">You really feel, like, awful today.</font>'
  399. $bimbo_tooltip = 'You really feel, like, awful today.'
  400. elseif bimbowithdrawal >= 6:
  401. if pcs_mood > 10: pcs_mood -= 10
  402. $bimbostatus= '<font color="red"><b>You feel that, like, horrible today!</b></font>'
  403. $bimbo_tooltip = 'You feel that, like, horrible today!'
  404. end
  405. else
  406. bimbowithdrawal = 0
  407. $bimbostatus = ''
  408. end
  409. !
  410. ! WD: Triggers every 15 minutes if not sleeping
  411. ! Update to remove long iterations on loading saves from previous versions
  412. ! Do Nothing if sleeping, invalid Trig15Minute value or more than 6 hours 16 minute pass
  413. if InSleep ! 0 or Trig15Minute > totminut or (totminut - Trig15Minute) >= 376:
  414. set Trig15Minute = totminut
  415. ! More than 15 minutes since last check
  416. else
  417. if (totminut - Trig15Minute) >= 15:
  418. ! begin Loop
  419. :Trig15MinuteLoop
  420. ! Horny Actions
  421. if pcs_horny > 100:
  422. set Trig15Minute = totminut
  423. else
  424. set Trig15Minute += 15
  425. ! WD: Fix vibrator arousal to trigger every 15 minutes, moved from 'time' location
  426. if vibratorin = 1:pcs_horny += rand(1, 5)
  427. ! WD: Fixed Piecing arousal to trigger every 15 minutes, instead of once per day
  428. if pcs_horny < 70:
  429. hornystat = 0
  430. if pirsF > 0 and pirsF < 10000:hornystat += 1
  431. if pirsG > 0 and pirsG < 10000:hornystat += 1
  432. hornyStat = hornystat * 4
  433. if pirsA > 0 and pirsA < 10000:hornystat += 1
  434. if pirsB > 0 and pirsB < 10000:hornystat += 1
  435. if pirsC > 0 and pirsC < 10000:hornystat += 1
  436. if pirsD > 0 and pirsD < 10000:hornystat += 1
  437. if pirsE > 0 and pirsE < 10000:hornystat += 1
  438. if pirsN > 0 and pirsN < 10000:hornystat += 1
  439. set pcs_horny += hornyStat / 4 + rand(1,4) <= hornyStat mod 4 & ! Apply 1/4 of value on average
  440. end
  441. ! WD: Clothing
  442. if CloStyle = 4 and pcs_horny < 70:set pcs_horny += rand(0, 2)
  443. if (PCloSkirt > 5 or PCloPants > 5) and pcs_horny < 50:set pcs_horny += rand(0, 1)
  444. if PCloTopCut = 4 and pcs_horny < 50:set pcs_horny += rand(0, 1)
  445. end
  446. !!SECTION: Bimbo (15 minute interval update checks)
  447. if bimbolevel > 0:
  448. if (pcs_mood < 100): pcs_mood += (pcs_mood / 100) * max(0, (rand(bimbowithdrawal*-1,bimbolevel)))
  449. if pcs_horny < max(0, 30 - bimbowithdrawal * bimbolevel): pcs_horny = max(0, 30 - bimbowithdrawal * bimbolevel)
  450. if pcs_horny < 100: pcs_horny += max(0, rand(bimbowithdrawal/-2, bimbolevel))
  451. end
  452. !!SECTION: Commando trait (15 minute interval update checks)
  453. if $clothingworntype ! 'nude':
  454. if $pantyworntype = 'none':
  455. !! Addition to trait exp/lvls
  456. if pcs_traits['commando_lvl'] = 0:
  457. if PCloSkirt > 0:
  458. pcs_traits['commando_exp'] += 2
  459. else
  460. pcs_traits['commando_exp'] += 1
  461. end
  462. if pcs_traits['commando_exp'] >= 1000:
  463. pcs_traits['commando_exp'] = 50
  464. pcs_traits['commando_lvl'] = 1
  465. 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...'
  466. end
  467. elseif pcs_traits['commando_lvl'] = 1:
  468. pcs_traits['commando_exp'] += 2
  469. if pcs_traits['commando_exp'] >= 1000:
  470. pcs_traits['commando_exp'] = 50
  471. pcs_traits['commando_lvl'] = 2
  472. 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.'
  473. end
  474. elseif pcs_traits['commando_lvl'] = 2:
  475. mosol = 0
  476. pcs_traits['commando_exp'] += 2
  477. if pcs_traits['commando_exp'] >= 1000:
  478. pcs_traits['commando_exp'] = 500
  479. pcs_traits['commando_lvl'] = 3
  480. 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.'
  481. end
  482. elseif pcs_traits['commando_lvl'] = 3:
  483. pcs_traits['commando_exp'] += 1
  484. end
  485. elseif pcs_traits['commando_lvl'] > 0:
  486. !!Reduction from exp/lvls
  487. if pcs_traits['commando_lvl'] = 3:
  488. pcs_traits['commando_exp'] -= 1
  489. pcs_mood -= 1
  490. if pcs_traits['commando_exp'] <= 0:
  491. pcs_traits['commando_exp'] = 500
  492. pcs_traits['commando_lvl'] = 2
  493. 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.'
  494. end
  495. else
  496. pcs_traits['commando_exp'] -= 1
  497. if pcs_traits['commando_exp'] <= -0:
  498. pcs_traits['commando_exp'] = 900
  499. pcs_traits['commando_lvl'] -= 1
  500. end
  501. end
  502. end
  503. !!{
  504. if $braworntype = 'none':
  505. end}
  506. end
  507. !! This is the Succubus non-direct injection (pun intented) sex to sexnutrition and the sexnutrition conversion handling
  508. if succubusflag = 1:
  509. if hypnoAddict > 0: dynamic $RestTherapyVariables
  510. if pcs_horny < 50: pcs_horny = 50
  511. if pcs_horny < 100: pcs_horny += succublvl
  512. if succhungry > 0:
  513. pcs_energy -= succhungry * succublvl
  514. pcs_hydra -= succhungry * succublvl
  515. pcs_sleep -= succhungry * succublvl
  516. end
  517. if arrsize('sparrvol') > 0:
  518. suctempi = -1
  519. :SuccAbsorbLoop
  520. suctempi += 1
  521. if suctempi <= 1 or suctempi = 3 or suctempi = 4 or suctempi >= 8:
  522. suctemparr = arrpos('sparrloc',suctempi)
  523. if suctemparr >= 0 and sparrloc[suctemparr] = suctempi and sparrvol[suctemparr] > 0:
  524. scfeed = succublvl + rand(1,4)
  525. sexnutrition += 30 * scfeed
  526. succubxp += 5
  527. cumsumbod -= sparrvol[suctemparr]
  528. ! msg "we've got xp!" + sparrloc[suctemparr]
  529. sucabscum = 1
  530. gs 'cum_cleanup', 'cleandeposit', suctemparr
  531. cumloc[suctempi] = 0
  532. !debug code $stat_msg += '<BR>Absorb ext <<sexnutrition>>'
  533. end
  534. end
  535. if suctempi < 17:jump 'SuccAbsorbLoop'
  536. cumspclnt = 20 & gs 'cum_cleanup'
  537. end
  538. if suclezsex < lesbian:
  539. sexnutrition += succublvl * 20
  540. suclezsex = lesbian
  541. succubxp += 5
  542. sucabslez = 1
  543. end
  544. if sexnutrition > 0:
  545. if sucskill >= 3 and succublvl >= 2: sexnutrition += (sexnutrition * 2) / 10
  546. if sucabslez = 1 and sucabscum = 1:
  547. $sucabs1 = 'absorbed energy from the woman you had sex with'
  548. $sucabs2 = ' and you '
  549. $sucabs3 = 'absorb the semen in your body'
  550. elseif sucabscum = 1:
  551. $sucabs3 = 'absorb the semen in your body'
  552. elseif sucabslez = 1:
  553. $sucabs1 = 'absorbed energy from the woman you had sex with'
  554. else
  555. !!Debug code
  556. $stat_msg += '<BR>SOMETHING HAPPENED!'
  557. end
  558. $stat_msg += '<BR>You <<$sucabs1>><<$sucabs2>><<$sucabs3>>, gaining nourishment.'
  559. sucabslez = 0 & sucabscum = 0
  560. $sucabs1 = '' & $sucabs2 = '' & $sucabs3 = ''
  561. if (pcs_mood < 100): pcs_mood += ((pcs_mood / 100) * 5)
  562. if pcs_energy > 100: entemp = (pcs_energy - 100)
  563. if sucexcess < 0 and sexnutrition > 20 and pcs_energy > 30:
  564. if sexnutrition - 20 >= (0 - sucexcess) * 2:
  565. sexnutrition += sucexcess * 2
  566. sucexcess = 0
  567. else
  568. sucexcess += (sexnutrition - 20) / 2
  569. sexnutrition = 20
  570. end
  571. end
  572. pcs_energy += sexnutrition / 2
  573. pcs_hydra += sexnutrition
  574. pcs_sleep += sexnutrition / 20
  575. if succhungry > 0: succhungry = 0
  576. sexnutrition = 0
  577. if pcs_energy > 100: sucexcess += (pcs_energy - entemp - 100) & pcs_energy = 100 + entemp & killvar 'entemp'
  578. end
  579. end
  580. !! safeguards to prevent bimbolevel from going above or below its intended limits
  581. if bimbolevel > 3: bimbolevel = 3
  582. if bimbolevel < 0: bimbolevel = 0
  583. ! do loop
  584. if (totminut - Trig15Minute) >= 15:jump 'Trig15MinuteLoop'
  585. end
  586. end
  587. !!!!!!!!!!!!!
  588. !!!ENERGY!!!
  589. !!!!!!!!!!!!!
  590. if succubusflag = 1:
  591. if pcs_energy < 0:
  592. if fat >= 1:
  593. if cheatNoFat = 0: fat -= 2
  594. pcs_energy += 8 + succublvl
  595. else
  596. pcs_energy += 8 + succublvl
  597. sucexcess -= (8 + succublvl) * (6 - succublvl)
  598. end
  599. end
  600. if pcs_health < 0:
  601. pcs_health = 10
  602. sucexcess -= 25 * (9 - succublvl)
  603. end
  604. if pcs_willpwr < 0:
  605. pcs_willpwr = 10
  606. sucexcess -= 20 * (9 - succublvl)
  607. sucpowzeroed = 4
  608. end
  609. end
  610. if pcs_sleep < 0:
  611. pcs_sleep = 0
  612. pcs_mood -= 5
  613. end
  614. if pcs_energy < 0:
  615. pcs_energy = 0
  616. pcs_health -= 5
  617. if pcs_mass['body'] = 0 and pcs_stren + pcs_vital > 0:
  618. stren_deg -= 1
  619. vital_deg -= 1
  620. pcs_energy += 8
  621. elseif pcs_mass['body'] = 0 and pcs_stren + pcs_vital <= 0:
  622. if Enable_nogameover = 0 :
  623. over = 3
  624. if $loc ! 'gameover': gt 'gameover'
  625. exit
  626. else
  627. $stat_msg += '<BR><font color=red><B>You starved to death, but Cheat Mode keeps you Alive.</B></font>'
  628. fat = 1
  629. end
  630. elseif pcs_mass['body'] > 0:
  631. if cheatNoFat = 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. if Enable_nogameover = 0 :
  647. over = 1
  648. if $loc ! 'gameover': gt 'gameover'
  649. exit & !nogameover by illume
  650. else
  651. $stat_msg += '<BR><font color=red><B>You died from injuries, but Cheat Mode keeps you Alive.</B></font>'
  652. pcs_health = 0
  653. end
  654. end
  655. if pcs_willpwr <= 0 :
  656. !this will set willpower to 0 correctly; then check mana =1 for insane-gameover(pcs_willpwr=0&mana=1).
  657. if pcs_mood <= 1:
  658. if Enable_nogameover = 0 :
  659. over = 2
  660. if $loc ! 'gameover': gt 'gameover'
  661. exit & !nogameover by illume
  662. else
  663. $stat_msg += '<BR><font color=red><B>You are insane, but Cheat Mode keeps you Alive.</B></font>'
  664. !pcs_mood already checked for >=1 in line 1113 if pcs_mood <= 0, no need to set another one
  665. end
  666. end
  667. pcs_willpwr = 0
  668. end
  669. !!cars-increase/depressed mood after orgasm/rape
  670. if rape > 0 and rape ! rape_count and orgasm = orgasm_count:
  671. pcs_mood = 10
  672. rape_count = rape
  673. elseif orgasm > 0 and orgasm ! orgasm_count:
  674. pcs_mood = 100
  675. orgasm_count = orgasm
  676. elseif rape > 0 and rape ! rape_count and orgasm > 0 and orgasm ! orgasm_count:
  677. pcs_mood = 100
  678. orgasm_count = orgasm
  679. rape_count = rape
  680. end
  681. !! Drug stats
  682. gs 'drugs', 'heroin', 'stat'
  683. gs 'drugs', 'alcohol', 'stat'
  684. gs 'drugs', 'cocaine', 'stat'
  685. gs 'drugs', 'amphetamine', 'stat'
  686. !!Health, Willpower, Auto Birth Control pregnancy check
  687. gs 'body', 'RegularUpdate'
  688. gs 'body', 'Update_Appearance'
  689. if pcs_health >= healthmax:
  690. $pcs_health = '<font color="green">You are very healthy.</font>'
  691. elseif pcs_health >= healthmax * 75 / 100:
  692. $pcs_health = '<font color=#0064FF>You are healthy.</font>'
  693. elseif pcs_health >= healthmax * 50 / 100:
  694. $pcs_health = '<font color="brown">You are not healthy.</font>'
  695. elseif pcs_health >= healthmax * 25 / 100:
  696. $pcs_health = '<font color="red">You are sick.</font>'
  697. else
  698. $pcs_health = '<font color="red">You are on the verge of death.</font>'
  699. end
  700. if pcs_willpwr >= willpowermax:
  701. $pcs_willpwr = '<font color="green">You feel in charge of your actions.</font>'
  702. elseif pcs_willpwr >= willpowermax * 75 / 100:
  703. $pcs_willpwr = '<font color=#0064FF>You are mostly in control.</font>'
  704. elseif pcs_willpwr >= willpowermax * 50 / 100:
  705. $pcs_willpwr = '<font color="brown">You might have to make some concessions.</font>'
  706. elseif pcs_willpwr >= willpowermax * 25 / 100:
  707. $pcs_willpwr = '<font color="red">You will have to toe the line.</font>'
  708. else
  709. $pcs_willpwr = '<font color="red">You are completely at other people''s mercy.</font>'
  710. end
  711. !!stop auto birth control pill taking if the player believes they are pregnant or are pregnant
  712. if thinkpreg = 1 or knowpreg = 1:
  713. if tabletkicheck = 1: tabletkicheck = 0
  714. if birth_control['remind_hour'] > 0:
  715. birth_control['remind_hour'] = 0
  716. if birth_control['remind_icon'] = 1: birth_control['remind_icon'] = 0
  717. end
  718. elseif birth_control['remind_hour'] > 0 and hour >= birth_control['remind_hour'] and hour <= birth_control['remind_hour'] + 1 and tabletkiday ! daystart:
  719. birth_control['remind_icon'] = 1
  720. else
  721. birth_control['remind_icon'] = 0
  722. end
  723. 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':
  724. gs 'fertility', 'auto_pill'
  725. end
  726. !! detected change in pillcon
  727. if pillcon ! birth_control['old_pillcon'] or pillcon2 ! birth_control['old_pillcon2']: gs 'fertility', 'update'
  728. gs 'cum_manage', 'cum_decay'
  729. !!Mood
  730. if cheatNoMood = 0:
  731. maxmood = 100 - moodmodifier
  732. if pcs_mood > 100:
  733. pcs_mood = 100
  734. elseif pcs_mood < 0:
  735. pcs_mood = 0
  736. !! 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
  737. end
  738. else
  739. pcs_mood = 100
  740. mood_trauma = 0
  741. end
  742. if Gerpes >= 3 or Sifilis >= 21 or Triper > 2:
  743. $msg_extra = ' it is being reduced due to an STD'
  744. else
  745. killvar '$msg_extra'
  746. end
  747. if pcs_mood >= 80:
  748. $pcs_mood = '<font color="green">You are in a great mood<<$msg_extra>>.</font>'
  749. elseif pcs_mood >= 60:
  750. $pcs_mood = '<font color=#0064FF>You are in a good mood<<$msg_extra>>.</font>'
  751. elseif pcs_mood >= 40:
  752. $pcs_mood = '<font color="brown">You are in an OK mood<<$msg_extra>>.</font>'
  753. elseif pcs_mood >= 20:
  754. $pcs_mood = '<font color="orange">You are in a bad mood<<$msg_extra>>.</font>'
  755. elseif pcs_mood >= 5:
  756. $pcs_mood = '<font color="red">You are in a terrible mood<<$msg_extra>>.</font>'
  757. else
  758. $pcs_mood = '<font color="red">You are really depressed and need to improve your mood<<$msg_extra>>.</font>'
  759. end
  760. if pcs_energy >= 80:
  761. $pcs_energy = '<font color="green">You couldn''t eat one more bite.</font>'
  762. elseif pcs_energy >= 40:
  763. $pcs_energy = '<font color=#0064FF>You''re not really hungry, but a small snack would be very welcome.</font>'
  764. elseif pcs_energy >= 8:
  765. $pcs_energy = '<font color="brown">You are hungry.</font>'
  766. else
  767. $pcs_energy = '<font color="red">You are very hungry.</font>'
  768. end
  769. if pcs_hydra >= 80:
  770. $pcs_hydra = '<font color="green">You are not thirsty at all.</font>'
  771. elseif pcs_hydra >= 40:
  772. $pcs_hydra = '<font color=#0064FF>You are slightly thirsty.</font>'
  773. elseif pcs_hydra >= 8:
  774. $pcs_hydra = '<font color="brown">You are thirsty.</font>'
  775. else
  776. $pcs_hydra = '<font color="red">You are very thirsty.</font>'
  777. end
  778. if pcs_sleep >= 80:
  779. $pcs_sleep = '<font color="green">You are well rested.</font>'
  780. elseif pcs_sleep >= 40:
  781. $pcs_sleep = '<font color=#0064FF>You are slightly tired.</font>'
  782. elseif pcs_sleep >= 8:
  783. $pcs_sleep = '<font color="brown">You are tired.</font>'
  784. else
  785. $pcs_sleep = '<font color="red">You are very tired.</font>'
  786. end
  787. 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:
  788. !!absence from work in a factory in Pavlovsk
  789. FabrikaProgul += 1
  790. FabrikaProgulDay = day
  791. end
  792. if hotelRoom['pav_hotel'] > 0:
  793. if hotelRoomDays['pav_hotel'] - 1 = daystart:
  794. $stat_msg += '<BR>You have 1 night left on your Pavlosk hotel booking.'
  795. elseif hotelRoomDays['pav_hotel'] = daystart and hour < 11:
  796. $stat_msg += '<BR>Your room at the Pavlosk hotel has check out today at 11:00'
  797. elseif hotelRoomDays['pav_hotel'] = daystart:
  798. hotelRoom['pav_hotel'] = 0
  799. end
  800. end
  801. if hotelRoom['city_hotel'] > 0:
  802. if hotelRoomDays['city_hotel'] - 1 = daystart:
  803. $stat_msg += '<BR>You have 1 night left on your St Petersburg hotel booking.'
  804. elseif hotelRoomDays['city_hotel'] = daystart and hour < 11:
  805. $stat_msg += '<BR>Your room at the St Petersburg hotel has check out today at 11:00'
  806. elseif hotelRoomDays['city_hotel'] = daystart:
  807. hotelRoom['city_hotel'] = 0
  808. end
  809. end
  810. 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:
  811. !!absence from school
  812. schoolprogul += 1
  813. schoolProgulDay = daystart
  814. end
  815. if cumcondslip <= 0: cumcondslip_deep = 0
  816. !!Sex stat update
  817. stat['mast'] += mastr & mastr = 0
  818. stat['hj'] += hj & hj = 0
  819. stat['bj'] += bj & bj = 0
  820. stat['vaginal'] += sex & sex = 0
  821. stat['anal'] += anal & anal = 0
  822. stat['cuni'] += kuni & kuni = 0
  823. stat['anal_strap_give'] += pegging & pegging = 0
  824. !!Pain calculation
  825. gs 'pain', 'calc'
  826. pain['relief'] = 0
  827. gs 'drugs', 'pain_relief'
  828. if pain['relief'] ! 0:
  829. if (pain['total'] / pain['relief']) > 0:
  830. pain['total'] = pain['total'] / pain['relief']
  831. elseif pain['total'] > 0:
  832. pain['total'] = 0
  833. end
  834. end
  835. if pain['total'] > 80:
  836. if (pcs_health * 5) >= healthmax: pcs_health = pcs_health * 20 / 100
  837. if (pcs_mood * 5) >= 100: pcs_mood = pcs_mood * 20 / 100
  838. elseif pain['total'] > 60:
  839. if (pcs_health * 5 / 2) >= healthmax: pcs_health = pcs_health * 40 / 100
  840. if (pcs_mood * 5 / 2) >= 100: pcs_mood = pcs_mood * 40 / 100
  841. elseif pain['total'] > 40:
  842. if (pcs_health * 5 / 3) >= healthmax: pcs_health = pcs_health * 60 / 100
  843. if (pcs_mood * 5 / 3) >= 100: pcs_mood = pcs_mood * 60 / 100
  844. elseif pain['total'] > 20:
  845. if (pcs_health * 5 / 4) >= healthmax: pcs_health = pcs_health * 80 / 100
  846. if (pcs_mood * 5 / 4) >= 100: pcs_mood = pcs_mood * 80 / 100
  847. elseif pain['total'] > 0:
  848. if (pcs_health * 10 / 9) >= healthmax: pcs_health = pcs_health * 90 / 100
  849. if (pcs_mood * 10 / 9) >= 100: pcs_mood = pcs_mood * 90 / 100
  850. end
  851. !!--------------------------pain calculation end--------------------------------
  852. !!update skills and attributes to pcs_ from there _lvl values plus adjustments based on condition
  853. gs 'stat_sklattrib_lvlset'
  854. !!Sleep variable cap
  855. if pcs_sleep > 100: pcs_sleep = 100
  856. if insleep = 0: gs 'stat_display'
  857. gs 'family_schedule'
  858. !!--------------------------Job Checks For Icons--------------------------------
  859. if (acting['shoot_day'] = daystart and actress_cast = 1) or (audition['day'] = daystart):
  860. acting['icon'] = 1
  861. else
  862. acting['icon'] = 0
  863. end
  864. if model_job_week < 2 and model['status'] = 1:
  865. model['icon'] = 1
  866. else
  867. model['icon'] = 0
  868. end
  869. if pfilmday[0] > 0:
  870. pornstar['icon'] = 1
  871. else
  872. pornstar['icon'] = 0
  873. end
  874. if hypnoSchedule = 1:
  875. if therapist_weekly_block = 0 and week = 4 and therapistday ! daystart and remindedtherapyday ! daystart:
  876. if menu_off = 0 and workDolg = 0:
  877. if (hour >= 18 and (minut > 45 or hour >= 19)) _
  878. and (hour < 20 and (minut < 15 or hour < 19)):
  879. gs 'therapist_reminder'
  880. end
  881. end
  882. end
  883. end
  884. !!--------------------------Booty Call SMSs--------------------------------
  885. if arrsize('$FuckBuddy') > 0 and hour > 1: gs 'booty_call', 'SMS raiser'
  886. --- stat ---------------------------------