{"author_name":"lurkingshadow","cat":"LD #23","comments":[],"epoch":1335086640,"likes":0,"metadata":{"p_key":"57011","p_author":"lurkingshadow","p_authorkey":"8145","p_urlkey":"92760","p_title":"day 2 \u2013 behind but looking good","p_cat":"LD #23","p_event":"LD23","p_time":"1335086640","p_likes":"0","p_comments":"0","p_status":"UPD5","us_key":"8145","us_name":"lurkingshadow","us_username":"lurkingshadow","event_start":"1334880000","event_key":"10","event_name":"LD23"},"text":"<p>so its the end of day 2. heres some code and what 1 of the worlds will look like (thanks to @justjarrodyo)<\/p>\n <p><a href=\"http:\/\/www.ludumdare.com\/compo\/2012\/04\/22\/day-2-behind-but-looking-good\/day2-2\/\" rel=\"attachment wp-att-130207\"><img class=\"alignnone size-full wp-image-130207\" src=\"http:\/\/www.ludumdare.com\/compo\/wp-content\/uploads\/2012\/04\/day2.jpg\" alt=\"\" width=\"2646\" height=\"1024\" srcset=\"http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/04\/day2-300x116.jpg 300w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/04\/day2-550x212.jpg 550w, http:\/\/ludumdare.com\/compo\/wp-content\/uploads\/2012\/04\/day2.jpg 2646w\" sizes=\"(max-width: 2646px) 100vw, 2646px\" \/><\/a>\u00a0i\u00a0might get up\u00a0 round 5 and continue, will work after school anyway and finish this thing of all i need to now is chuck in the levels (plus code them) add a diary , rewards , credit and help wow i am behind oh will ill still do it<\/p>\n <p>&nbsp;<\/p>\n <p>btw here is the full code so far<\/p>\n <blockquote><p>import flash.events.MouseEvent;<\/p>\n <p>\/\/at start<br \/>\n stop();<br \/>\n var $hasitbeen:String;<\/p>\n <p>\/\/vars<br \/>\n if ($hasitbeen != &#8220;yup&#8221;) {<br \/>\n var $lastworld:Number = 0;<br \/>\n var $currentS:Number = 0;<br \/>\n var $totalS:Number = 0;<br \/>\n var $credits:Number = 0;<br \/>\n var $karmaLV:Number = 0;<br \/>\n var $karmaTP:Number = 0;<br \/>\n $hasitbeen = &#8220;yup&#8221;;<br \/>\n };<br \/>\n var $slavePrice:Number = Math.ceil(((Math.random() * 10) + 5));<\/p>\n <p>\/\/displayinboxes<br \/>\n txt_trade.text = String($slavePrice);<br \/>\n txt_release.text = String(&#8220;10&#8221;);<br \/>\n txt_survivors.text = String($currentS);<br \/>\n txt_credits.text = String($credits);<br \/>\n txt_karmaLv.text = String($karmaLV);<br \/>\n txt_karmaTp.text = String($karmaTP);<br \/>\n \/\/cons<br \/>\n \/\/evt listeners<br \/>\n btn_newWorld.addEventListener(MouseEvent.CLICK, newWorld);<br \/>\n btn_tradeS.addEventListener(MouseEvent.CLICK, tradeS);<br \/>\n btn_releaseS.addEventListener(MouseEvent.CLICK, releaseS);<br \/>\n btn_diary.addEventListener(MouseEvent.CLICK, diary);<br \/>\n btn_rewards.addEventListener(MouseEvent.CLICK, rewards);<br \/>\n btn_help.addEventListener(MouseEvent.CLICK, help);<br \/>\n btn_credits.addEventListener(MouseEvent.CLICK, credits);<\/p>\n <p>\/\/functions<br \/>\n function newWorld(evt:MouseEvent):void{<\/p>\n <p>};<br \/>\n function tradeS(evt:MouseEvent):void{<br \/>\n if ($currentS &gt; 0) {<br \/>\n $currentS = $currentS &#8211; 1;<br \/>\n $credits = $credits + $slavePrice;<br \/>\n $karmaLV = $karmaLV + 1;<br \/>\n $karmaTP = $karmaTP &#8211; 1;<br \/>\n trace($currentS);<br \/>\n trace($credits);<\/p>\n <p>txt_trade.text = String($slavePrice);<br \/>\n txt_release.text = String(&#8220;10&#8221;);<br \/>\n txt_survivors.text = String($currentS);<br \/>\n txt_credits.text = String($credits);<br \/>\n txt_karmaLv.text = String($karmaLV);<br \/>\n txt_karmaTp.text = String($karmaTP);<br \/>\n }<\/p>\n <p>};<br \/>\n function releaseS(evt:MouseEvent):void{<br \/>\n if ($currentS &gt; 0) {<br \/>\n $currentS = $currentS -1;<br \/>\n $credits = $credits + 10;<br \/>\n $karmaLV = $karmaLV + 1;<br \/>\n $karmaTP = $karmaTP + 1;<br \/>\n trace($currentS);<br \/>\n trace($credits);<\/p>\n <p>txt_trade.text = String($slavePrice);<br \/>\n txt_release.text = String(&#8220;10&#8221;);<br \/>\n txt_survivors.text = String($currentS);<br \/>\n txt_credits.text = String($credits);<br \/>\n txt_karmaLv.text = String($karmaLV);<br \/>\n txt_karmaTp.text = String($karmaTP);<br \/>\n }<br \/>\n };<br \/>\n function diary(evt:MouseEvent):void{<\/p>\n <p>};<br \/>\n function rewards(evt:MouseEvent):void{<\/p>\n <p>};<br \/>\n function help(evt:MouseEvent):void{<\/p>\n <p>};<br \/>\n function credits(evt:MouseEvent):void{<\/p>\n <p>};<\/p><\/blockquote>\n <p>btw this is my first as3 game \ud83d\ude1b thanks for reding<\/p>\n <blockquote><p>&nbsp;<\/p><\/blockquote>","time":"April 22nd, 2012 4:24 am","title":"day 2 \u2013 behind but looking good"}