Welcome to SomaliNet Forums, a friendly and gigantic Somali centric active community. Login to hide this block

You are currently viewing this page as a guest. By joining our community you will have the ability to post topics, ask questions, educate others, use the advanced search, subscribe to threads and access many, many other features. Registration is quick, simple and absolutely free. Join SomaliNet forums today! Please note that registered members with over 50 posts see no ads whatsoever! Are you new to SomaliNet? These forums with millions of posts are just one section of a much larger site. Just visit the front page and use the top links to explore deep into SomaliNet oasis, Somali singles, Somali business directory, Somali job bank and much more. Click here to login. If you need to reset your password, click here. If you have any problems with the registration process or your account login, please contact us.

LONG SERIES OF HTML5 GAMES: chapter1 part2

Qaybta Xirfada Sayniska iyo iwm

Moderators: Moderators, Junior Moderators

OUR SPONSOR: LOGIN TO HIDE
User avatar
afisoone
SomaliNet Super
SomaliNet Super
Posts: 5490
Joined: Wed Jul 22, 2009 9:46 pm
Location: We all want to become president even though Amisom controls Mogadishu

LONG SERIES OF HTML5 GAMES: chapter1 part2

Postby afisoone » Fri May 22, 2015 11:33 am

Now we have to create Object.js file and save it inside chapter1.
---------------------------------------------------------------------------------------------
Ok. now open your notepad and let's put stuff on Object.js
------------------------------------------------------------------------------
Game kasto oo lasuubiyo waxaa u baahantahay object adigoo u isticmaalaya sida template...

now we need to create object template....

------------------------------------------------------------------------------------
Hada waxaan suubisaneen variable object magaciisana waxaan u bixineeynaa sawirObject.. ok..
var sawirObject={


};
That is easy: Now we need to add some properties in this sawirObject. Waxaan u bahaanahay inaa qeexno afar shay.
1. sawirka width
2. sawirka height
3. sawirka x
4. sawirka y
ok. Now let add those properties...
--------------------------------------------------------------
var sawirkObject={
sawirWidth:148,
sawirHeight:104,
sawirX:0,
sawirY:0


};
Beautiful: As you can see markaad suubineeysid properties wax u dhaxeeysineeysa coma. Also width iyo height tiradaan siiyay waa sawirka aan isticmaali doona ayaa sizekiisa ah. adiga waa badeli kartaa hadii uu ka duwanyahay.
waxaan u baahanahay inaa ku darno sawirObject width iyo height iy x iyo y uu canvas uu siin doon.
let' add that one now.
var sawirkObject={
sawirWidth:148,
sawirHeight:104,
sawirX:0,
sawirY:0,
width:148,
height:104,
x:0,
y:0


};
Beautiful: We have complete sawirObject. Now before plugin to our image. Waa inaa xafidanaa shaykasto aan kasuubineeyno sawirObject. Maxaa yeelay canvas wax ma xafido.
Waxaan rabnaa sawiro ka badan hal inaa soo galino canvaska sideen u xafidnaa variableka sawirObject?
Su'aashashaa waan ka jawaabi doonaa casharki soo socdo.....

Inshallah!

<<Previous lesson

User avatar
afisoone
SomaliNet Super
SomaliNet Super
Posts: 5490
Joined: Wed Jul 22, 2009 9:46 pm
Location: We all want to become president even though Amisom controls Mogadishu

Re: LONG SERIES OF HTML5 GAMES: chapter1 part2

Postby afisoone » Fri May 22, 2015 4:15 pm

Now we have to create Object.js file and save it inside chapter1.
---------------------------------------------------------------------------------------------
Ok. now open your notepad and let's put stuff on Object.js
------------------------------------------------------------------------------
Game kasto oo lasuubiyo waxaa u baahantahay object adigoo u isticmaalaya sida template...

now we need to create object template....

------------------------------------------------------------------------------------
Hada waxaan suubisaneen variable object magaciisana waxaan u bixineeynaa sawirObject.. ok..
var sawirObject={


};
That is easy: Now we need to add some properties in this sawirObject. Waxaan u bahaanahay inaa qeexno afar shay.
1. sawirka width
2. sawirka height
3. sawirka x
4. sawirka y
ok. Now let add those properties...
--------------------------------------------------------------
var sawirObject={
sawirWidth:148,
sawirHeight:104,
sawirX:0,
sawirY:0


};
Beautiful: As you can see markaad suubineeysid properties wax u dhaxeeysineeysa coma. Also width iyo height tiradaan siiyay waa sawirka aan isticmaali doona ayaa sizekiisa ah. adiga waa badeli kartaa hadii uu ka duwanyahay.
waxaan u baahanahay inaa ku darno sawirObject width iyo height iy x iyo y uu canvas uu siin doon.
let' add that one now.
var sawirObject={
sawirWidth:148,
sawirHeight:104,
sawirX:0,
sawirY:0,
width:148,
height:104,
x:0,
y:0


};
Beautiful: We have complete sawirObject. Now before plugin to our image. Waa inaa xafidanaa shaykasto aan kasuubineeyno sawirObject. Maxaa yeelay canvas wax ma xafido.
Waxaan rabnaa sawiro ka badan hal inaa soo galino canvaska sideen u xafidnaa variableka sawirObject?
Su'aashashaa waan ka jawaabi doonaa casharki soo socdo.....

Inshallah!

<<Previous lesson
mistake just happened.. Make sure it is sawirObject..


OUR SPONSOR: LOGIN TO HIDE

Hello, Has your question been answered on this page? We hope yes. If not, you can start a new thread and post your question(s). It is free to join. You can also search our over a million pages (just scroll up and use our site-wide search box) or browse the forums.

  • Similar Topics
    Replies
    Views
    Last post

Return to “Careers - Engineering, Science & Computers”

Who is online

Users browsing this forum: No registered users and 3 guests