[{"data":1,"prerenderedAt":739},["ShallowReactive",2],{"content-query-2aVK9U1zk6":3},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":7,"icon":9,"body":10,"_type":733,"_id":734,"_source":735,"_file":736,"_stem":737,"_extension":738},"/ramdb/getting-started","ramdb",false,"","ArmaRAMDb - Getting Started","mdi:file-text-outline",{"type":11,"children":12,"toc":724},"root",[13,22,29,36,56,62,68,74,114,126,141,150,286,298,305],{"type":14,"tag":15,"props":16,"children":18},"element","h1",{"id":17},"getting-started",[19],{"type":20,"value":21},"text","Getting Started",{"type":14,"tag":23,"props":24,"children":26},"h2",{"id":25},"armaramdb",[27],{"type":20,"value":28},"ArmaRAMDb",{"type":14,"tag":30,"props":31,"children":33},"h3",{"id":32},"prerequisites",[34],{"type":20,"value":35},"Prerequisites",{"type":14,"tag":37,"props":38,"children":39},"ul",{},[40,46,51],{"type":14,"tag":41,"props":42,"children":43},"li",{},[44],{"type":20,"value":45},"Network access",{"type":14,"tag":41,"props":47,"children":48},{},[49],{"type":20,"value":50},"Minimum 4GB of RAM to get the benifits of RAMDb",{"type":14,"tag":41,"props":52,"children":53},{},[54],{"type":20,"value":55},"Minimum 1CPU Core",{"type":14,"tag":30,"props":57,"children":59},{"id":58},"os-compatibility",[60],{"type":20,"value":61},"OS Compatibility",{"type":14,"tag":63,"props":64,"children":65},"p",{},[66],{"type":20,"value":67},"ArmaRAMDb is currently only compatible with Windows. Linux is planned for a future release.",{"type":14,"tag":30,"props":69,"children":71},{"id":70},"usage",[72],{"type":20,"value":73},"Usage",{"type":14,"tag":75,"props":76,"children":77},"ol",{},[78,95,100],{"type":14,"tag":41,"props":79,"children":80},{},[81,83,93],{"type":20,"value":82},"Download the latest release from the ",{"type":14,"tag":84,"props":85,"children":90},"a",{"href":86,"rel":87,"target":89},"https://gitea.innovativedevsolutions.org/IDSolutions/ramdb/releases/latest",[88],"nofollow","_blank",[91],{"type":20,"value":92},"Releases",{"type":20,"value":94}," page.",{"type":14,"tag":41,"props":96,"children":97},{},[98],{"type":20,"value":99},"Extract the zip file to your Arma 3 directory.",{"type":14,"tag":41,"props":101,"children":102},{},[103,105,112],{"type":20,"value":104},"Create the ",{"type":14,"tag":106,"props":107,"children":109},"code",{"className":108},[],[110],{"type":20,"value":111},"init.sqf",{"type":20,"value":113}," file in your mission folder and add the following code:",{"type":14,"tag":115,"props":116,"children":121},"pre",{"className":117,"code":119,"language":120,"meta":7},[118],"language-sqf","addMissionEventHandler [\"ExtensionCallback\", {\n    params [\"_name\", \"_function\", \"_data\"];\n    diag_log _this;\n    if (_name isEqualTo \"ArmaRAMDb\") then {\n        parseSimpleArray _data call (missionNamespace getVariable [_function, {\n            hint \"Function does not exist!\"\n        }]);\n    };\n}];\n","sqf",[122],{"type":14,"tag":106,"props":123,"children":124},{"__ignoreMap":7},[125],{"type":20,"value":119},{"type":14,"tag":75,"props":127,"children":129},{"start":128},4,[130],{"type":14,"tag":41,"props":131,"children":132},{},[133,134,140],{"type":20,"value":104},{"type":14,"tag":106,"props":135,"children":137},{"className":136},[],[138],{"type":20,"value":139},"initServer.sqf",{"type":20,"value":113},{"type":14,"tag":115,"props":142,"children":145},{"className":143,"code":144,"language":120,"meta":7},[118],"if (isServer || isDedicated) then {\n    true spawn ramdb_db_fnc_init;\n};\n",[146],{"type":14,"tag":106,"props":147,"children":148},{"__ignoreMap":7},[149],{"type":20,"value":144},{"type":14,"tag":75,"props":151,"children":153},{"start":152},5,[154],{"type":14,"tag":41,"props":155,"children":156},{},[157,159],{"type":20,"value":158},"Implement data persistence using ArmaRAMDb:",{"type":14,"tag":37,"props":160,"children":161},{},[162,167,180,193,232,251,256],{"type":14,"tag":41,"props":163,"children":164},{},[165],{"type":20,"value":166},"To enable saving and loading data from ArmaRAMDb, you need to create the necessary functions.",{"type":14,"tag":41,"props":168,"children":169},{},[170,172,178],{"type":20,"value":171},"Refer to the ",{"type":14,"tag":84,"props":173,"children":175},{"href":174},"/ramdb/main/addtask",[176],{"type":20,"value":177},"Add Task",{"type":20,"value":179}," wiki page for detailed information on how to create tasks in ArmaRAMDb.",{"type":14,"tag":41,"props":181,"children":182},{},[183,185,191],{"type":20,"value":184},"Utilize the ",{"type":14,"tag":106,"props":186,"children":188},{"className":187},[],[189],{"type":20,"value":190},"ramdb_db_fnc_addTask",{"type":20,"value":192}," function to add tasks to the ArmaRAMDb queue for saving and loading data.",{"type":14,"tag":41,"props":194,"children":195},{},[196,198,217,226,230],{"type":20,"value":197},"Here's an example of how you can create a task to save data:",{"type":14,"tag":199,"props":200,"children":201},"blockquote",{},[202],{"type":14,"tag":63,"props":203,"children":204},{},[205,215],{"type":14,"tag":206,"props":207,"children":208},"strong",{},[209],{"type":14,"tag":210,"props":211,"children":212},"em",{},[213],{"type":20,"value":214},"IMPORTANT:",{"type":20,"value":216}," All data must be encapsulated by brackets []",{"type":14,"tag":115,"props":218,"children":221},{"className":219,"code":220,"language":120,"meta":7},[118],"[\"hsetid\", getPlayerUID player, \"loadout\", -1, [getUnitLoadout player]] call ramdb_db_fnc_addTask;\n",[222],{"type":14,"tag":106,"props":223,"children":224},{"__ignoreMap":7},[225],{"type":20,"value":220},{"type":14,"tag":227,"props":228,"children":229},"br",{},[],{"type":20,"value":231},"This example adds a task to set the value of the field \"loadout\" in the hash player UID to the player's loadout.",{"type":14,"tag":41,"props":233,"children":234},{},[235,237,246,249],{"type":20,"value":236},"To load data, you can create a task using the appropriate task type, such as \"hgetall\" or \"hget\":",{"type":14,"tag":115,"props":238,"children":241},{"className":239,"code":240,"language":120,"meta":7},[118],"[\"hgetid\", getPlayerUID player, \"loadout\", -1, [], \"myCallbackFunction\", false, netId player] call ramdb_db_fnc_addTask;\n",[242],{"type":14,"tag":106,"props":243,"children":244},{"__ignoreMap":7},[245],{"type":20,"value":240},{"type":14,"tag":227,"props":247,"children":248},{},[],{"type":20,"value":250},"This example adds a task to retrieve all values from the hash player UID and pass the retrieved data to the \"myCallbackFunction\" for further processing.",{"type":14,"tag":41,"props":252,"children":253},{},[254],{"type":20,"value":255},"Ensure that you provide the correct task type, key names, field names, and callback functions based on your specific data requirements. Please refer to the Task Types section below for more information on available task types and their corresponding data types.",{"type":14,"tag":41,"props":257,"children":258},{},[259,261,277],{"type":20,"value":260},"Properly handle the retrieved data in the callback functions to utilize it effectively in your project.",{"type":14,"tag":37,"props":262,"children":263},{},[264],{"type":14,"tag":41,"props":265,"children":266},{},[267,269,275],{"type":20,"value":268},"I.e. implement public variables and ",{"type":14,"tag":106,"props":270,"children":272},{"className":271},[],[273],{"type":20,"value":274},"waitUntil",{"type":20,"value":276}," checks before proceeding onto the next task(s).",{"type":14,"tag":115,"props":278,"children":281},{"className":279,"code":280,"language":120,"meta":7},[118],"// First Script or Function to execute `ramdb_db_fnc_addTask`\nvalue_ExampleDone = false;\npublicVariable \"value_ExampleDone\";\n...\n\n// Callback function to process the retrieved data\n...\nvalue_ExampleDone = true;\npublicVariable \"value_ExampleDone\";\n\n// Next Script or Function to execute `ramdb_db_fnc_addTask`\nwaitUntil { value_ExampleDone };\n...\n",[282],{"type":14,"tag":106,"props":283,"children":284},{"__ignoreMap":7},[285],{"type":20,"value":280},{"type":14,"tag":63,"props":287,"children":288},{},[289,291,296],{"type":20,"value":290},"By following these steps and leveraging the ",{"type":14,"tag":106,"props":292,"children":294},{"className":293},[],[295],{"type":20,"value":190},{"type":20,"value":297}," function, you can implement robust data persistence functionality using ArmaRAMDb in your Arma 3 project.",{"type":14,"tag":299,"props":300,"children":302},"h4",{"id":301},"task-types",[303],{"type":20,"value":304},"Task Types",{"type":14,"tag":306,"props":307,"children":308},"table",{},[309,328],{"type":14,"tag":310,"props":311,"children":312},"thead",{},[313],{"type":14,"tag":314,"props":315,"children":316},"tr",{},[317,323],{"type":14,"tag":318,"props":319,"children":320},"th",{},[321],{"type":20,"value":322},"Task Type",{"type":14,"tag":318,"props":324,"children":325},{},[326],{"type":20,"value":327},"Data Type",{"type":14,"tag":329,"props":330,"children":331},"tbody",{},[332,350,367,384,401,418,435,452,469,486,503,520,537,554,571,588,605,622,639,656,673,690,707],{"type":14,"tag":314,"props":333,"children":334},{},[335,341],{"type":14,"tag":336,"props":337,"children":338},"td",{},[339],{"type":20,"value":340},"del",{"type":14,"tag":336,"props":342,"children":343},{},[344],{"type":14,"tag":84,"props":345,"children":347},{"href":346},"/ramdb/generic/delete",[348],{"type":20,"value":349},"Delete Data Type",{"type":14,"tag":314,"props":351,"children":352},{},[353,358],{"type":14,"tag":336,"props":354,"children":355},{},[356],{"type":20,"value":357},"get",{"type":14,"tag":336,"props":359,"children":360},{},[361],{"type":14,"tag":84,"props":362,"children":364},{"href":363},"/ramdb/generic/get",[365],{"type":20,"value":366},"Get Data Type",{"type":14,"tag":314,"props":368,"children":369},{},[370,375],{"type":14,"tag":336,"props":371,"children":372},{},[373],{"type":20,"value":374},"load",{"type":14,"tag":336,"props":376,"children":377},{},[378],{"type":14,"tag":84,"props":379,"children":381},{"href":380},"/ramdb/generic/load",[382],{"type":20,"value":383},"Load Data Type",{"type":14,"tag":314,"props":385,"children":386},{},[387,392],{"type":14,"tag":336,"props":388,"children":389},{},[390],{"type":20,"value":391},"save",{"type":14,"tag":336,"props":393,"children":394},{},[395],{"type":14,"tag":84,"props":396,"children":398},{"href":397},"/ramdb/generic/save",[399],{"type":20,"value":400},"Save Data Type",{"type":14,"tag":314,"props":402,"children":403},{},[404,409],{"type":14,"tag":336,"props":405,"children":406},{},[407],{"type":20,"value":408},"set",{"type":14,"tag":336,"props":410,"children":411},{},[412],{"type":14,"tag":84,"props":413,"children":415},{"href":414},"/ramdb/generic/set",[416],{"type":20,"value":417},"Set Data Type",{"type":14,"tag":314,"props":419,"children":420},{},[421,426],{"type":14,"tag":336,"props":422,"children":423},{},[424],{"type":20,"value":425},"hdel",{"type":14,"tag":336,"props":427,"children":428},{},[429],{"type":14,"tag":84,"props":430,"children":432},{"href":431},"/ramdb/hashes/hashdelete",[433],{"type":20,"value":434},"Hash Delete Data Type",{"type":14,"tag":314,"props":436,"children":437},{},[438,443],{"type":14,"tag":336,"props":439,"children":440},{},[441],{"type":20,"value":442},"hdelid",{"type":14,"tag":336,"props":444,"children":445},{},[446],{"type":14,"tag":84,"props":447,"children":449},{"href":448},"/ramdb/hashes/hashdeleteid",[450],{"type":20,"value":451},"Hash Delete by ID Data Type",{"type":14,"tag":314,"props":453,"children":454},{},[455,460],{"type":14,"tag":336,"props":456,"children":457},{},[458],{"type":20,"value":459},"hget",{"type":14,"tag":336,"props":461,"children":462},{},[463],{"type":14,"tag":84,"props":464,"children":466},{"href":465},"/ramdb/hashes/hashget",[467],{"type":20,"value":468},"Hash Get Data Type",{"type":14,"tag":314,"props":470,"children":471},{},[472,477],{"type":14,"tag":336,"props":473,"children":474},{},[475],{"type":20,"value":476},"hgetid",{"type":14,"tag":336,"props":478,"children":479},{},[480],{"type":14,"tag":84,"props":481,"children":483},{"href":482},"/ramdb/hashes/hashgetid",[484],{"type":20,"value":485},"Hash Get by ID Data Type",{"type":14,"tag":314,"props":487,"children":488},{},[489,494],{"type":14,"tag":336,"props":490,"children":491},{},[492],{"type":20,"value":493},"hgetall",{"type":14,"tag":336,"props":495,"children":496},{},[497],{"type":14,"tag":84,"props":498,"children":500},{"href":499},"/ramdb/hashes/hashgetall",[501],{"type":20,"value":502},"Hash Get All Data Type",{"type":14,"tag":314,"props":504,"children":505},{},[506,511],{"type":14,"tag":336,"props":507,"children":508},{},[509],{"type":20,"value":510},"hgetallid",{"type":14,"tag":336,"props":512,"children":513},{},[514],{"type":14,"tag":84,"props":515,"children":517},{"href":516},"/ramdb/hashes/hashgetallid",[518],{"type":20,"value":519},"Hash Get All by ID Data Type",{"type":14,"tag":314,"props":521,"children":522},{},[523,528],{"type":14,"tag":336,"props":524,"children":525},{},[526],{"type":20,"value":527},"hrem",{"type":14,"tag":336,"props":529,"children":530},{},[531],{"type":14,"tag":84,"props":532,"children":534},{"href":533},"/ramdb/hashes/hashremove",[535],{"type":20,"value":536},"Hash Remove Data Type",{"type":14,"tag":314,"props":538,"children":539},{},[540,545],{"type":14,"tag":336,"props":541,"children":542},{},[543],{"type":20,"value":544},"hremid",{"type":14,"tag":336,"props":546,"children":547},{},[548],{"type":14,"tag":84,"props":549,"children":551},{"href":550},"/ramdb/hashes/hashremoveid",[552],{"type":20,"value":553},"Hash Remove by ID Data Type",{"type":14,"tag":314,"props":555,"children":556},{},[557,562],{"type":14,"tag":336,"props":558,"children":559},{},[560],{"type":20,"value":561},"hset",{"type":14,"tag":336,"props":563,"children":564},{},[565],{"type":14,"tag":84,"props":566,"children":568},{"href":567},"/ramdb/hashes/hashset",[569],{"type":20,"value":570},"Hash Set Data Type",{"type":14,"tag":314,"props":572,"children":573},{},[574,579],{"type":14,"tag":336,"props":575,"children":576},{},[577],{"type":20,"value":578},"hsetid",{"type":14,"tag":336,"props":580,"children":581},{},[582],{"type":14,"tag":84,"props":583,"children":585},{"href":584},"/ramdb/hashes/hashsetid",[586],{"type":20,"value":587},"Hash Set by ID Data Type",{"type":14,"tag":314,"props":589,"children":590},{},[591,596],{"type":14,"tag":336,"props":592,"children":593},{},[594],{"type":20,"value":595},"hsetbulk",{"type":14,"tag":336,"props":597,"children":598},{},[599],{"type":14,"tag":84,"props":600,"children":602},{"href":601},"/ramdb/hashes/hashsetbulk",[603],{"type":20,"value":604},"Hash Set Bulk Data Type",{"type":14,"tag":314,"props":606,"children":607},{},[608,613],{"type":14,"tag":336,"props":609,"children":610},{},[611],{"type":20,"value":612},"hsetbulkid",{"type":14,"tag":336,"props":614,"children":615},{},[616],{"type":14,"tag":84,"props":617,"children":619},{"href":618},"/ramdb/hashes/hashsetidbulk",[620],{"type":20,"value":621},"Hash Set Bulk by ID Data Type",{"type":14,"tag":314,"props":623,"children":624},{},[625,630],{"type":14,"tag":336,"props":626,"children":627},{},[628],{"type":20,"value":629},"listadd",{"type":14,"tag":336,"props":631,"children":632},{},[633],{"type":14,"tag":84,"props":634,"children":636},{"href":635},"/ramdb/lists/listadd",[637],{"type":20,"value":638},"List Add Data Type",{"type":14,"tag":314,"props":640,"children":641},{},[642,647],{"type":14,"tag":336,"props":643,"children":644},{},[645],{"type":20,"value":646},"listdel",{"type":14,"tag":336,"props":648,"children":649},{},[650],{"type":14,"tag":84,"props":651,"children":653},{"href":652},"/ramdb/lists/listdelete",[654],{"type":20,"value":655},"List Delete Data Type",{"type":14,"tag":314,"props":657,"children":658},{},[659,664],{"type":14,"tag":336,"props":660,"children":661},{},[662],{"type":20,"value":663},"listidx",{"type":14,"tag":336,"props":665,"children":666},{},[667],{"type":14,"tag":84,"props":668,"children":670},{"href":669},"/ramdb/lists/listget",[671],{"type":20,"value":672},"List Get Data Type",{"type":14,"tag":314,"props":674,"children":675},{},[676,681],{"type":14,"tag":336,"props":677,"children":678},{},[679],{"type":20,"value":680},"listrng",{"type":14,"tag":336,"props":682,"children":683},{},[684],{"type":14,"tag":84,"props":685,"children":687},{"href":686},"/ramdb/lists/listload",[688],{"type":20,"value":689},"List Load Data Type",{"type":14,"tag":314,"props":691,"children":692},{},[693,698],{"type":14,"tag":336,"props":694,"children":695},{},[696],{"type":20,"value":697},"listrem",{"type":14,"tag":336,"props":699,"children":700},{},[701],{"type":14,"tag":84,"props":702,"children":704},{"href":703},"/ramdb/lists/listremove",[705],{"type":20,"value":706},"List Remove Data Type",{"type":14,"tag":314,"props":708,"children":709},{},[710,715],{"type":14,"tag":336,"props":711,"children":712},{},[713],{"type":20,"value":714},"listset",{"type":14,"tag":336,"props":716,"children":717},{},[718],{"type":14,"tag":84,"props":719,"children":721},{"href":720},"/ramdb/lists/listset",[722],{"type":20,"value":723},"List Set Data Type",{"title":7,"searchDepth":725,"depth":725,"links":726},2,[727],{"id":25,"depth":725,"text":28,"children":728},[729,731,732],{"id":32,"depth":730,"text":35},3,{"id":58,"depth":730,"text":61},{"id":70,"depth":730,"text":73},"markdown","content:ramdb:getting-started.md","content","ramdb/getting-started.md","ramdb/getting-started","md",1742777961706]