{"id":2040,"date":"2025-09-04T16:22:35","date_gmt":"2025-09-04T15:22:35","guid":{"rendered":"https:\/\/kankiprojects.com\/?p=2040"},"modified":"2025-09-04T17:14:21","modified_gmt":"2025-09-04T16:14:21","slug":"ai-for-strategy-and-role-playing-games","status":"publish","type":"post","link":"https:\/\/kankiprojects.com\/es\/ai-for-strategy-and-role-playing-games\/","title":{"rendered":"AI for strategy and role-playing games"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\" id=\"general-presentation\"><strong>General presentation<\/strong><\/h2>\n\n\n\n<p>In this second activity we have practiced with the movement of agents in&nbsp;<em>Formation Motion<\/em>&nbsp;and&nbsp;<em>Flocking<\/em>&nbsp;, and decision making with&nbsp;<em>behavior trees<\/em>&nbsp;, this time with writing code in C#.<\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe loading=\"lazy\" title=\"AI - PAC 2\" width=\"1290\" height=\"726\" src=\"https:\/\/www.youtube.com\/embed\/1LeBaMoYSIg?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"act-1-security-patrol\"><strong>ACT 1: security patrol<\/strong><\/h2>\n\n\n\n<p>This first activity has surprised me how simple it has turned out, since I asked ChatGPT (link to the conversation in the webgraphy) to make a suitable script for my scene with the parameters mentioned in the GitHub of the subject and it gave a decent result at the first attempt.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/media.folio.uoc.edu\/private\/wp-content\/uploads\/sites\/19359\/2024\/12\/26233127\/Captura-de-pantalla-2024-12-26-233241.jpg?Expires=1757000155&amp;Signature=GJL8EzzXlxkak4VPvGqVjSk97205D2JlJAPdhvPUkFEo~hLgTLkECTcmSQ4lg8LA89sloL0hEoCAdhQfzbGYUnipYs4uNMEsPnk6wevPVJoim9nfyWMWou5Glu3U04EhzM8sADX~KzSUIydn1DcmxfjWQ~ylzAw1Ir9EXc~xwNu4uR8VIyVMD287zyYhUV952kmWIa3H5jcJ2oSCTgaTEnHK5TxijGiJyHLSwmYMeA40iaf4HXdu57W4NHuKtUOZYN-0E-XE79KU4m5dNK06VipTAabPOJ6DeZO70iXzercE5QHmamEcWPdcNC2hUXqk~Wl-WXdjNqALeTdNDzSMnw__&amp;Key-Pair-Id=K3T7EYR9NMFURT\" alt=\"\" class=\"wp-image-532\"\/><\/figure>\n\n\n\n<p>As in the previous activity I configured the patrolling agent correctly, basically what I did was create several copies of the guard (changing the color of the texture to violet to differentiate them), but without motion scripts and I grouped them under an Empty that contains the&nbsp;<em>Formation Motion script component.<\/em>&nbsp;I have configured the script so that it can enter the formation figure dynamically.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"act-2-insect-hive\"><strong>ACT 2: insect hive<\/strong><\/h2>\n\n\n\n<p>I&#8217;ve decided that my hive of insects will be a swarm of bees and a panel like FlockManager (it&#8217;s not the most original thing in the world, I know, but I found a model of a very cute bee that I couldn&#8217;t not use).<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/media.folio.uoc.edu\/private\/wp-content\/uploads\/sites\/19359\/2024\/12\/26233258\/Captura-de-pantalla-2024-12-26-233316.jpg?Expires=1757000155&amp;Signature=jnJXFJozuCVGAQMSmiZNn13vB38cAGHXGpX-y6DfepTTdCQsRC9ZfNWSD2IEhYvmQmYrZgFkqaOCGya5SNDWOFcT8ohPrpWjezd4fF1zmhbdp1H7Jh4I9oIPk1oFfT3Dlq3GEcluNih-WY7Cgz8cajG3HttxFJpn-UcogOAzrr97m~piu9ygcr7Rl~wE-CbZP4HGwHN1fk-FSbnThFrWiOsz-Uk7m8UXvIXWKOcIpKBfkcCdoXcX2tTovtWQ0WYAv3Wvmxb7rCHP239HKREGh9uJ3ijuxUJwxXG96rqMJJ9VR~M7OWmOQfeimMr9QN80RDo~OILlmuehpL2LfEEHdw__&amp;Key-Pair-Id=K3T7EYR9NMFURT\" alt=\"\" class=\"wp-image-533\"\/><\/figure>\n\n\n\n<p>For this activity I have started from the code offered by our professor on GitHub, but I have made several modifications with the help of ChatGPT so that the behavior of the swarm is more natural and more controlled. Mainly, what I have done has been to add a maximum radius from which the bees can move away from the hive and I have increased the values \u200b\u200bof the vectors quite a bit so that they all have a more energetic movement. In addition, I have added alterations to the vectors so that they move more randomly.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"act-3-flocking-leader\"><strong>ACT 3: flocking leader<\/strong><\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"3-1-behavior-and-movement\">3.1. Behavior and movement<\/h3>\n\n\n\n<p>Firstly, in this activity I tried to use Muse Behavoirs in version 0.11, but it turned out to be extremely unstable (in addition, the behavior of the other agents was unusable for some reason) with Unity &#8220;crashes&#8221;. In its version 0.10.1. (recommended by our professor) has given me multiple errors when loading the project, possibly due to the lack of components of the most modern version.<\/p>\n\n\n\n<p>For these reasons, I have decided to proceed with the implementation with&nbsp;<a href=\"https:\/\/assetstore.unity.com\/packages\/tools\/visual-scripting\/behavior-bricks-74816\">Behavior Bricks<\/a>&nbsp;. This asset at first glance seems more complex and &#8220;rough&#8221; than Muse Behavoirs, but hey, it will do. The first thing I did was follow the outline of the old&nbsp;<a href=\"https:\/\/gebakx.github.io\/dm-games\/#37\">notes of the subject<\/a>&nbsp;a little , but these were for a behavior different from the one we want for this bee, so I asked ChatGPT to make some modifications in the script of the condition &#8220;Is Cop Near?&#8221; and also in the AI \u200b\u200blogic tree.<\/p>\n\n\n\n<p>The condition script must be placed in the &#8220;conditions&#8221; folder of the BehaviorBricks asset for the editor to detect it.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/media.folio.uoc.edu\/private\/wp-content\/uploads\/sites\/19359\/2024\/12\/26233304\/Captura-de-pantalla-2024-12-26-233335.jpg?Expires=1757000155&amp;Signature=QBrGc8XAg2ea~B7vjB1marnGWjPJS6YWK09uTZdV-uFPsgeIe0ord8jmXDcFPpTQEC2L5HmGyaISONn2qXy4e04WuURkF8c63HYefKfZXxXL4CcE-FMTdKMN7DoDzmbbiS3vs9KzEdoKXxhymAQhK7wuYaEAzAwTE3nnopE--RqsHYORJHVYsFMi-PZ89HukhcVVsO0BKeYr29eboAqunQZC91aBwCTjdjeUML-GMn6vUEcg2DUzpyBXNtYvaSaDic4cwFJcp6kgi-JvoPFzqb25meOu~B~zjIBm31Eb6XmDCmAnGkw4JdcpyxORnvvRuXldukKVBHB4i~Xsgiac2w__&amp;Key-Pair-Id=K3T7EYR9NMFURT\" alt=\"\" class=\"wp-image-534\"\/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"3-2-monitoring-flocking\">3.2. Monitoring flocking<\/h3>\n\n\n\n<p>Unexpectedly, the most challenging part for me was to make the flocking be the leader bee when it was required. It was thanks to the Unity AI Swarming Tutorial (Stephen Barr, 2018) that I managed to incorporate a simple logic that made the LeadBee object follow, although instead the flocking code has been quite altered.<\/p>\n\n\n\n<p>For some reason I also had problems with the orientation of the bees, since they were all &#8220;spawned&#8221; twisted 90\u00ba in the Z axis. I fixed it by applying an extra rotation directly in the &#8220;flocks&#8221; script.<\/p>\n\n\n\n<p>I also had problems making the agents collide with the insects, since they also bothered the LeadBee and the movement was, therefore, very orthopedic. I tried to solve it by making the bees collide with the police with colliders and not with NavMeshObstacles as I had originally done, but for this I had to use Unity layers and the result is not so satisfactory. Both options are included in the demo video.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"webography\"><strong>Webography<\/strong><\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Simpson, C. (2023, December 8). Behavior trees for AI: How they work.\u00a0<a href=\"https:\/\/www.gamedeveloper.com\/programming\/behavior-trees-for-ai-how-they-work\">https:\/\/www.gamedeveloper.com\/programming\/behavior-trees-for-ai-how-they-work<\/a><\/li>\n\n\n\n<li><em>Decision making for games<\/em>\u00a0. (n.d.).\u00a0<a href=\"https:\/\/gebakx.github.io\/dm-games\/#38\">https:\/\/gebakx.github.io\/dm-games\/#38<\/a><\/li>\n\n\n\n<li>gameAIUnity\/dm\/dm.md at main \u00b7 gebakx\/gameAIUnity. (n.d.).\u00a0<a href=\"https:\/\/github.com\/gebakx\/gameAIUnity\/blob\/main\/dm\/dm.md\">https:\/\/github.com\/gebakx\/gameAIUnity\/blob\/main\/dm\/dm.md<\/a><\/li>\n\n\n\n<li><em>quick:design [BehaviorBricks]<\/em>\u00a0. (n.d.).\u00a0<a href=\"https:\/\/bb.padaonegames.com\/quick:design\">https:\/\/bb.padaonegames.com\/quick:design<\/a><\/li>\n\n\n\n<li>Stephen Barr. (2018, July 15). Unity AI Swarming Tutorial (Flocking but it follows the Player) [Video]. YouTube.\u00a0<a href=\"https:\/\/www.youtube.com\/watch?v=5ziHg2kO56s\">https:\/\/www.youtube.com\/watch?v=5ziHg2kO56s<\/a><\/li>\n\n\n\n<li>OpenAI. (2024). ChatGPT (Version 22 November) [Large language model].\u00a0<a href=\"https:\/\/chat.openai.com\/chat\">https:\/\/chat.openai.com\/chat<\/a><\/li>\n\n\n\n<li>ChatGPT chat used for implementation, troubleshooting compilation errors, providing ideas and cleaning up the code:\u00a0<a href=\"https:\/\/chatgpt.com\/share\/67507a9f-7680-800b-9956-d8882661b1ed\">https:\/\/chatgpt.com\/share\/67507a9f-7680-800b-9956-d8882661b1ed<\/a><\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"assets\">Assets<\/h2>\n\n\n\n<p>Sketchfab. (n.d.). Beee, bumblebee \u2013 Download Free 3D model by i.deal3d.&nbsp;<a href=\"https:\/\/sketchfab.com\/3d-models\/beee-bumblebee-816b3d1876434439bb02b6046d51ca32\">https:\/\/sketchfab.com\/3d-models\/beee-bumblebee-816b3d1876434439bb02b6046d51ca32<\/a><\/p>\n\n\n\n<p>Sketchfab. (n.d.). Beee, bumblebee \u2013 Download Free 3D model by i.deal3d.&nbsp;<a href=\"https:\/\/sketchfab.com\/3d-models\/beehive-5627f41b490246a2a1e1e88b554e17bf\">https:\/\/sketchfab.com\/3d-models\/beehive-5627f41b490246a2a1e1e88b554e17bf<\/a><\/p>\n\n\n\n<p>Sketchfab. (n.d.). Stylized tree stump \u2013 Download Free 3D model by Aartee.&nbsp;<a href=\"https:\/\/sketchfab.com\/3d-models\/stylized-tree-stump-04d51f5c2fb643aab3b93b451d1b77c9\">https:\/\/sketchfab.com\/3d-models\/stylized-tree-stump-04d51f5c2fb643aab3b93b451d1b77c9<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>General presentation In this second activity we have practiced with the movement of agents in&nbsp;Formation Motion&nbsp;and&nbsp;Flocking&nbsp;, and decision making with&nbsp;behavior trees&nbsp;, this time with writing code in C#. ACT 1: security patrol This first activity has surprised me how simple it has turned out, since I asked ChatGPT (link to the conversation in the webgraphy) [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":2041,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_gspb_post_css":"","_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","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":[14,12],"tags":[20,23,22],"class_list":["post-2040","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-3d","category-development","tag-ai","tag-studies","tag-unity"],"blocksy_meta":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>AI for strategy and role-playing games - Kanki Projects<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/kankiprojects.com\/es\/ai-for-strategy-and-role-playing-games\/\" \/>\n<meta property=\"og:locale\" content=\"es_ES\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"AI for strategy and role-playing games - Kanki Projects\" \/>\n<meta property=\"og:description\" content=\"General presentation In this second activity we have practiced with the movement of agents in&nbsp;Formation Motion&nbsp;and&nbsp;Flocking&nbsp;, and decision making with&nbsp;behavior trees&nbsp;, this time with writing code in C#. ACT 1: security patrol This first activity has surprised me how simple it has turned out, since I asked ChatGPT (link to the conversation in the webgraphy) [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/kankiprojects.com\/es\/ai-for-strategy-and-role-playing-games\/\" \/>\n<meta property=\"og:site_name\" content=\"Kanki Projects\" \/>\n<meta property=\"article:published_time\" content=\"2025-09-04T15:22:35+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-09-04T16:14:21+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1182\" \/>\n\t<meta property=\"og:image:height\" content=\"658\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Escrito por\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Tiempo de lectura\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/\"},\"author\":{\"name\":\"admin\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#\\\/schema\\\/person\\\/0e11590f4b7d2062bd82d8af59428401\"},\"headline\":\"AI for strategy and role-playing games\",\"datePublished\":\"2025-09-04T15:22:35+00:00\",\"dateModified\":\"2025-09-04T16:14:21+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/\"},\"wordCount\":866,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#\\\/schema\\\/person\\\/0e11590f4b7d2062bd82d8af59428401\"},\"image\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/Captura-de-pantalla-2024-12-26-233623.jpg\",\"keywords\":[\"AI\",\"Studies\",\"Unity\"],\"articleSection\":[\"3D\",\"Development\"],\"inLanguage\":\"es\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/\",\"url\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/\",\"name\":\"AI for strategy and role-playing games - Kanki Projects\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/Captura-de-pantalla-2024-12-26-233623.jpg\",\"datePublished\":\"2025-09-04T15:22:35+00:00\",\"dateModified\":\"2025-09-04T16:14:21+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#breadcrumb\"},\"inLanguage\":\"es\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"es\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#primaryimage\",\"url\":\"https:\\\/\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/Captura-de-pantalla-2024-12-26-233623.jpg\",\"contentUrl\":\"https:\\\/\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/Captura-de-pantalla-2024-12-26-233623.jpg\",\"width\":1182,\"height\":658},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/ai-for-strategy-and-role-playing-games\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/kankiprojects.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"AI for strategy and role-playing games\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#website\",\"url\":\"https:\\\/\\\/kankiprojects.com\\\/\",\"name\":\"Kanki Projects\",\"description\":\"Digital Artist Portfolio\",\"publisher\":{\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#\\\/schema\\\/person\\\/0e11590f4b7d2062bd82d8af59428401\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/kankiprojects.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"es\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/kankiprojects.com\\\/#\\\/schema\\\/person\\\/0e11590f4b7d2062bd82d8af59428401\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"es\",\"@id\":\"https:\\\/\\\/i0.wp.com\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2023\\\/07\\\/Profile_picture.png?fit=600%2C600&ssl=1\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2023\\\/07\\\/Profile_picture.png?fit=600%2C600&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2023\\\/07\\\/Profile_picture.png?fit=600%2C600&ssl=1\",\"width\":600,\"height\":600,\"caption\":\"admin\"},\"logo\":{\"@id\":\"https:\\\/\\\/i0.wp.com\\\/kankiprojects.com\\\/wp-content\\\/uploads\\\/2023\\\/07\\\/Profile_picture.png?fit=600%2C600&ssl=1\"},\"sameAs\":[\"https:\\\/\\\/kankiprojects.com\"],\"url\":\"https:\\\/\\\/kankiprojects.com\\\/es\\\/author\\\/admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"AI for strategy and role-playing games - Kanki Projects","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:\/\/kankiprojects.com\/es\/ai-for-strategy-and-role-playing-games\/","og_locale":"es_ES","og_type":"article","og_title":"AI for strategy and role-playing games - Kanki Projects","og_description":"General presentation In this second activity we have practiced with the movement of agents in&nbsp;Formation Motion&nbsp;and&nbsp;Flocking&nbsp;, and decision making with&nbsp;behavior trees&nbsp;, this time with writing code in C#. ACT 1: security patrol This first activity has surprised me how simple it has turned out, since I asked ChatGPT (link to the conversation in the webgraphy) [&hellip;]","og_url":"https:\/\/kankiprojects.com\/es\/ai-for-strategy-and-role-playing-games\/","og_site_name":"Kanki Projects","article_published_time":"2025-09-04T15:22:35+00:00","article_modified_time":"2025-09-04T16:14:21+00:00","og_image":[{"width":1182,"height":658,"url":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","type":"image\/jpeg"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Escrito por":"admin","Tiempo de lectura":"5 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#article","isPartOf":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/"},"author":{"name":"admin","@id":"https:\/\/kankiprojects.com\/#\/schema\/person\/0e11590f4b7d2062bd82d8af59428401"},"headline":"AI for strategy and role-playing games","datePublished":"2025-09-04T15:22:35+00:00","dateModified":"2025-09-04T16:14:21+00:00","mainEntityOfPage":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/"},"wordCount":866,"commentCount":0,"publisher":{"@id":"https:\/\/kankiprojects.com\/#\/schema\/person\/0e11590f4b7d2062bd82d8af59428401"},"image":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#primaryimage"},"thumbnailUrl":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","keywords":["AI","Studies","Unity"],"articleSection":["3D","Development"],"inLanguage":"es","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/","url":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/","name":"AI for strategy and role-playing games - Kanki Projects","isPartOf":{"@id":"https:\/\/kankiprojects.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#primaryimage"},"image":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#primaryimage"},"thumbnailUrl":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","datePublished":"2025-09-04T15:22:35+00:00","dateModified":"2025-09-04T16:14:21+00:00","breadcrumb":{"@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#breadcrumb"},"inLanguage":"es","potentialAction":[{"@type":"ReadAction","target":["https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/"]}]},{"@type":"ImageObject","inLanguage":"es","@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#primaryimage","url":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","contentUrl":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","width":1182,"height":658},{"@type":"BreadcrumbList","@id":"https:\/\/kankiprojects.com\/ai-for-strategy-and-role-playing-games\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/kankiprojects.com\/"},{"@type":"ListItem","position":2,"name":"AI for strategy and role-playing games"}]},{"@type":"WebSite","@id":"https:\/\/kankiprojects.com\/#website","url":"https:\/\/kankiprojects.com\/","name":"Kanki Projects","description":"Digital Artist Portfolio","publisher":{"@id":"https:\/\/kankiprojects.com\/#\/schema\/person\/0e11590f4b7d2062bd82d8af59428401"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/kankiprojects.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"es"},{"@type":["Person","Organization"],"@id":"https:\/\/kankiprojects.com\/#\/schema\/person\/0e11590f4b7d2062bd82d8af59428401","name":"admin","image":{"@type":"ImageObject","inLanguage":"es","@id":"https:\/\/i0.wp.com\/kankiprojects.com\/wp-content\/uploads\/2023\/07\/Profile_picture.png?fit=600%2C600&ssl=1","url":"https:\/\/i0.wp.com\/kankiprojects.com\/wp-content\/uploads\/2023\/07\/Profile_picture.png?fit=600%2C600&ssl=1","contentUrl":"https:\/\/i0.wp.com\/kankiprojects.com\/wp-content\/uploads\/2023\/07\/Profile_picture.png?fit=600%2C600&ssl=1","width":600,"height":600,"caption":"admin"},"logo":{"@id":"https:\/\/i0.wp.com\/kankiprojects.com\/wp-content\/uploads\/2023\/07\/Profile_picture.png?fit=600%2C600&ssl=1"},"sameAs":["https:\/\/kankiprojects.com"],"url":"https:\/\/kankiprojects.com\/es\/author\/admin\/"}]}},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/kankiprojects.com\/wp-content\/uploads\/2025\/09\/Captura-de-pantalla-2024-12-26-233623.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/posts\/2040","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/comments?post=2040"}],"version-history":[{"count":1,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/posts\/2040\/revisions"}],"predecessor-version":[{"id":2042,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/posts\/2040\/revisions\/2042"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/media\/2041"}],"wp:attachment":[{"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/media?parent=2040"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/categories?post=2040"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kankiprojects.com\/es\/wp-json\/wp\/v2\/tags?post=2040"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}