Author Topic: VCE Saving Variables about a brick?  (Read 588 times)

I want to make some kind of stat loggers with VCE I.E. how many times was x done y times in the server.

It works, up to the point when I restart the server, saving or not.

There's no saveVariable or loadVaraible for Brick.

Does anyone know any way to save/load Brick variables? Or for the matter if they can make one (but this would be in Suggestions & Requests then I guess).

I kind of thought I remember that brick saves automatically, but if it doesn't, then I do want a new event to add Minigame and Brick to the save variable list.

If no one makes one, then you could always use some complicated system with printcount recall.

The only legitimate solution to this is to move the variable from the brick to the client, then save it.
Whenever you need it again, move it from the client to the brick.

So have my client hold all items.

Like..

onMinigameKill - OwnerClient - loadVariable - Kills
onMinigameKill - OwnerClient -  vcemodVariable - CLKills Add 1
onMinigameKill - OwnerClient - saveVariable - Kills
onMinigameKill - Brick - vcemodVariable - Kill Set <var:cl:CLKills>
onActivate - Client - chatMessage - Total amount of kills on the server: <var:br:CLKills>

Would that work?

So have my client hold all items.

Like..

onMinigameKill - OwnerClient - loadVariable - Kills
onMinigameKill - OwnerClient -  vcemodVariable - CLKills Add 1
onMinigameKill - OwnerClient - saveVariable - Kills
onMinigameKill - Brick - vcemodVariable - Kill Set <var:cl:CLKills>
onActivate - Client - chatMessage - Total amount of kills on the server: <var:br:CLKills>

Would that work?

Um

It's a bit much, and unorganized, but I get it.

I'm pretty sure I get what you want, just a way to display number of people killed on the server?

I think it'd be better to do minigame.

Code: [Select]
[0] [onminigamekill] [minigame] [VCE_Modvariable] [Kills] [add] [1]
[1] [onactivate] [Client] [centerprint] [<var:mg:Kills> kills in the game]

This should work, although I only dabble in minigame input events.

Um

It's a bit much, and unorganized, but I get it.

I'm pretty sure I get what you want, just a way to display number of people killed on the server?

I think it'd be better to do minigame.

Code: [Select]
[0] [onminigamekill] [minigame] [VCE_Modvariable] [Kills] [add] [1]
[1] [onactivate] [Client] [centerprint] [<var:mg:Kills> kills in the game]

This should work, although I only dabble in minigame input events.

No stuff, I have no problem on that part.

But they reset after a minigame change/reset etc. I want to have the starts regardless if I reload minigame, reload save, restart server or PC.