• Announcements

    • Ashal

      SITE MOVED - IN READ ONLY MODE   12/08/2015

      Please use http://www.loverslab.com moving forward. Site has been restored to a previous version, and this one placed into a read-only mode. This is available for a limited time so users may reference/copy content that has been lost in the transition. This will no longer be accessible by December 22nd, 2015.

Archived

This topic is now archived and is closed to further replies.

Hitman69

Scripting help would be much appreciated.

Well, as noted in the Monstergirl-Thread, I'm hard at work at building a mod for milking minotaur-girls.

It almost works, but I can't seem to fix the issue I'm having right now.

I've made a script that puts all the minotaur-girls that appear in an array, and have this questscript:

scn xLoversMilkquestSCRIPT

short Once

ref Offence
ref Defence

short SPos
short DownTimeOld
short amountofmilk

array_var listofminotaurs

long oldnumberofdays
long currentday

short MyIndex

Ref Minotaur
short AmountofMilkOwned
short AmountofMilkToAdd
short MinotaurHealth
short MinotaurMaxHealth
short MaxMilk

Begin GameMode

if GetGameRestarted
Let Once := 1
endif
if Once == 0
Let listofminotaurs := ar_Construct Array
set Once to 1
endif

if GetGameLoaded || GetGameRestarted
AddTopic xLoversCanMilk
endif

Let currentday := GameDaysPassed
if currentday == oldnumberofdays
return
else
Let MyIndex := 0
while MyIndex < ar_Size listofminotaurs
Let Minotaur := listofminotaurs[MyIndex]

;Let MinotaurHealth := Minotaur.GetCurrentHealth
;Let MinotaurMaxHealth := Minotaur.GetBaseAV2 Health
; ^ does not work, needs fixing ^

let AmountofMilkOwned := Minotaur.GetItemCount Gotmilk
let MaxMilk := 3
;let MaxMilk := 1 + 2 * MinotaurMaxHealt / MinotaurHealth
Let AmountofMilkToAdd := Rand 1 MaxMilk
if AmountofMilkToAdd > 10 - AmountofMilkOwned
Let AmountofMilkToAdd := 10 - AmountofMilkOwned
endif
Minotaur.AddItem Gotmilk AmountofMilkToAdd
let MyIndex += 1
loop
endif
End

The problem is that I keep getting this error:

52	Left of dot must be quest or persitent reference

It's referring to this line:

			let AmountofMilkOwned := Minotaur.GetItemCount Gotmilk

If anyone knows how to fix this, please help. It's the last part of the puzzle that is this mod. I'm guessing that if this thing is fixed, it will also enable me to use health-values for choosing the limits for milk-adding.

If it is any help, I'm using OBSE arrays, not Pluggy Arrays (because Pluggy is apparently buggy and crashy)

0

Share this post


Link to post