{"id":50875,"date":"2023-09-29T00:00:00","date_gmt":"2023-09-29T07:00:00","guid":{"rendered":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/"},"modified":"2026-03-30T12:19:11","modified_gmt":"2026-03-30T19:19:11","slug":"save-unity-game-data-using-node-js-and-griddb","status":"publish","type":"post","link":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/","title":{"rendered":"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b"},"content":{"rendered":"<h2>\u306f\u3058\u3081\u306b<\/h2>\n<p>\u3053\u306e\u6295\u7a3f\u3067\u306f\u3001<strong>Feed The Animals<\/strong> \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js \u3092\u3001\u30b9\u30c8\u30ec\u30fc\u30b8\u3068\u3057\u3066 GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<h2>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u5b9f\u884c<\/h2>\n<p>GitHub \u30ea\u30dd\u30b8\u30c8\u30ea\u304b\u3089\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e<a href=\"https:\/\/github.com\/junwatu\/unity-node.js-griddb\">\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9<\/a>\u3092\u30af\u30ed\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>git clone https:\/\/github.com\/junwatu\/unity-node.js-griddb.git<\/code><\/pre>\n<\/div>\n<p>\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u306b\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>cd unity-node.js-griddb<\/code><\/pre>\n<\/div>\n<p>\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u7528\u306b Node.js \u306e\u4f9d\u5b58\u95a2\u4fc2\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-sh\">cd appserver\nnpm install<\/code><\/pre>\n<\/div>\n<h3>\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc<\/h3>\n<p>\u30b2\u30fc\u30e0\u3092\u8d77\u52d5\u3059\u308b\u524d\u306b\u3001\u307e\u305a\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u3092\u8d77\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u304b\u3089 <code>appserver<\/code> \u30d5\u30a9\u30eb\u30c0\u306b\u79fb\u52d5\u3057\u3001\u30bf\u30fc\u30df\u30ca\u30eb\u3067\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>npm run start<\/code><\/pre>\n<\/div>\n<p>\u30b5\u30fc\u30d0\u30fc\u306e\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30db\u30b9\u30c8\u3068\u30dd\u30fc\u30c8\u306e\u8a2d\u5b9a\u306f <code>.env<\/code> \u30d5\u30a1\u30a4\u30eb\u306b\u3042\u308a\u307e\u3059\u3002\u4ed6\u306e IP \u30a2\u30c9\u30ec\u30b9\u3068\u30dd\u30fc\u30c8\u3067\u30b5\u30fc\u30d0\u3092\u52d5\u4f5c\u3055\u305b\u305f\u3044\u5834\u5408\u306f\u5909\u66f4\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u4f8b\u3048\u3070\u3001IP \u30a2\u30c9\u30ec\u30b9\u3092 <code>192.168.0.11<\/code>\u3001\u30dd\u30fc\u30c8\u3092 <code>9000<\/code> \u306b\u8a2d\u5b9a\u3057\u3066\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u3092\u52d5\u4f5c\u3055\u305b\u308b\u5834\u5408\u306f <code>.env<\/code> \u30d5\u30a1\u30a4\u30eb\u3092\u958b\u304d <code>GAME_SERVER<\/code> \u5909\u6570\u3092\u7de8\u96c6\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>GAME_SERVER=http:\/\/192.168.0.11:9000<\/code><\/pre>\n<\/div>\n<p>\u305d\u306e\u5f8c\u3001\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u3092\u8d77\u52d5\u307e\u305f\u306f\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n<h3>\u30b2\u30fc\u30e0\u306e\u30d3\u30eb\u30c9<\/h3>\n<p>\u5b9f\u969b\u306e\u30d3\u30eb\u30c9\u3092\u898b\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<h4>Windows \u30d0\u30a4\u30ca\u30ea .exe<\/h4>\n<p>\u3053\u306e\u30b2\u30fc\u30e0\u30d3\u30eb\u30c9\u306f Windows OS \u30de\u30b7\u30f3\u4e0a\u3067\u52d5\u4f5c\u3057\u307e\u3059\u3002\u30d0\u30a4\u30ca\u30ea\u30d3\u30eb\u30c9\u306f\u3053\u3061\u3089\u306e\u30ea\u30f3\u30af\u304b\u3089\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><a href=\"https:\/\/github.com\/junwatu\/unity-node.js-griddb\/releases\/download\/demo\/FeedTheAnimals.Windows-x64.zip\">https:\/\/github.com\/junwatu\/unity-node.js-griddb\/releases\/download\/demo\/FeedTheAnimals.Windows-x64.zip<\/a><\/p>\n<p>\u305d\u308c\u3092\u89e3\u51cd\u3057\u3066\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u306e\u30a2\u30c9\u30ec\u30b9\u3092\u5909\u66f4\u3057\u305f\u3089\u3001\u30b2\u30fc\u30e0\u306e IP \u30a2\u30c9\u30ec\u30b9\u3082\u5909\u66f4\u3057\u3066\u304f\u3060\u3055\u3044\u3002<code>config.json<\/code> \u30d5\u30a1\u30a4\u30eb\u3092\u958b\u304d <code>WebSocketURL<\/code> \u3092\u7de8\u96c6\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-sh\">\n{\n  \"WebSocketURL\": \"http:\/\/192.168.0.11:9000\"\n}<\/code><\/pre>\n<\/div>\n<p>\u305d\u306e\u5f8c\u3001<code>feed.the.animals.exe<\/code> \u30d5\u30a1\u30a4\u30eb\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u30b2\u30fc\u30e0\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\uff01<\/p>\n<p>\u30b2\u30fc\u30e0\u30d7\u30ec\u30a4\u306f\u7c21\u5358\u3067\u3059\u3002\u52d5\u7269\u306b\u990c\u3092\u3084\u308a\u3001\u4f55\u5339\u304b\u990c\u3092\u3084\u3089\u306a\u304b\u3063\u305f\u3089\u8ca0\u3051\u3001\u3064\u307e\u308a\u30b2\u30fc\u30e0\u30aa\u30fc\u30d0\u30fc\u3067\u3059\uff01<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/game-screenshot.png\"><img fetchpriority=\"high\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/game-screenshot.png\" alt=\"\" width=\"1659\" height=\"933\" class=\"aligncenter size-full wp-image-29822\" srcset=\"\/wp-content\/uploads\/2023\/09\/game-screenshot.png 1659w, \/wp-content\/uploads\/2023\/09\/game-screenshot-300x169.png 300w, \/wp-content\/uploads\/2023\/09\/game-screenshot-1024x576.png 1024w, \/wp-content\/uploads\/2023\/09\/game-screenshot-768x432.png 768w, \/wp-content\/uploads\/2023\/09\/game-screenshot-1536x864.png 1536w, \/wp-content\/uploads\/2023\/09\/game-screenshot-150x85.png 150w, \/wp-content\/uploads\/2023\/09\/game-screenshot-600x337.png 600w\" sizes=\"(max-width: 1659px) 100vw, 1659px\" \/><\/a><\/p>\n<p>\u3053\u306e\u30b2\u30fc\u30e0\u306b\u306f3\u3064\u306e\u30ad\u30fc\u6a5f\u80fd\u3057\u304b\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<p>\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000\u3000<\/p>\n<table>\n<thead>\n<tr>\n<th>\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\u30ad\u30fc\u3000<\/th>\n<th>\u30a2\u30af\u30b7\u30e7\u30f3<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><strong>\u5de6\u77e2\u5370<\/strong> \u307e\u305f\u306f <strong>A<\/strong><\/td>\n<td>\u5de6\u65b9\u5411\u306b\u79fb\u52d5\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u53f3\u77e2\u5370<\/strong> \u307e\u305f\u306f <strong>D<\/strong><\/td>\n<td>\u53f3\u65b9\u5411\u306b\u79fb\u52d5\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td><strong>\u30b9\u30da\u30fc\u30b9\u30d0\u30fc<\/strong><\/td>\n<td>\u52d5\u7269\u306b\u990c\u3092\u4e0e\u3048\u308b\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2><strong>\u30d3\u30eb\u30c7\u30a3\u30f3\u30b0\u30fb\u30d6\u30ed\u30c3\u30af\uff1a Unity\u3001Node.js\u3001WebSocket\u3001\u304a\u3088\u3073GridDB<\/strong><\/h2>\n<p>\u30b7\u30fc\u30e0\u30ec\u30b9\u306a\u30b2\u30fc\u30e0\u30d7\u30ec\u30a4\u3001\u7279\u306b\u30de\u30eb\u30c1\u30d7\u30ec\u30a4\u30e4\u30fc\u30b7\u30ca\u30ea\u30aa\u3084\u4e00\u8cab\u3057\u305f\u540c\u671f\u3092\u5fc5\u8981\u3068\u3059\u308b\u30b2\u30fc\u30e0\u3067\u306f\u3001\u3059\u3079\u3066\u306e\u30a2\u30af\u30b7\u30e7\u30f3\u3001\u6c7a\u5b9a\u3001\u30b2\u30fc\u30e0\u30b9\u30c6\u30fc\u30c8\u3092\u6b63\u78ba\u304b\u3064\u8fc5\u901f\u306b\u4fdd\u5b58\u3059\u308b\u3053\u3068\u304c\u91cd\u8981\u3067\u3059\u3002\u79c1\u305f\u3061\u306f <strong>Unity<\/strong> \u30b2\u30fc\u30e0\u30a8\u30f3\u30b8\u30f3\u3068\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b9\u30bf\u30c3\u30af <strong>Node.js<\/strong> \u3068 <strong>GridDB<\/strong> \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u4f7f\u7528\u3057\u3066\u30b2\u30fc\u30e0\u3092\u69cb\u7bc9\u3057\u307e\u3059\u3002\u305d\u308c\u305e\u308c\u306e\u91cd\u8981\u6027\u3092\u691c\u8a3c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<h3><a href=\"https:\/\/unity.com\/\"><strong>Unity<\/strong><\/a><\/h3>\n<p>Unity \u306f 2D \u30b9\u30d7\u30e9\u30a4\u30c8\u3084 3D \u30ef\u30fc\u30eb\u30c9\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306e\u6c4e\u7528\u30a8\u30f3\u30b8\u30f3\u3092\u5099\u3048\u305f\u30c8\u30c3\u30d7\u30af\u30e9\u30b9\u306e\u30b2\u30fc\u30e0\u958b\u767a\u30d7\u30e9\u30c3\u30c8\u30d5\u30a9\u30fc\u30e0\u3067\u3059\u3002\u3053\u306e\u30d7\u30e9\u30c3\u30c8\u30d5\u30a9\u30fc\u30e0\u306f\u3001\u30e6\u30fc\u30b6\u30fc\u30d5\u30ec\u30f3\u30c9\u30ea\u30fc\u306a\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u8c4a\u5bcc\u306a\u30a2\u30bb\u30c3\u30c8\u3001\u5354\u529b\u7684\u306a\u30b3\u30df\u30e5\u30cb\u30c6\u30a3\u3092\u6301\u3063\u3066\u304a\u308a\u3001\u30e2\u30d0\u30a4\u30eb\u30c7\u30d0\u30a4\u30b9\u3001\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u3001VR \u30d8\u30c3\u30c9\u30bb\u30c3\u30c8\u5411\u3051\u306e\u6ca1\u5165\u578b\u30b2\u30fc\u30e0\u4f53\u9a13\u306e\u4f5c\u6210\u3092\u652f\u63f4\u3057\u307e\u3059\u3002<\/p>\n<h3><a href=\"https:\/\/nodejs.org\/en\/download\"><strong>Node.js<\/strong><\/a><\/h3>\n<p>Node.js \u306f\u3001\u958b\u767a\u8005\u304c JavaScript \u3092\u4f7f\u7528\u3057\u3066\u52b9\u7387\u7684\u3067\u30b9\u30b1\u30fc\u30e9\u30d6\u30eb\u306a\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d3\u30b9\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u3092\u53ef\u80fd\u306b\u3057\u307e\u3059\u3002\u305d\u306e\u30a4\u30d9\u30f3\u30c8\u99c6\u52d5\u578b\u3001\u30ce\u30f3\u30d6\u30ed\u30c3\u30ad\u30f3\u30b0 I\/O \u30e2\u30c7\u30eb\u306f\u3001\u591a\u6570\u306e\u540c\u6642\u63a5\u7d9a\u3092\u51e6\u7406\u3059\u308b\u306e\u306b\u7406\u60f3\u7684\u3067\u3001\u5927\u898f\u6a21\u306a\u30e6\u30fc\u30b6\u30fc\u30d9\u30fc\u30b9\u3092\u6301\u3064\u30b2\u30fc\u30e0\u306b\u6700\u9069\u3067\u3059\u3002Unity \u30b2\u30fc\u30e0\u3068 GridDB \u306a\u3069\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u63a5\u7d9a\u3059\u308b\u30d6\u30ea\u30c3\u30b8\u3068\u3057\u3066\u6a5f\u80fd\u3057\u307e\u3059\u3002<\/p>\n<h3><a href=\"https:\/\/www.griddb.net\/\"><strong>GridDB<\/strong><\/a><\/h3>\n<p>\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u30b2\u30fc\u30e0\u3067\u306f\u3001\u52b9\u7387\u7684\u306a\u30c7\u30fc\u30bf\u30b9\u30c8\u30ec\u30fc\u30b8\u304c\u91cd\u8981\u3067\u3059\u3002GridDB \u306f\u3001\u3053\u306e\u76ee\u7684\u306e\u305f\u3081\u306b\u8a2d\u8a08\u3055\u308c\u305f\u3001\u62e1\u5f35\u6027\u3001\u53ef\u7528\u6027\u3001\u8010\u4e45\u6027\u306b\u512a\u308c\u305f\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u30b7\u30b9\u30c6\u30e0\u3067\u3059\u3002GridDB \u306e\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306f\u3001IoT \u306e\u30e6\u30fc\u30b9\u30b1\u30fc\u30b9\u306b\u5408\u308f\u305b\u3066\u8a2d\u8a08\u3055\u308c\u3066\u304a\u308a\u3001\u30b2\u30fc\u30e0\u306b\u3082\u9069\u3057\u3066\u3044\u307e\u3059\u3002GridDB \u306f\u3059\u3079\u3066\u306e\u30d7\u30ec\u30a4\u30e4\u30fc\u306e\u30a2\u30af\u30b7\u30e7\u30f3\u3092\u78ba\u5b9f\u306b\u30ad\u30e3\u30d7\u30c1\u30e3\u3057\u3001\u4f4e\u30ec\u30a4\u30c6\u30f3\u30b7\u30fc\u3067\u4fdd\u5b58\u3057\u307e\u3059\u3002<\/p>\n<h3><strong>WebSocket: Unity \u3068 Node.js \u3092\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u306b\u7e4b\u3050<\/strong><\/h3>\n<p>\u4e00\u6319\u624b\u4e00\u6295\u8db3\u304c\u91cd\u8981\u306a\u30da\u30fc\u30b9\u306e\u901f\u3044\u30b2\u30fc\u30e0\u306e\u4e16\u754c\u3067\u306f\u3001\u5f93\u6765\u306e\u30ea\u30af\u30a8\u30b9\u30c8-\u30ec\u30b9\u30dd\u30f3\u30b9\u578b\u4ee5\u4e0a\u306e\u901a\u4fe1\u30e2\u30c7\u30eb\u304c\u5fc5\u8981\u306b\u306a\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002\u305d\u3053\u3067 <a href=\"https:\/\/en.wikipedia.org\/wiki\/WebSocket\">WebSocket<\/a> \u306e\u5a01\u529b\u304c\u767a\u63ee\u3055\u308c\u307e\u3059\u3002<\/p>\n<ul>\n<li><strong>WebSocket \u306e\u57fa\u672c:<\/strong> WebSocket \u306f\u3001\u5f93\u6765\u306e HTTP \u30e2\u30c7\u30eb\u3068\u306f\u7570\u306a\u308b\u30a2\u30d7\u30ed\u30fc\u30c1\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002\u30ea\u30af\u30a8\u30b9\u30c8\u3092\u9001\u4fe1\u3057\u305f\u5f8c\u306b\u5fdc\u7b54\u3092\u5f85\u3064\u306e\u3067\u306f\u306a\u304f\u3001WebSocket \u306f 1 \u3064\u306e\u9577\u671f\u7684\u306a\u63a5\u7d9a\u3092\u4ecb\u3057\u3066\u5168\u4e8c\u91cd\u901a\u4fe1\u30c1\u30e3\u30cd\u30eb\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u5e38\u306b\u63a5\u7d9a\u3092\u5207\u65ad\u3059\u308b\u3053\u3068\u306a\u304f\u30c7\u30fc\u30bf\u306e\u540c\u6642\u9001\u53d7\u4fe1\u304c\u53ef\u80fd\u306b\u306a\u308a\u307e\u3059\u3002\u63a5\u7d9a\u306f HTTP \u63a5\u7d9a\u30cf\u30f3\u30c9\u30b7\u30a7\u30a4\u30af\u306b\u3088\u3063\u3066\u78ba\u7acb\u3055\u308c\u3001\u305d\u306e\u5f8c WebSocket \u3067\u4f7f\u7528\u3059\u308b\u305f\u3081\u306b\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u4e00\u8cab\u3057\u305f\u4e2d\u65ad\u306e\u306a\u3044\u63a5\u7d9a\u306f\u3001\u30c7\u30fc\u30bf\u8ee2\u9001\u304c\u77ac\u6642\u306b\u884c\u308f\u308c\u308b\u305f\u3081\u3001\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u306e\u30d5\u30a3\u30fc\u30c9\u30d0\u30c3\u30af\u3092\u5fc5\u8981\u3068\u3059\u308b\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u6700\u9069\u3067\u3059\u3002<\/p>\n<\/li>\n<li><strong>\u30b2\u30fc\u30e0\u306b\u304a\u3051\u308b\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u901a\u4fe1\u306e\u91cd\u8981\u6027:<\/strong> \u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d7\u30ec\u30a4\u30e4\u30fc\u306f\u81ea\u5206\u306e\u52d5\u304d\u306b\u5bfe\u3059\u308b\u7d20\u65e9\u3044\u30ec\u30b9\u30dd\u30f3\u30b9\u3092\u6c42\u3081\u307e\u3059\u3002\u30de\u30eb\u30c1\u30d7\u30ec\u30a4\u30e4\u30fc\u30b7\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30b3\u30df\u30e5\u30cb\u30b1\u30fc\u30b7\u30e7\u30f3\u306b\u3088\u3063\u3066\u30c1\u30fc\u30e0\u306e\u52dd\u6557\u304c\u6c7a\u307e\u3063\u305f\u308a\u3001\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u30b9\u30c8\u30e9\u30c6\u30b8\u30fc\u30b2\u30fc\u30e0\u3067\u306f\u3001\u9045\u6ede\u306a\u304f\u610f\u601d\u6c7a\u5b9a\u3092\u884c\u3044\u3001\u5b9f\u884c\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u3088\u3046\u306a\u671f\u5f85\u306b\u5fdc\u3048\u308b\u305f\u3081\u3001\u30b2\u30fc\u30e0\u958b\u767a\u8005\u306f WebSocket \u3092\u5229\u7528\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u308c\u3089\u306e\u30c4\u30fc\u30eb\u306f\u3001\u9045\u5ef6\u3092\u6700\u5c0f\u9650\u306b\u6291\u3048\u3001\u30d7\u30ec\u30a4\u30e4\u30fc\u306e\u30a2\u30af\u30b7\u30e7\u30f3\u304c\u3055\u307e\u3056\u307e\u306a\u30d7\u30e9\u30c3\u30c8\u30d5\u30a9\u30fc\u30e0\u3084\u30c7\u30d0\u30a4\u30b9\u9593\u3067\u540c\u671f\u3055\u308c\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002WebSocket \u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3001\u30b2\u30fc\u30de\u30fc\u306f\u30b7\u30fc\u30e0\u30ec\u30b9\u3067\u9b45\u529b\u7684\u306a\u4f53\u9a13\u3092\u697d\u3057\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<\/li>\n<\/ul>\n<h2>\u30b7\u30b9\u30c6\u30e0\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3<\/h2>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306f\u3001\u5148\u306b\u8aac\u660e\u3057\u305f\u3088\u3046\u306b3\u3064\u306e\u4e3b\u8981\u306a\u30b9\u30bf\u30c3\u30af Unity\u3001Node.js\u3001GridDB \u3067\u69cb\u6210\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u30b7\u30b9\u30c6\u30e0\u56f3\u306f\u975e\u5e38\u306b\u30b7\u30f3\u30d7\u30eb\u3067\u3001Node.js \u3068 GridDB \u3092\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066\u4f7f\u7528\u3057\u3001Unity \u30b2\u30fc\u30e0\u3068\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u9593\u306e\u901a\u4fe1\u306f WebSocket \u6280\u8853\u3092\u901a\u3058\u3066\u884c\u3044\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\" alt=\"\" width=\"1605\" height=\"903\" class=\"aligncenter size-full wp-image-29820\" srcset=\"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png 1605w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-300x169.png 300w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-768x432.png 768w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-1024x576.png 1024w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-1536x864.png 1536w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-150x85.png 150w, \/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb-600x338.png 600w\" sizes=\"(max-width: 1605px) 100vw, 1605px\" \/><\/a><\/p>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001\u4e3b\u306b 2 \u3064\u306e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u8a00\u8a9e\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002\u30b2\u30fc\u30e0\u958b\u767a\u7528\u306e C# \u3068 Node.js \u4e0a\u3067\u52d5\u4f5c\u3059\u308b JavaScript \u3067\u3059\u3002<\/p>\n<h2>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h2>\n<h3>Node.js \u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/h3>\n<p>\u3053\u306e\u30d6\u30ed\u30b0\u8a18\u4e8b\u3067\u53d6\u308a\u4e0a\u3052\u308b\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001Node.js LTS \u30d0\u30fc\u30b8\u30e7\u30f3 18 \u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002Node.js \u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u308b\u304b\u78ba\u8a8d\u3059\u308b\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>node --version<\/code><\/pre>\n<\/div>\n<p>Node.js \u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u306a\u3044\u5834\u5408\u3084\u53e4\u3044\u30d0\u30fc\u30b8\u30e7\u30f3\u306e\u5834\u5408\u306f\u3001\u516c\u5f0f\u30b5\u30a4\u30c8 <a href=\"https:\/\/nodejs.org\/en\/download\">nodejs.org<\/a> \u304b\u3089 Node.js LTS \u3092\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u307e\u305f\u306f\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u3053\u3068\u3092\u63a8\u5968\u3057\u307e\u3059\u3002<\/p>\n<h3>GridDB \u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/h3>\n<p>GridDB \u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u306f\u7c21\u5358\u3067\u3059\u3002Ubuntu \u3078\u306e\u65b0\u898f\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f<a href=\"https:\/\/docs.griddb.net\/latest\/gettingstarted\/using-apt\/\">\u3053\u3061\u3089<\/a>\u3001Windows \u3078\u306eWSL(Windows Subsystem Linux) \u7d4c\u7531\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f<a href=\"https:\/\/docs.griddb.net\/installation\/misc.html\">\u3053\u3061\u3089<\/a>\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u65e2\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u3066\u3044\u308b\u5834\u5408\u306f\u3001\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3067 griddb \u30b5\u30fc\u30d3\u30b9\u304c\u5b9f\u884c\u3055\u308c\u3066\u3044\u308b\u304b\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>sudo systemctl status gridstore<\/code><\/pre>\n<\/div>\n<p>\u3053\u306e Ubuntu OS \u306e\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u51fa\u529b\u306f\u3001griddb\u30b5\u30fc\u30d3\u30b9\u304c\u5b9f\u884c\u3055\u308c\u3066\u3044\u308b\u3053\u3068\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-sh\">\u25cf gridstore.service - GridDB database server.\n     Loaded: loaded (\/lib\/systemd\/system\/gridstore.service; enabled; vendor preset: enabled)\n     Active: active (running) since Tue 2023-07-04 04:47:12 +07; 9h ago\n   Main PID: 575 (gsserver)\n      Tasks: 34 (limit: 7017)\n     Memory: 144.7M\n     CGroup: \/system.slice\/gridstore.service\n             \u2514\u2500575 \/usr\/bin\/gsserver --conf \/var\/lib\/gridstore\/conf\n\nJul 04 04:47:08 GenAI systemd[1]: Starting GridDB database server....\nJul 04 04:47:09 GenAI gridstore[381]: Starting gridstore service:\nJul 04 04:47:12 GenAI gridstore[526]: ..\nJul 04 04:47:12 GenAI gridstore[526]: Started node.\nJul 04 04:47:12 GenAI gridstore[381]: [ OK ]\nJul 04 04:47:12 GenAI systemd[1]: Started GridDB database server..<\/code><\/pre>\n<\/div>\n<h3>Unity \u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7<\/h3>\n<p>\u3053\u306e\u8a18\u4e8b\u3067\u306f\u3001Windows OS \u3092\u4f7f\u7528\u3057\u3066 Unity \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<blockquote><p>\n  \u30b2\u30fc\u30e0\u958b\u767a\u3092\u30bc\u30ed\u304b\u3089\u884c\u3046\u308f\u3051\u3067\u306f\u306a\u3044\u306e\u3067\u3001\u3053\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f\u4efb\u610f\u3067\u3059\u3002Unity Editor \u306b\u98db\u3073\u8fbc\u307f\u3001\u5b9f\u6a5f\u958b\u767a\u3092\u8a66\u3057\u3066\u307f\u305f\u3044\u65b9\u306f\u3001\u3053\u306e\u307e\u307e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3092\u7d9a\u3051\u3066\u304f\u3060\u3055\u3044\u3002\n<\/p><\/blockquote>\n<h4>Unity Editor<\/h4>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f Unity 2022 LTS \u3092\u4f7f\u7528\u3057\u307e\u3059\u3002\u3053\u308c\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u306b\u306f\u3001\u307e\u305a Unity Hub \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306f\u3053\u3061\u3089 <a href=\"https:\/\/public-cdn.cloud.unity3d.com\/hub\/prod\/UnityHubSetup.exe\">Unity Hub<\/a> \u304b\u3089\u884c\u3063\u3066\u304f\u3060\u3055\u3044\u3002Unity Hub \u304b\u3089\u76f4\u63a5 <strong>Unity 2022.3.6f1<\/strong> \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u3053\u3068\u3067\u3001\u3088\u308a\u826f\u3044\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u7ba1\u7406\u304c\u53ef\u80fd\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p><strong>Unity Hub\u3068\u306f?<\/strong><br \/>\nUnity Hub \u306f Unity Editor \u306e\u8907\u6570\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u7ba1\u7406\u3001\u65b0\u898f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4f5c\u6210\u3001\u4f5c\u696d\u3078\u306e\u30a2\u30af\u30bb\u30b9\u306b\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-hub.png\"><img decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-hub.png\" alt=\"\" width=\"1330\" height=\"748\" class=\"aligncenter size-full wp-image-29826\" srcset=\"\/wp-content\/uploads\/2023\/09\/unity-hub.png 1330w, \/wp-content\/uploads\/2023\/09\/unity-hub-300x169.png 300w, \/wp-content\/uploads\/2023\/09\/unity-hub-1024x576.png 1024w, \/wp-content\/uploads\/2023\/09\/unity-hub-768x432.png 768w, \/wp-content\/uploads\/2023\/09\/unity-hub-150x85.png 150w, \/wp-content\/uploads\/2023\/09\/unity-hub-600x337.png 600w\" sizes=\"(max-width: 1330px) 100vw, 1330px\" \/><\/a><\/p>\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u5f8c\u3001\u30d5\u30a9\u30eb\u30c0\u5185\u306e\u30b2\u30fc\u30e0\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30bd\u30fc\u30b9\u30b3\u30fc\u30c9\u3068\u30a2\u30bb\u30c3\u30c8\u3092\u30a4\u30f3\u30dd\u30fc\u30c8\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-sh\"> appgameunity.feed.the.animals\n<\/code><\/pre>\n<\/div>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-hub-open.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-hub-open.png\" alt=\"\" width=\"1427\" height=\"803\" class=\"aligncenter size-full wp-image-29819\" srcset=\"\/wp-content\/uploads\/2023\/09\/unity-hub-open.png 1427w, \/wp-content\/uploads\/2023\/09\/unity-hub-open-300x169.png 300w, \/wp-content\/uploads\/2023\/09\/unity-hub-open-1024x576.png 1024w, \/wp-content\/uploads\/2023\/09\/unity-hub-open-768x432.png 768w, \/wp-content\/uploads\/2023\/09\/unity-hub-open-150x85.png 150w, \/wp-content\/uploads\/2023\/09\/unity-hub-open-600x338.png 600w\" sizes=\"(max-width: 1427px) 100vw, 1427px\" \/><\/a><\/p>\n<p>\u305d\u306e\u5f8c\u3001Unity Editor \u3067\u30b2\u30fc\u30e0\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30bd\u30fc\u30b9\u3068\u30a2\u30bb\u30c3\u30c8\u3092\u958b\u304f\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-editor.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-editor.png\" alt=\"\" width=\"1921\" height=\"1080\" class=\"aligncenter size-full wp-image-29825\" srcset=\"\/wp-content\/uploads\/2023\/09\/unity-editor.png 1921w, \/wp-content\/uploads\/2023\/09\/unity-editor-300x169.png 300w, \/wp-content\/uploads\/2023\/09\/unity-editor-1024x576.png 1024w, \/wp-content\/uploads\/2023\/09\/unity-editor-768x432.png 768w, \/wp-content\/uploads\/2023\/09\/unity-editor-1536x864.png 1536w, \/wp-content\/uploads\/2023\/09\/unity-editor-150x85.png 150w, \/wp-content\/uploads\/2023\/09\/unity-editor-600x337.png 600w\" sizes=\"(max-width: 1921px) 100vw, 1921px\" \/><\/a><\/p>\n<h2>\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u30b3\u30fc\u30c9<\/h2>\n<h3>Node.js \u3068 WebSocket \u306e\u7d71\u5408<\/h3>\n<p>Node.js \u3068 WebSocket \u306e\u7d71\u5408\u306f\u3001<a href=\"https:\/\/github.com\/websockets\/ws\"><code>ws<\/code><\/a> npm \u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u4f7f\u3048\u3070\u7c21\u5358\u3067\u3059\u3002\u3053\u306e npm \u30d1\u30c3\u30b1\u30fc\u30b8\u306f\u4f7f\u3044\u3084\u3059\u304f\u3001\u9ad8\u901f\u3067\u3001\u5fb9\u5e95\u7684\u306b\u30c6\u30b9\u30c8\u3055\u308c\u305f WebSocket \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3068\u30b5\u30fc\u30d0\u30fc\u306e\u5b9f\u88c5\u3067\u3059\u3002\u305f\u3060\u3057 <code>ws<\/code> \u306f\u30b5\u30fc\u30d0\u4e0a\u3067\u306e\u307f\u5229\u7528\u3057\u307e\u3059\u3002\u30d6\u30e9\u30a6\u30b6\u306b\u306f\u65e2\u306b WebSocket \u306e\u5b9f\u88c5\u304c\u3042\u308b\u305f\u3081\u3001\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\u3067\u306f\u5229\u7528\u3057\u307e\u305b\u3093\u3002<\/p>\n<h4>Node.js HTTP \u30b5\u30fc\u30d0\u30fc<\/h4>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3067\u306f\u3001Node.js \u3068\u69d8\u3005\u306a Node.js \u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u4f7f\u7528\u3057\u3066\u3001\u57fa\u672c\u7684\u306a HTTP \u3068 WebSocket \u30b5\u30fc\u30d0\u30fc\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3057\u307e\u3059\u3002\u307e\u305f\u3001\u3044\u304f\u3064\u304b\u306eHTTP\u30eb\u30fc\u30c8\u3092\u516c\u958b\u3057\u3001\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306b\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u30b5\u30fc\u30d3\u30b9\u306b\u63a5\u7d9a\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">\/\/ index.js\nimport express from 'express';\nimport http from 'http';\nimport cors from 'cors';\nimport path from 'path';\nimport 'dotenv\/config';\nimport url from 'url';\n\nimport setupWebSocket from '.\/websocket.js';\nimport { __dirname } from '.\/libs\/dirname.js';\nimport { getAllData } from \".\/griddbservice.js\";\nimport { createRequire } from 'module'; \n\nconst require = createRequire(import.meta.url); \nconst WebSocket = require('ws');\n\nconst app = express();\n\nconst parsedUrl = url.parse(process.env.GAME_SERVER_URL);\nconst hostname = parsedUrl.hostname;\nconst port = parsedUrl.port || 8080; \n\nconst server = http.createServer(app);\n\nconst wss = new WebSocket.Server({ server });\n\nsetupWebSocket(wss);\n\nconst publicPath = path.resolve(`${__dirname}`, '.\/public');\n\napp.use(express.static(publicPath));\napp.use(cors());\n\napp.get('\/', (req, res) => {\n    res.send('Unity Game Server!');\n});\n\n\napp.get('\/api\/gamedata', async (req, res) => {\n    try {\n        const data = await getAllData();\n        res.json(data); \n    } catch (err) {\n        console.error(err);\n        res.status(500).send('Internal Server Error');\n    }\n});\n\nserver.listen(port, () => {\n    console.log(`HTTP and WebSocket server running on http:\/\/${hostname}:${port}`);\n});\n<\/code><\/pre>\n<\/div>\n<p>HTTP \u30b5\u30fc\u30d0\u30fc\u3092\u52d5\u4f5c\u3059\u308b\u524d\u306b <code>env<\/code> \u30d5\u30a1\u30a4\u30eb\u3092\u8aad\u307f\u8fbc\u3093\u3067 <code>GAME_SERVER_URL<\/code> \u74b0\u5883\u5909\u6570\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">const parsedUrl = url.parse(process.env.GAME_SERVER_URL);\nconst hostname = parsedUrl.hostname;\nconst port = parsedUrl.port || 8080;<\/code><\/pre>\n<\/div>\n<p>\u4e0a\u8a18\u306e\u30b3\u30fc\u30c9\u306f <code>GAME_SERVER_URL<\/code> \u3092\u89e3\u6790\u3057\u3001<code>hostname<\/code> \u3068 <code>port<\/code> \u3092\u62bd\u51fa\u3057\u307e\u3059\u3002\u3082\u3057 <code>env<\/code> \u30d5\u30a1\u30a4\u30eb\u3067\u30dd\u30fc\u30c8\u3092\u5b9a\u7fa9\u3057\u306a\u3051\u308c\u3070\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u3067 <code>8080<\/code> \u756a\u30dd\u30fc\u30c8\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h4>HTTP \u30eb\u30fc\u30c6\u30a3\u30f3\u30b0<\/h4>\n<p>HTTP\u3000\u30b5\u30fc\u30d0\u30fc\u306f\u30db\u30fc\u30e0\u30da\u30fc\u30b8\u3084\u5bfe\u5c40\u30c7\u30fc\u30bf\u30ea\u30b9\u30c8\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306e\u30eb\u30fc\u30c8\u3082\u516c\u958b\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<table>\n<thead>\n<tr>\n<th>HTTP\u30e1\u30bd\u30c3\u30c9<\/th>\n<th>\u30eb\u30fc\u30c8<\/th>\n<th>\u8aac\u660e \u3000\u3000\u3000\u3000<\/th>\n<th>\u30ec\u30b9\u30dd\u30f3\u30b9\u30fb\u30bf\u30a4\u30d7<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>GET<\/td>\n<td><code>\/<\/code><\/td>\n<td>\u30b7\u30f3\u30d7\u30eb\u306a\u30c6\u30ad\u30b9\u30c8\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u8fd4\u3057\u307e\u3059\u3002<\/td>\n<td>\u30c6\u30ad\u30b9\u30c8 &#8220;Unity\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\uff01&#8221;<\/td>\n<\/tr>\n<tr>\n<td>GET<\/td>\n<td><code>\/api\/gamedata<\/code><\/td>\n<td>\u30b5\u30fc\u30d3\u30b9\u304b\u3089\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002<\/td>\n<td>JSON \u307e\u305f\u306f 500 \u5185\u90e8\u30b5\u30fc\u30d0\u30fc\u30a8\u30e9\u30fc<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><strong>\u6ce8\u610f:<\/strong> \u3053\u306e\u8868\u306f HTTP \u30eb\u30fc\u30c8\u306e\u307f\u3092\u30ab\u30d0\u30fc\u3057\u3066\u304a\u308a\u3001WebSocket \u30eb\u30fc\u30c8\u306f\u542b\u307e\u308c\u3066\u3044\u307e\u305b\u3093\u3002<\/p>\n<h4>WebSocket \u30b5\u30fc\u30d0\u30fc<\/h4>\n<p>WebSocket \u30b5\u30fc\u30d0\u30fc\u306f HTTP \u30b5\u30fc\u30d0\u30fc\u306b\u30a2\u30bf\u30c3\u30c1\u3055\u308c\u3066\u3044\u308b\u306e\u3067\u3001HTTP \u30b5\u30fc\u30d0\u30fc\u304c\u5b9f\u884c\u3055\u308c\u308b\u3068\u3001WebSocket \u30b5\u30fc\u30d0\u30fc\u3082\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">const wss = new WebSocket.Server({ server });\n\nsetupWebSocket(wss);<\/code><\/pre>\n<\/div>\n<p><code>setupWebSocket()<\/code> \u306f\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u3068 Unity \u30b2\u30fc\u30e0\u306e\u63a5\u7d9a\u3092\u51e6\u7406\u3059\u308b\u30e1\u30a4\u30f3\u95a2\u6570\u3067\u3059\u3002\u30b3\u30fc\u30c9\u3092\u898b\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">\/\/ websocket.js\nimport { saveData, getAllData } from '.\/griddbservice.js';\n\nfunction setupWebSocket(wss) {\n    wss.on('connection', function connection(ws) {\n        ws.on('message', async (data) => {\n\n            let readableData;\n\n            \/\/ Check if the data is in JSON format\n            try {\n                readableData = JSON.parse(data.toString('utf8'));\n            } catch (e) {\n                console.log('Received data is not JSON. Ignoring...');\n                return;\n            }\n\n            \/\/ If data is of type \"save\", then save it\n            if (readableData.type === 'save') {\n                const playerposition = {\n                    x: readableData.PlayerX,\n                    y: readableData.PlayerY,\n                    z: readableData.PlayerZ\n                };\n                const numberofthrows = readableData.NumberOfMeatThrows;\n                const gameover = false;\n\n                await saveData({ playerposition, numberofthrows, gameover });\n                ws.send(JSON.stringify(readableData))\n            } else if (readableData.type === 'getAll') {\n                const allData = await getAllData();\n                ws.send(JSON.stringify(allData));\n            }\n\n            console.log('data received n %o', readableData);\n\n        });\n    });\n\n\n    wss.on('listening', () => {\n        console.log('WebSocket server is listening');\n    });\n};\n\nexport default setupWebSocket;<\/code><\/pre>\n<\/div>\n<p>\u63a5\u7d9a\u72b6\u614b\u306b\u306a\u308b\u3068 WebSocket \u306f Unity \u30b2\u30fc\u30e0\u304b\u3089\u306e\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u5f85\u3061\u53d7\u3051\u307e\u3059\u3002WebSocket \u306e\u6027\u8cea\u4e0a\u3001Unity \u30b2\u30fc\u30e0\uff08\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\uff09\u304b\u3089\u306e\u30c7\u30fc\u30bf\u306f\u5373\u5ea7\u306b\u53d7\u4fe1\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30b3\u30fc\u30c9\u3067\u306f JSON \u30c7\u30fc\u30bf\u306e\u307f\u3092\u53d7\u3051\u53d6\u308a\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">try {\n    readableData = JSON.parse(data.toString('utf8'));\n} catch (e) {\n    console.log('Received data is not JSON. Ignoring...');\nreturn;\n}<\/code><\/pre>\n<\/div>\n<p>Unity \u30b2\u30fc\u30e0\u304b\u3089\u306e JSON \u30c7\u30fc\u30bf\u306b\u306f\u3001\u6700\u5f8c\u306e\u30d7\u30ec\u30fc\u30e4\u30fc\u306e\u52d5\u304d\u3068\u8089\u6295\u3052\u306e\u6570\u304c\u542b\u307e\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">const playerposition = {\n        x: readableData.PlayerX,\n        y: readableData.PlayerY,\n        z: readableData.PlayerZ\n};\nconst numberofthrows = readableData.NumberOfMeatThrows;<\/code><\/pre>\n<\/div>\n<p>\u3053\u306e\u30c7\u30fc\u30bf\u306f\u5f8c\u306b GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002<\/p>\n<h3>WebSocket \u30a4\u30d9\u30f3\u30c8<\/h3>\n<table>\n<thead>\n<tr>\n<th>\u30a4\u30d9\u30f3\u30c8<\/th>\n<th>\u30e1\u30c3\u30bb\u30fc\u30b8\u30bf\u30a4\u30d7<\/th>\n<th>\u8aac\u660e<\/th>\n<th>\u30ec\u30b9\u30dd\u30f3\u30b9\/\u30a2\u30af\u30b7\u30e7\u30f3<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>on message<\/td>\n<td><code>save<\/code><\/td>\n<td>\u30d7\u30ec\u30a4\u30e4\u30fc\u306e\u4f4d\u7f6e\u3068\u30df\u30fc\u30c8\u6570\u3092\u4fdd\u5b58\u3057\u307e\u3059\u3002<\/td>\n<td>\u53d7\u4fe1\u3057\u305fJSON\u30c7\u30fc\u30bf\u3092\u30a8\u30b3\u30fc\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>on message<\/td>\n<td><code>getAll<\/code><\/td>\n<td>\u4fdd\u5b58\u3055\u308c\u305f\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u5168\u3066\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u9001\u4fe1\u3057\u307e\u3059\u3002 (\u5c06\u6765\u5229\u7528)<\/td>\n<td>\u3059\u3079\u3066\u306e\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092 JSON \u3068\u3057\u3066\u9001\u4fe1\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<tr>\n<td>on listening<\/td>\n<td>N\/A<\/td>\n<td>WebSocket \u30b5\u30fc\u30d0\u30fc\u304c\u7740\u4fe1\u63a5\u7d9a\u3092\u30ea\u30b9\u30cb\u30f3\u30b0\u3057\u3066\u3044\u308b\u3053\u3068\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/td>\n<td>\u30b3\u30f3\u30bd\u30fc\u30eb\u306b\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u8a18\u9332\u3057\u307e\u3059\u3002<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><code>setupWebSocket<\/code> \u95a2\u6570\u306f WebSocket \u30b5\u30fc\u30d0\u30fc\u3092\u30d5\u30c3\u30af\u3057\u3001\u69d8\u3005\u306a\u30bf\u30a4\u30d7\u306e\u30a4\u30d9\u30f3\u30c8\u3092\u30ea\u30c3\u30b9\u30f3\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li><strong><code>connection<\/code><\/strong>\uff1a \u65b0\u3057\u3044 WebSocket \u63a5\u7d9a\u304c\u78ba\u7acb\u3055\u308c\u308b\u305f\u3073\u306b\u3001\u4ee5\u4e0b\u306e\u30e1\u30c3\u30bb\u30fc\u30b8\u30cf\u30f3\u30c9\u30e9\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3057\u307e\u3059\uff1a <\/li>\n<li><strong><code>message<\/code><\/strong>\uff1a\u53d7\u4fe1\u30e1\u30c3\u30bb\u30fc\u30b8\u3092\u30ea\u30b9\u30f3\u3059\u308b\u3002\u30e1\u30c3\u30bb\u30fc\u30b8\u306e<code>type<\/code>\u30d5\u30a3\u30fc\u30eb\u30c9(<code>save<\/code>\u307e\u305f\u306f<code>getAll<\/code>)\u306b\u5fdc\u3058\u3066\u3001\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b\u304b\u3001\u4fdd\u5b58\u3055\u308c\u305f\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u3059\u3079\u3066\u53d6\u5f97\u3057\u3066\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u9001\u308a\u8fd4\u3057\u307e\u3059\u3002<\/li>\n<li><strong><code>listening<\/code><\/strong>\uff1a WebSocket \u30b5\u30fc\u30d0\u30fc\u304c\u30a2\u30af\u30c6\u30a3\u30d6\u306b\u63a5\u7d9a\u3092\u30ea\u30c3\u30b9\u30f3\u3057\u3066\u3044\u308b\u3053\u3068\u3092\u8a18\u9332\u3057\u307e\u3059\u3002<\/li>\n<\/ul>\n<h3>\u30b2\u30fc\u30e0\u9032\u884c\u306e\u4fdd\u5b58<\/h3>\n<p>\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092 GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3059\u308b\u306e\u306f\u975e\u5e38\u306b\u7c21\u5358\u3067\u3059\u3002WebSocket \u30b5\u30fc\u30d0\u306e\u30b3\u30fc\u30c9\u3067\u306f\u3001<code>saveData()<\/code> \u3068 <code>getAllData()<\/code> \u306e 2 \u3064\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>import { saveData, getAllData } from '.\/griddbservice.js';<\/code><\/pre>\n<\/div>\n<p><code>griddbservice.js<\/code> \u306f\u3001\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u64cd\u4f5c\u306b\u95a2\u9023\u3059\u308b\u30ed\u30b8\u30c3\u30af\u3092\u51e6\u7406\u3059\u308b GridDB \u30b5\u30fc\u30d3\u30b9\u30d5\u30a1\u30a4\u30eb\u3067\u3059\u3002\u3053\u308c\u306b\u3088\u308a\u3001\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u30ed\u30b8\u30c3\u30af\u306e\u66f4\u65b0\u304c\u5bb9\u6613\u306b\u306a\u308a\u3001GridDB \u306b\u3088\u308b CRUD \u64cd\u4f5c\u3092\u3088\u308a\u30e2\u30b8\u30e5\u30fc\u30eb\u5316\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">\/\/ griddbservice.js\nimport * as GridDB from '.\/libs\/griddb.cjs';\nimport { generateRandomID } from '.\/libs\/rangen.js';\n\nconst { collectionDb, store, conInfo, containerName } = await GridDB.initGridDbTS();\n\nexport async function saveData({ playerposition, numberofthrows, gameover }) {\n    const id = generateRandomID();\n\n    \/\/ Serialize player position to a JSON string (if needed)\n    const playerpositionStr = JSON.stringify(playerposition);\n    const numberofthrowsStr = String(numberofthrows);\n    const gameoverStr = String(gameover);\n\n    \/\/ Now you can safely insert them into the database as strings\n    const playerState = [parseInt(id), playerpositionStr, numberofthrowsStr, gameoverStr];\n    const saveStatus = await GridDB.insert(playerState, collectionDb);\n    return saveStatus;\n}\n\nexport async function getAllData() {\n    return await GridDB.queryAll(conInfo, store);\n}<\/code><\/pre>\n<\/div>\n<p>\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u306f <code>saveData()<\/code> \u95a2\u6570\u3092\u7528\u3044\u3066\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u95a2\u6570\u306e\u30b7\u30b0\u30cd\u30c1\u30e3\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>async function saveData({ playerposition, numberofthrows, gameover })<\/code><\/pre>\n<\/div>\n<p><code>saveData()<\/code> \u95a2\u6570\u306f 3 \u3064\u306e\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf <code>playerposition<\/code>\u3001<code>numberofthrows<\/code>\u3001<code>gameover<\/code> \u3092 GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3057\u307e\u3059\u3002<\/p>\n<p><code>getAllData()<\/code> \u95a2\u6570\u306f GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3055\u308c\u3066\u3044\u308b\u5168\u3066\u306e\u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u8fd4\u3057\u307e\u3059\u3002HTTP \u30b5\u30fc\u30d0\u30fc\u306e URL \u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u3067\u3001\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u3053\u306e\u30c7\u30fc\u30bf\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code>http:\/\/localhost:8080\/api\/gamedata<\/code><\/pre>\n<\/div>\n<p><code>env<\/code> \u30d5\u30a1\u30a4\u30eb\u3067 HTTP URL \u30b5\u30fc\u30d0\u30fc\u3092\u5909\u66f4\u3059\u308b\u3068\u3001\u4e0a\u8a18\u306e URL \u3082\u5909\u66f4\u3055\u308c\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>\u30b2\u30fc\u30e0\u306e\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3<\/h3>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/game-architecture.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/game-architecture.png\" alt=\"\" width=\"1869\" height=\"1203\" class=\"aligncenter size-full wp-image-29821\" srcset=\"\/wp-content\/uploads\/2023\/09\/game-architecture.png 1869w, \/wp-content\/uploads\/2023\/09\/game-architecture-300x193.png 300w, \/wp-content\/uploads\/2023\/09\/game-architecture-1024x659.png 1024w, \/wp-content\/uploads\/2023\/09\/game-architecture-768x494.png 768w, \/wp-content\/uploads\/2023\/09\/game-architecture-1536x989.png 1536w, \/wp-content\/uploads\/2023\/09\/game-architecture-600x386.png 600w\" sizes=\"(max-width: 1869px) 100vw, 1869px\" \/><\/a><\/p>\n<p><strong>Feed the Animals<\/strong> \u30b2\u30fc\u30e0\u306e\u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u306f\u3001\u4e00\u822c\u7684\u306b\u3053\u306e\u56f3\u306e\u3088\u3046\u306b\u8a18\u8ff0\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3053\u306e\u56f3\u3067\u306f <strong>WebSocket (WsClient)<\/strong> \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u304c\u3055\u307e\u3056\u307e\u306a\u30c7\u30fc\u30bf\u3092\u9001\u4fe1\u3057\u3066\u3044\u307e\u3059\uff1a<\/p>\n<ul>\n<li><strong>PlayerX\u3001PlayerY\u3001PlayerZ<\/strong>\uff1a PlayerX\u3001PlayerY\u3001PlayerZ**\uff1a\u30d7\u30ec\u30a4\u30e4\u30fc\u306e\u4f4d\u7f6e\u3067\u3001\u304a\u305d\u3089\u304f PlayerController \u304b\u3089\u53ce\u96c6\u3055\u308c\u305f\u3082\u306e\u3067\u3059\u3002\n<\/li>\n<li>\n<p><strong>NumberOfMeatThrows<\/strong>\uff1aGameManager \u304b\u3089\u76f4\u63a5\u8aad\u307f\u8fbc\u307e\u308c\u307e\u3059\u3002<\/p>\n<\/li>\n<\/ul>\n<p>\u3053\u308c\u3089\u306e\u30c7\u30fc\u30bf\u30dd\u30a4\u30f3\u30c8\u306f JSON \u3068\u3057\u3066\u30b7\u30ea\u30a2\u30e9\u30a4\u30ba\u3055\u308c\u3001WebSocket \u63a5\u7d9a\u3092\u4ecb\u3057\u3066\u9001\u4fe1\u3055\u308c\u307e\u3059\u3002<\/p>\n<h3>Unity \u3068 WebSocket \u306e\u51fa\u4f1a\u3044<\/h3>\n<h4>WebSocket NuGet<\/h4>\n<p>Unity \u306f\u30cd\u30a4\u30c6\u30a3\u30d6\u3067 WebSocket \u3092\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u306a\u3044\u306e\u3067\u3001\u3053\u306e\u554f\u984c\u3092\u89e3\u6c7a\u3059\u308b\u305f\u3081\u306b NuGet \u306e WebSocket \u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002\u3054\u5b58\u77e5\u306e\u901a\u308a\u3001Unity \u306f C# \u3092\u4f7f\u7528\u3057\u3066\u304a\u308a\u3001JavaScript \u3092\u4f7f\u7528\u3059\u308b Node.js \u30b5\u30fc\u30d0\u30fc\u3068\u306f\u7570\u306a\u308b\u8a00\u8a9e\u3067\u3059\u3002<\/p>\n<blockquote><p>\n  <strong>NuGet\u3068\u306f\uff1f<\/strong><br \/>\n  NuGet \u306f .NET \u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u30de\u30cd\u30fc\u30b8\u30e3\u30fc\u3067\u3059\u3002NuGet \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u30c4\u30fc\u30eb\u306f\u3001\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u751f\u6210\u304a\u3088\u3073\u6d88\u8cbb\u3059\u308b\u6a5f\u80fd\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002NuGet Gallery \u306f\u3001\u3059\u3079\u3066\u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u4f5c\u6210\u8005\u3068\u6d88\u8cbb\u8005\u304c\u4f7f\u7528\u3059\u308b\u4e2d\u592e\u30d1\u30c3\u30b1\u30fc\u30b8\u30ea\u30dd\u30b8\u30c8\u30ea\u3067\u3059\u3002\n<\/p><\/blockquote>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u306f\u3001\u3088\u308a\u826f\u3044\u30d1\u30c3\u30b1\u30fc\u30b8\u7ba1\u7406\u306e\u305f\u3081\u306b\u3001<a href=\"https:\/\/github.com\/GlitchEnzo\/NuGetForUnity\">NuGetForUnity<\/a> \u3092\u4f7f\u7528\u3057\u307e\u3057\u305f\u3002Unity \u30d1\u30c3\u30b1\u30fc\u30b8\u306f\u3053\u306e<a href=\"https:\/\/github.com\/GlitchEnzo\/NuGetForUnity\/releases\">\u30ea\u30f3\u30af<\/a>\u304b\u3089\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u307e\u3059\u3002<\/p>\n<blockquote><p>\n  <strong>NuGetForUnity<\/strong> \u306f\u3001Unity \u30a8\u30c7\u30a3\u30bf\u5185\u3067\u52d5\u4f5c\u3059\u308b\u3088\u3046\u306b\u30bc\u30ed\u304b\u3089\u69cb\u7bc9\u3055\u308c\u305f NuGet \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3067\u3059\u3002NuGet \u306f\u30d1\u30c3\u30b1\u30fc\u30b8\u7ba1\u7406\u30b7\u30b9\u30c6\u30e0\u3067\u3001\u30b5\u30fc\u30d0\u30fc\u4e0a\u3067\u914d\u5e03\u3055\u308c\u3001\u30e6\u30fc\u30b6\u30fc\u306b\u3088\u3063\u3066\u6d88\u8cbb\u3055\u308c\u308b\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u7c21\u5358\u306b\u4f5c\u6210\u3067\u304d\u307e\u3059\u3002\n<\/p><\/blockquote>\n<p>\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u4f7f\u7528\u3059\u308b WebSocket \u30d1\u30c3\u30b1\u30fc\u30b8\u306f <code>WebSocketSharp-netstandard<\/code> \u3067\u3059\u3002<\/p>\n<p><a href=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/nuget-unity.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/nuget-unity.png\" alt=\"\" width=\"1918\" height=\"1058\" class=\"aligncenter size-full wp-image-29824\" srcset=\"\/wp-content\/uploads\/2023\/09\/nuget-unity.png 1918w, \/wp-content\/uploads\/2023\/09\/nuget-unity-300x165.png 300w, \/wp-content\/uploads\/2023\/09\/nuget-unity-1024x565.png 1024w, \/wp-content\/uploads\/2023\/09\/nuget-unity-768x424.png 768w, \/wp-content\/uploads\/2023\/09\/nuget-unity-1536x847.png 1536w, \/wp-content\/uploads\/2023\/09\/nuget-unity-600x331.png 600w\" sizes=\"(max-width: 1918px) 100vw, 1918px\" \/><\/a><\/p>\n<h4>WebSocket \u30af\u30e9\u30a4\u30a2\u30f3\u30c8<\/h4>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3067\u306f\u3001\u30b2\u30fc\u30e0\u958b\u59cb\u6642\u306b WebSocket \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3092\u521d\u671f\u5316\u3057\u3001\u30b2\u30fc\u30e0\u4e2d\u306b\u30d7\u30ec\u30a4\u30e4\u30fc\u304c\u30b9\u30da\u30fc\u30b9\u30d0\u30fc\u3092\u62bc\u3057\u305f\u3068\u304d\u306b WebSocket \u30b5\u30fc\u30d0\u30fc\u306b\u30c7\u30fc\u30bf\u3092\u9001\u4fe1\u3057\u307e\u3059\u3002\u3053\u306e\u30c7\u30fc\u30bf\u306b\u306f\u3001\u30b2\u30fc\u30e0\u4e16\u754c\u306b\u304a\u3051\u308b\u30d7\u30ec\u30a4\u30e4\u30fc\u306e\u4f4d\u7f6e\u306b\u95a2\u3059\u308b\u60c5\u5831\u3068\u3001<code>NumberOfMeatThrows<\/code> \u3068\u547c\u3070\u308c\u308b\u30b2\u30fc\u30e0\u56fa\u6709\u306e\u30e1\u30c8\u30ea\u30c3\u30af\u304c\u542b\u307e\u308c\u307e\u3059\u3002<\/p>\n<div class=\"clipboard\">\n<pre><code class=\"language-javascript\">\/\/ WsClient.cs\npublic class WsClient : MonoBehaviour\n{\n    WebSocket ws;\n\n    void Start()\n    {\n      \/\/...\n    }\n\n    void Update()\n    {\n        if (ws == null)\n        {\n            return;\n        }\n        if (Input.GetKeyDown(KeyCode.Space))\n        {\n            ws.Send(\"Save Data...\");\n            Dictionary&lt;string, object> dataToSave = new Dictionary&lt;string, object>();\n\n            \/\/Add player position\n            Vector3 playerPosition = GameObject.Find(\"Player\").transform.position;\n            dataToSave.Add(\"PlayerX\", playerPosition.x);\n            dataToSave.Add(\"PlayerY\", playerPosition.y);\n            dataToSave.Add(\"PlayerZ\", playerPosition.z);\n            dataToSave.Add(\"NumberOfMeatThrows\", GameManager.Instance.numberOfMeatThrows);\n            dataToSave.Add(\"type\", \"save\");\n\n            \/\/ Convert dictionary to JSON and send it\n            string json = JsonConvert.SerializeObject(dataToSave);\n            ws.Send(json);\n        }\n    }\n}\n<\/code><\/pre>\n<\/div>\n<p>**\u30b2\u30fc\u30e0\u30fb\u30eb\u30fc\u30d7\uff1a Update() \u30e1\u30bd\u30c3\u30c9<\/p>\n<p>\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u306f 1 \u30d5\u30ec\u30fc\u30e0\u306b 1 \u56de\u547c\u3073\u51fa\u3055\u308c\u3001\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u306e\u30a4\u30f3\u30bf\u30e9\u30af\u30b7\u30e7\u30f3\u3092\u53ef\u80fd\u306b\u3057\u307e\u3059\u3002WebSocket   \u30af\u30e9\u30a4\u30a2\u30f3\u30c8 <code>ws<\/code> \u304c\u521d\u671f\u5316\u3055\u308c\u3066\u3044\u306a\u3044\u5834\u5408\u3001\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u306f\u4f55\u3082\u305b\u305a\u306b\u623b\u308a\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u306f <strong>Spacebar<\/strong> \u30ad\u30fc\u304c\u62bc\u3055\u308c\u3066\u3044\u308b\u304b\u3069\u3046\u304b\u3092\u30c1\u30a7\u30c3\u30af\u3057\u307e\u3059\u3002\u3082\u3057\u62bc\u3055\u308c\u3066\u3044\u308c\u3070\u3001\u3044\u304f\u3064\u304b\u306e\u30c7\u30fc\u30bf\u3092\u53ce\u96c6\u3057\u3001WebSocket \u30b5\u30fc\u30d0\u30fc\u306b\u9001\u4fe1\u3057\u307e\u3059\u3002<\/p>\n<ul>\n<li><strong>Player<\/strong> \u3068\u3044\u3046 GameObject \u306e\u4f4d\u7f6e\u304c\u8f9e\u66f8\u306b\u683c\u7d0d\u3055\u308c\u307e\u3059\u3002<\/li>\n<li>\u300c\u8089\u3092\u6295\u3052\u305f\u300d\u56de\u6570\u3082\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002<\/li>\n<li>\u3053\u306e\u8f9e\u66f8\u30c7\u30fc\u30bf\u306f JSON \u6587\u5b57\u5217\u306b\u5909\u63db\u3055\u308c\u3001WebSocket \u7d4c\u7531\u3067\u30b2\u30fc\u30e0\u30b5\u30fc\u30d0\u30fc\u306b\u9001\u4fe1\u3055\u308c\u307e\u3059\u3002<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js \u3092\u3001\u30b9\u30c8\u30ec\u30fc\u30b8\u3068\u3057\u3066 GridDB \u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002 \u30d7\u30ed [&hellip;]<\/p>\n","protected":false},"author":41,"featured_media":49595,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1005],"tags":[],"class_list":["post-50875","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-1005"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT<\/title>\n<meta name=\"description\" content=\"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/save-unity-game-data-using-node-js-and-griddb\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"og:description\" content=\"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js\" \/>\n<meta property=\"og:url\" content=\"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/save-unity-game-data-using-node-js-and-griddb\/\" \/>\n<meta property=\"og:site_name\" content=\"GridDB: Open Source Time Series Database for IoT\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/griddbcommunity\/\" \/>\n<meta property=\"article:published_time\" content=\"2023-09-29T07:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-30T19:19:11+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1605\" \/>\n\t<meta property=\"og:image:height\" content=\"903\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"griddb-admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:site\" content=\"@GridDBCommunity\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"griddb-admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"5\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/\"},\"author\":{\"name\":\"griddb-admin\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233\"},\"headline\":\"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b\",\"datePublished\":\"2023-09-29T07:00:00+00:00\",\"dateModified\":\"2026-03-30T19:19:11+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/\"},\"wordCount\":265,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/\",\"url\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/\",\"name\":\"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT\",\"isPartOf\":{\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage\"},\"thumbnailUrl\":\"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\",\"datePublished\":\"2023-09-29T07:00:00+00:00\",\"dateModified\":\"2026-03-30T19:19:11+00:00\",\"description\":\"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js\",\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage\",\"url\":\"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\",\"contentUrl\":\"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png\",\"width\":1605,\"height\":903},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#website\",\"url\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/\",\"name\":\"GridDB: Open Source Time Series Database for IoT\",\"description\":\"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL\",\"publisher\":{\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ja\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization\",\"name\":\"Fixstars\",\"url\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"contentUrl\":\"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png\",\"width\":200,\"height\":83,\"caption\":\"Fixstars\"},\"image\":{\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/griddbcommunity\/\",\"https:\/\/x.com\/GridDBCommunity\",\"https:\/\/www.linkedin.com\/company\/griddb-by-toshiba\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233\",\"name\":\"griddb-admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g\",\"caption\":\"griddb-admin\"},\"url\":\"https:\/\/griddb.net\/ja\/author\/griddb-admin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT","description":"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/save-unity-game-data-using-node-js-and-griddb\/","og_locale":"ja_JP","og_type":"article","og_title":"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT","og_description":"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js","og_url":"https:\/\/griddb.net\/ja\/\u672a\u5206\u985e\/save-unity-game-data-using-node-js-and-griddb\/","og_site_name":"GridDB: Open Source Time Series Database for IoT","article_publisher":"https:\/\/www.facebook.com\/griddbcommunity\/","article_published_time":"2023-09-29T07:00:00+00:00","article_modified_time":"2026-03-30T19:19:11+00:00","og_image":[{"width":1605,"height":903,"url":"https:\/\/griddb.net\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png","type":"image\/png"}],"author":"griddb-admin","twitter_card":"summary_large_image","twitter_creator":"@GridDBCommunity","twitter_site":"@GridDBCommunity","twitter_misc":{"\u57f7\u7b46\u8005":"griddb-admin","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"5\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#article","isPartOf":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/"},"author":{"name":"griddb-admin","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233"},"headline":"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b","datePublished":"2023-09-29T07:00:00+00:00","dateModified":"2026-03-30T19:19:11+00:00","mainEntityOfPage":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/"},"wordCount":265,"commentCount":0,"publisher":{"@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization"},"image":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png","inLanguage":"ja","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/","url":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/","name":"Node.js \u3068 GridDB \u3092\u4f7f\u7528\u3057\u3066 Unity \u30b2\u30fc\u30e0\u30c7\u30fc\u30bf\u3092\u4fdd\u5b58\u3059\u308b | GridDB: Open Source Time Series Database for IoT","isPartOf":{"@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage"},"image":{"@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage"},"thumbnailUrl":"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png","datePublished":"2023-09-29T07:00:00+00:00","dateModified":"2026-03-30T19:19:11+00:00","description":"\u306f\u3058\u3081\u306b \u3053\u306e\u6295\u7a3f\u3067\u306f\u3001Feed The Animals \u3068\u3044\u3046\u30b7\u30f3\u30d7\u30eb\u306a\u30b2\u30fc\u30e0\u3092\u4f5c\u308a\u307e\u3059\u3002\u3053\u306e\u30b2\u30fc\u30e0\u3067\u306f\u3001\u30d0\u30c3\u30af\u30a8\u30f3\u30c9\u30b5\u30fc\u30d0\u30fc\u3068\u3057\u3066 Node.js","inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/"]}]},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb.net\/ja\/%e6%9c%aa%e5%88%86%e9%a1%9e\/save-unity-game-data-using-node-js-and-griddb\/#primaryimage","url":"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png","contentUrl":"\/wp-content\/uploads\/2023\/09\/unity-nodejs-griddb.png","width":1605,"height":903},{"@type":"WebSite","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#website","url":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/","name":"GridDB: Open Source Time Series Database for IoT","description":"GridDB is an open source time-series database with the performance of NoSQL and convenience of SQL","publisher":{"@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ja"},{"@type":"Organization","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#organization","name":"Fixstars","url":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/","logo":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/logo\/image\/","url":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","contentUrl":"https:\/\/griddb.net\/wp-content\/uploads\/2019\/04\/fixstars_logo_web_tagline.png","width":200,"height":83,"caption":"Fixstars"},"image":{"@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/griddbcommunity\/","https:\/\/x.com\/GridDBCommunity","https:\/\/www.linkedin.com\/company\/griddb-by-toshiba"]},{"@type":"Person","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/4fe914ca9576878e82f5e8dd3ba52233","name":"griddb-admin","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/griddb-linux-hte8hndjf8cka8ht.westus-01.azurewebsites.net\/en\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5bceca1cafc06886a7ba873e2f0a28011a1176c4dea59709f735b63ae30d0342?s=96&d=mm&r=g","caption":"griddb-admin"},"url":"https:\/\/griddb.net\/ja\/author\/griddb-admin\/"}]}},"_links":{"self":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50875","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/users\/41"}],"replies":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/comments?post=50875"}],"version-history":[{"count":2,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50875\/revisions"}],"predecessor-version":[{"id":55118,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/posts\/50875\/revisions\/55118"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media\/49595"}],"wp:attachment":[{"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/media?parent=50875"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/categories?post=50875"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/griddb.net\/ja\/wp-json\/wp\/v2\/tags?post=50875"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}