Jump to content

Help needed using JFormDB to store data


Darolok

Recommended Posts

Posted

I was looking for a way to store certain date for a large amount of objects and thought that i could use JFormDB to achieve this. However, after trying to understand the way this operates using the tutorial provided here: https://github.com/SilverIce/JContainers/blob/master/JC.md#reference i seem to be missing an elemental part to initializing the needed form objects.

 

This:

Function MIMQuestInfosfill()
	MIMCreateQuestStorage (MIMQuest01Form, "Testquest", 1, -1, 1, 0)
	MIMCreateQuestStartpoints (MIMQuest01Form, 1, 2, 3, 4, 5)
	form me
	int tset = JMap.object()
	JFormDB.setFlt(me, ".yourModFormStorage.valueKey", 10)
	JFormDB.setStr(me, ".yourModFormStorage.anotherValueKey", "name")
	;;;and retrieve values
	float value = JFormDB.getFlt(me, ".yourModFormStorage.valueKey")
	Debug.MessageBox(value)
EndFunction

Is basically an almost unmodified version of the first tutorial Code (I added the messagebox at the bottom and the lines on the top are leftover code). The Problem is that while the MessageBox shows as expectet, it always prints 0.00000 (instead of the saved 10)

Can anyone explain what i am missing? I assume it has to do with the initialization of the form "me" but i couldn't figure out what.

 

EDIT: This topic can be closed, you can find the answer here: http://www.loverslab.com/topic/24777-jcontainers/page-14

Archived

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

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...