<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>albatrus</author_name>
  <author_url>https://blog.hatena.ne.jp/albatrus/</author_url>
  <blog_title>albatrusのブログ</blog_title>
  <blog_url>https://albatrus.com/</blog_url>
  <categories>
    <anon>cocos2d</anon>
    <anon>cocos2d</anon>
    <anon>game</anon>
    <anon>iOs</anon>
  </categories>
  <description>本日、引き続き、敵及び攻撃パターンを作っていました。その中で、「Player」の位置に応じて、敵が近づいてくる攻撃パターンを考えて、コードを触っていたのですがなかなかうまくいかずに、Twitterにツィートして所、shi3zさんが「こうすればうまくいくよ」と返信をいただいたので早速cocos2dでやってみました。 Twitterでのやりとり ↓↓↓ 2つある方法中のの後者については「外積」をネットで調べても全然わからなかったので、前者の差分ベクトルを使って考えました。 敵を自機（プレイヤー）に接近させる処理 色々調べてみたところ、cocos2dで、差分ベクトルを計算する方法は以下のようになりま…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Falbatrus.com%2Fentry%2Fmain%2Fios%2F2961&quot; title=&quot; ゲーム開発日誌part12 　自機の位置を利用した敵機の行動パターン - albatrusのブログ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>https://cdn-ak.f.st-hatena.com/images/fotolife/a/albatrus/20210116/20210116231651.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2012-05-11 22:45:32</published>
  <title> ゲーム開発日誌part12 　自機の位置を利用した敵機の行動パターン</title>
  <type>rich</type>
  <url>https://albatrus.com/entry/main/ios/2961</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
