<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Development &#8211; INCD021</title>
	<atom:link href="https://incd021.com/tag/development/feed/" rel="self" type="application/rss+xml" />
	<link>https://incd021.com</link>
	<description>Programming, thoughts, life  and art.</description>
	<lastBuildDate>Thu, 18 Apr 2013 20:15:00 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.8.1</generator>
	<item>
		<title>Don&#8217;t Fall Asheep Progress 2013-04-18</title>
		<link>https://incd021.com/2013/04/18/dont-fall-asheep-progress-2013-04-18/</link>
					<comments>https://incd021.com/2013/04/18/dont-fall-asheep-progress-2013-04-18/#respond</comments>
		
		<dc:creator><![CDATA[INC $D021]]></dc:creator>
		<pubDate>Thu, 18 Apr 2013 20:15:00 +0000</pubDate>
				<category><![CDATA[Don't fall asheep]]></category>
		<category><![CDATA[Game]]></category>
		<category><![CDATA[Unity]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Progress]]></category>
		<guid isPermaLink="false">http://incd021.com/?p=189</guid>

					<description><![CDATA[Don&#8217;t Fall Asheep Progress: Finally got around to start on the mock-ups for the project, but first I created the basic Unity setup and copied reusable scripts from the &#8220;Do No....]]></description>
										<content:encoded><![CDATA[<h1>Don&#8217;t Fall Asheep Progress:</h1>
<p>Finally got around to start on the mock-ups for the project, but first I created the basic Unity setup and copied reusable scripts from the &#8220;Do No Harm&#8221; project. Then I made a small batch script that creates my basic folder structure, so I don&#8217;t have to create it every time I start a new project.</p>
<p>Drew a few texture items to be able to try out some ideas. Without some textures, I find it very hard to gent a good camera angle for the game and how big the game area should be.</p>
<figure id="attachment_190" aria-describedby="caption-attachment-190" style="width: 256px" class="wp-caption aligncenter"><a href="https://incd021.com/wp-content/uploads/2013/04/DFA-MainTexture.png"><img fetchpriority="high" decoding="async" class="size-full wp-image-190 " title="Don't fall asheep MainTexture" alt="Don't fall asheep MainTexture" src="https://incd021.com/wp-content/uploads/2013/04/DFA-MainTexture.png" width="256" height="256" /></a><figcaption id="caption-attachment-190" class="wp-caption-text">Don&#8217;t fall asheep MainTexture</figcaption></figure>
<p><span style="line-height: 1.5;">Created a basic Sheep in Blender and discarded it, I still don&#8217;t know if I&#8217;m going to do the game in 2D, 2.5D or 3D.</span><br />
<span style="line-height: 1.5;">Made Player script to be able to fire spheres into the scene and s</span><span style="line-height: 1.5;">heep script to allow the user to &#8220;kill&#8221; it, by hitting it 3 times.</span></p>
<p><strong>Player script:</strong></p>
<pre class="brush: csharp; gutter: true">    void Update()
    {
        if (Input.GetMouseButtonDown(0))// || Input.GetMouseButton(0))
        { // only do anything when the button is pressed:
            Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
            RaycastHit hit;
            if (Physics.Raycast(ray, out hit, 1000))
            {
                Vector3 handPosition = transform.position;
                handPosition.x += 0.5f;
                GameObject projectile = (GameObject)Instantiate(bullet, handPosition, Quaternion.identity);
                // turn the projectile to hit.point
                projectile.transform.LookAt(hit.point);
                // accelerate it
                projectile.rigidbody.velocity = projectile.transform.forward * 20;
            }
        }
    }</pre>
<p><strong>Sheep Script:</strong></p>
<pre class="brush: actionscript3; gutter: true">  private int hitsLeft = 3;

    void OnCollisionEnter(Collision collision)
    {
        GameObject.Destroy(collision.collider.gameObject);
        hitsLeft -= 1;
        if (hitsLeft &lt;= 0)
        {
            GameObject.Destroy(gameObject);
        }
    }</pre>
<p><span style="line-height: 1.5;"> &#8211; Henning</span></p>
]]></content:encoded>
					
					<wfw:commentRss>https://incd021.com/2013/04/18/dont-fall-asheep-progress-2013-04-18/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Page Caching using Disk: Enhanced 

Served from: incd021.com @ 2025-05-22 04:10:04 by W3 Total Cache
-->