{"id":4324,"date":"2016-07-24T14:40:06","date_gmt":"2016-07-24T06:40:06","guid":{"rendered":"http:\/\/unitycoder.com\/blog\/?p=4324"},"modified":"2020-11-09T12:57:34","modified_gmt":"2020-11-09T10:57:34","slug":"enter-play-mode-with-f5-key","status":"publish","type":"post","link":"https:\/\/unitycoder.com\/blog\/2016\/07\/24\/enter-play-mode-with-f5-key\/","title":{"rendered":"Enter Play Mode with F5 key"},"content":{"rendered":"<p>Woaaah! Been waiting for this feature since VB5.. to have unity enter playmode with F5 key!<br \/>\n<em>*Same key can be used to stop play mode also<\/em><\/p>\n<p>Founded pretty much ready script from <a href=\"http:\/\/answers.unity3d.com\/answers\/1204307\/view.html\" target=\"_blank\" rel=\"noopener noreferrer\">unity answers<\/a>,<br \/>\nremoved the secondary shortcut and added check for if in playmode, then dont try saving..<br \/>\n(It could be customized to have separate Escape key for exit playmode too)<\/p>\n<p><strong>source:<\/strong> &#8220;F5 to play\/stop&#8221;<br \/>\n<a href=\"https:\/\/github.com\/UnityCommunity\/UnityLibrary\/blob\/master\/Assets\/Scripts\/Editor\/EditorShortCutKeys.cs\">https:\/\/github.com\/UnityCommunity\/UnityLibrary\/blob\/master\/Assets\/Scripts\/Editor\/EditorShortCutKeys.cs<\/a><\/p>\n<p>&#8212;<\/p>\n<p><strong>Next dream:<\/strong><br \/>\n&#8211; Pressing F5 in VisualStudio would switch to unity\/compile scripts, then enter playmode! (all with 1 keypress from vs)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Woaaah! Been waiting for this feature since VB5.. to have unity enter playmode with F5 key! *Same key can be used to stop play mode also Founded pretty much ready script from unity answers, removed the secondary shortcut and added check for if in playmode, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":4325,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"Enter Play Mode with F5 key","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[23,3],"tags":[568,358,898,778,833,897,800],"class_list":["post-4324","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-functions-unity3d","category-unity3d","tag-custom","tag-editor","tag-f5","tag-key","tag-play","tag-run","tag-shortcut"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/unitycoder.com\/blog\/wp-content\/uploads\/2016\/07\/f5-key.png?fit=200%2C189&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/p1KTaT-17K","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4324","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/comments?post=4324"}],"version-history":[{"count":3,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4324\/revisions"}],"predecessor-version":[{"id":5297,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/posts\/4324\/revisions\/5297"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/media\/4325"}],"wp:attachment":[{"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/media?parent=4324"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/categories?post=4324"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unitycoder.com\/blog\/wp-json\/wp\/v2\/tags?post=4324"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}