Author Topic: VCE Minigame Time help  (Read 507 times)

i need a minigame set time so i can pay peopl every half hour and have hourly bell go off.

bump

i just reviewed what my last post said and it sound sooo noobish.  im sorry, it was late.

Anyway, ill rephrase it.

For my Island/City RP, i needed a way to pay people, collect taxes, and collect rent in an easy, 'timely' (pun) manner.  i figured i could use "onminigamereset-blah blah blah-special start time sequence only i know."  i totally forgot that onminireset doesnt work with vce, so now ive decided to do a clickable event just to start it off.

i havent tried this yet, but i think it should work.

0
  • [onactivate]-[self]-[dosub] [1] [2]


1
  • [onsub]-[self]-[dosub]

2
  • [1000]-[onsub]-[minigame]-[VCEmodvariable]-[Time]-[add]-[1]


im assuming this would work, then i would go back and add in the hourly bell, pay,rent, and all that

what i want to know is how i can save the amount of time it is currently without clicking it again to stop the clock, just me ending or quitting the server.

I don't remember exactly, but I THINK you can save the brick's variable, and load it up the next time it's clicked. Save it every time it increases. Or you could have separate times on each player that save along with the rest of their variables, then load when they click that first brick.

Success!  My plan below worked for time, except i had to set event 2's delay to 0 and event 1's delay to 1000, the original design made a lot of lag.

Now that the time works, im gunna need a way to have every person's "pay" variable added to their "money" variable every five minutes.

"pay" is how much the person's job pays them.  "Money" is a player variable and "pay" is a client variable.  I do time as seen below except that i changed the variable "time" as seen below to "TimeSec".  I have some if values in the brick that checks to see if the seconds were at 60 seconds, it subtracts 60 from seconds and adds 1 to "TimeMin".  This continues on for hour, day, month, and year.  Now i just need a way to globally add everyone's pay variable to their money variable.