{"action":"created","issue":{"url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/43","repository_url":"https://api.github.com/repos/Baste-RainGames/Node_Editor","labels_url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/43/labels{/name}","comments_url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/43/comments","events_url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/43/events","html_url":"https://github.com/Baste-RainGames/Node_Editor/issues/43","id":134665025,"number":43,"title":"Custom (Additional) Save format for Runtime","user":{"login":"Seneral","id":12800840,"avatar_url":"https://avatars.githubusercontent.com/u/12800840?v=3","gravatar_id":"","url":"https://api.github.com/users/Seneral","html_url":"https://github.com/Seneral","followers_url":"https://api.github.com/users/Seneral/followers","following_url":"https://api.github.com/users/Seneral/following{/other_user}","gists_url":"https://api.github.com/users/Seneral/gists{/gist_id}","starred_url":"https://api.github.com/users/Seneral/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Seneral/subscriptions","organizations_url":"https://api.github.com/users/Seneral/orgs","repos_url":"https://api.github.com/users/Seneral/repos","events_url":"https://api.github.com/users/Seneral/events{/privacy}","received_events_url":"https://api.github.com/users/Seneral/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/labels/Difficulty%20High","name":"Difficulty High","color":"e11d21"},{"url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/labels/Open","name":"Open","color":"207de5"},{"url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/labels/required","name":"required","color":"f7c6c7"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2016-02-18T19:03:47Z","updated_at":"2016-03-15T07:29:25Z","closed_at":null,"body":"**Description:** Current save format, ScriptableObjects, cannot be created and saved at runtime nor saved externally. So, a new save file format for runtime is needed. It should be optional for the Editor but essential for Runtime.\r\nMaybe Binary, but more likely XML, just like Substance's .sbs.\r\n\r\n**State:** None. Needs some modifications to Node types and NodeKnob types to save anny additional data. Everything else is known for each object type and can be hardcoded (I guess?). Please notify me before working on this to discuss some details:)"},"comment":{"url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/comments/196700736","html_url":"https://github.com/Baste-RainGames/Node_Editor/issues/43#issuecomment-196700736","issue_url":"https://api.github.com/repos/Baste-RainGames/Node_Editor/issues/43","id":196700736,"user":{"login":"Seneral","id":12800840,"avatar_url":"https://avatars.githubusercontent.com/u/12800840?v=3","gravatar_id":"","url":"https://api.github.com/users/Seneral","html_url":"https://github.com/Seneral","followers_url":"https://api.github.com/users/Seneral/followers","following_url":"https://api.github.com/users/Seneral/following{/other_user}","gists_url":"https://api.github.com/users/Seneral/gists{/gist_id}","starred_url":"https://api.github.com/users/Seneral/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Seneral/subscriptions","organizations_url":"https://api.github.com/users/Seneral/orgs","repos_url":"https://api.github.com/users/Seneral/repos","events_url":"https://api.github.com/users/Seneral/events{/privacy}","received_events_url":"https://api.github.com/users/Seneral/received_events","type":"User","site_admin":false},"created_at":"2016-03-15T07:29:25Z","updated_at":"2016-03-15T07:29:25Z","body":"Ok, if your doing it before the framework was initialized (in the Open function f.E.), use this:\r\n``` C#\r\nNodeEditor.ReInit (false); // Make sure the framework is initiated\r\n_editor.AssureCanvas (); // Make sure a canvas is loaded\r\nNodeEditor.curNodeCanvas = _editor.mainNodeCanvas; // Set the canvas to create the Node on as the current one\r\n\r\n// Location is the canvas center (mouse pos won't work in creation)\r\nCalcNode node = Node.Create (CalcNode.ID, Vector2.zero) as CalcNode; // Creating a calc node\r\nDebug.Log (node.name);\r\n```\r\nif your using it in the GUI of the editor window when it's sure it is initiated and the canvas is existant, use something like this:\r\n```C#\r\nif (GUILayout.Button (new GUIContent (\"Add my Node\"))) \r\n{\r\n\tNodeEditor.curNodeCanvas = mainNodeCanvas;\r\n\tCalcNode node = Node.Create (CalcNode.ID, NodeEditor.ScreenToGUIPos (mainEditorState, Event.current.mousePosition)) as CalcNode;\r\n\tDebug.Log (node.name);\r\n}\r\n```\r\nThat should work, maybe the names vary a bit because I changed them in that area on my development copy...."}}