Author Topic: Money Saving  (Read 3656 times)

0 Members and 2 Guests are viewing this topic.

Offline Tamas

  • Made Man
  • ***
  • Posts: 127
    • View Profile
    • http://www.tamasnet.eu/
Money Saving
« on: August 04, 2008, 04:31:52 am »
I has a money saving error if somebody quit or crash or etc... and not deposit his money he will lost all i tryed this code but its not work:

Quote
on *:SIGNAL:vcmp.event.part:{
  !writeini vcmp.money.ini MONEY $2 $vcmp.hgetmoney($1)

And how can i do that if i rejoin or somebody than the server read the correct players money from that file?

Offline Tommis

  • VC:MP Beta Tester (inactive)
  • Wiseguy
  • *
  • Posts: 56
    • View Profile
Re: Money Saving
« Reply #1 on: August 04, 2008, 05:31:26 am »
Hey,

When working under the player part signal, remember always that you cannot use ID's. The player has left, if you try running a command to get the players name or information from the ID, it simply will not work because the player is not there anymore.

To get the player name, I would work with the signal to improve it, or sync player names to be saved to a var or smt before the player leaves.

Regards,
Tommis

Offline Youpi!

  • Street Thug
  • *
  • Posts: 10
    • View Profile
Re: Money Saving
« Reply #2 on: August 09, 2008, 12:06:40 am »
O.o i think i gave you the way to fix that
But there is one more problem
somepeople when join gets a lot of money and i don't know how to fix that :( or even why the reason it happends

Offline Tamas

  • Made Man
  • ***
  • Posts: 127
    • View Profile
    • http://www.tamasnet.eu/
Re: Money Saving
« Reply #3 on: August 09, 2008, 12:38:38 am »
Ok, whatever i solved the problem now.
When somebody quit, than the server check his money and write to a txt file, than if he rejoins his money will automatically reloaded from txt.

The money bug is not related to script, its the vc-mp bug, dunno maybe the developer team will fix this or something..