Selected Courses on Digital Art-UOWM

15 Απριλίου 2013

themes-scr

Filed under: Notes — admin @ 13:49














θεματικές στο εργαστήριο
————————————————————————————————————————————————————————————————————————————————————————————————————————————–


speaking lanquages-  

Root Zone Database

The Root Zone Database represents the delegation details of top-level domains, including gTLDs such as.com, and country-code TLDs such as .uk. As the manager of the DNS root zone, IANA is responsible for coordinating these delegations in accordance with its policies and procedures.
Much of this data is also available via the WHOIS protocol at whois.iana.org.
Domain Type Sponsoring Organisation
.ac country-code Network Information Center (AC Domain Registry) c/o Cable and Wireless (Ascension Island)
.ad country-code Andorra Telecom
.ae country-code Telecommunication Regulatory Authority (TRA)
.aero sponsored Societe Internationale de Telecommunications Aeronautique (SITA INC USA)
.af country-code Ministry of Communications and IT
.ag country-code UHSA School of Medicine
.ai country-code Government of Anguilla
.al country-code Electronic and Postal Communications Authority – AKEP
.am country-code Internet Society
.an country-code University of The Netherlands Antilles
.ao country-code Faculdade de Engenharia da Universidade Agostinho Neto
.aq country-code Mott and Associates
.ar country-code Presidencia de la Nación – Secretaría Legal y Técnica
.arpa infrastructure Internet Assigned Numbers Authority
.as country-code AS Domain Registry
.asia sponsored DotAsia Organisation Ltd.
.at country-code nic.at GmbH
.au country-code .au Domain Administration (auDA)
.aw country-code SETAR
.ax country-code Ålands landskapsregering
.az country-code IntraNS
.ba country-code Universtiy Telinformatic Centre (UTIC)
.bb country-code Government of Barbados Ministry of Economic Affairs and Development Telecommunications Unit
.bd country-code Ministry of Post & Telecommunications Bangladesh Secretariat
.be country-code DNS BE vzw/asbl
.bf country-code ARCE-AutoritÈ de RÈgulation des Communications Electroniques
.bg country-code Register.BG
.bh country-code Telecommunications Regulatory Authority (TRA)
.bi country-code Centre National de l’Informatique
.biz generic-restricted NeuStar, Inc.
.bj country-code Benin Telecoms S.A.
.bl country-code Not assigned
.bm country-code Registry General Ministry of Labour and Immigration
.bn country-code Telekom Brunei Berhad
.bo country-code Agencia para el Desarrollo de la Información de la Sociedad en Bolivia
.bq country-code Not assigned
.br country-code Comite Gestor da Internet no Brasil
.bs country-code The College of the Bahamas
.bt country-code Ministry of Information and Communications
.bv country-code UNINETT Norid A/S
.bw country-code University of Botswana
.by country-code Reliable Software Inc.
.bz country-code University of Belize
.ca country-code Canadian Internet Registration Authority (CIRA) Autorite Canadienne pour les Enregistrements Internet (ACEI)
.cat sponsored Fundacio puntCAT
.cc country-code eNIC Cocos (Keeling) Islands Pty. Ltd. d/b/a Island Internet Services
.cd country-code Office Congolais des Postes et Télécommunications – OCPT
.cf country-code Societe Centrafricaine de Telecommunications (SOCATEL)
.cg country-code ONPT Congo and Interpoint Switzerland
.ch country-code SWITCH The Swiss Education & Research Network
.ci country-code INP-HB Institut National Polytechnique Felix Houphouet Boigny
.ck country-code Telecom Cook Islands Ltd.
.cl country-code NIC Chile (University of Chile)
.cm country-code Cameroon Telecommunications (CAMTEL)
.cn country-code Computer Network Information Center, Chinese Academy of Sciences
.co country-code .CO Internet S.A.S.
.com generic VeriSign Global Registry Services
.coop sponsored DotCooperation LLC
.cr country-code National Academy of Sciences Academia Nacional de Ciencias
.cu country-code CENIAInternet Industria y San Jose Capitolio Nacional
.cv country-code Agência Nacional das Comunicações (ANAC)
.cw country-code University of the Netherlands Antilles
.cx country-code Christmas Island Internet Administration Limited
.cy country-code University of Cyprus
.cz country-code CZ.NIC, z.s.p.o
.de country-code DENIC eG
.dj country-code Djibouti Telecom S.A
.dk country-code Dansk Internet Forum
.dm country-code DotDM Corporation
.do country-code Pontificia Universidad Catolica Madre y Maestra Recinto Santo Tomas de Aquino
.dz country-code CERIST
.ec country-code NIC.EC (NICEC) S.A.
.edu sponsored EDUCAUSE
.ee country-code National Institute of Chemical Physics and Biophysics
.eg country-code Egyptian Universities Network (EUN) Supreme Council of Universities
.eh country-code Not assigned
.er country-code Eritrea Telecommunication Services Corporation (EriTel)
.es country-code Red.es
.et country-code Ethio telecom
.eu country-code EURid vzw/asbl
.fi country-code Finnish Communications Regulatory Authority
.fj country-code The University of the South Pacific IT Services
.fk country-code Falkland Islands Government
.fm country-code FSM Telecommunications Corporation
.fo country-code FO Council
.fr country-code AFNIC (NIC France) – Immeuble International
.ga country-code Gabon Telecom
.gb country-code Reserved Domain – IANA
.gd country-code The National Telecommunications Regulatory Commission (NTRC)
.ge country-code Caucasus Online
.gf country-code Net Plus
.gg country-code Island Networks Ltd.
.gh country-code Network Computer Systems Limited
.gi country-code Sapphire Networks
.gl country-code TELE Greenland A/S
.gm country-code GM-NIC
.gn country-code Centre National des Sciences Halieutiques de Boussoura
.gov sponsored General Services Administration Attn: QTDC, 2E08 (.gov Domain Registration)
.gp country-code Networking Technologies Group
.gq country-code GETESA
.gr country-code ICS-FORTH GR
.gs country-code Government of South Georgia and South Sandwich Islands (GSGSSI)
.gt country-code Universidad del Valle de Guatemala
.gu country-code University of Guam Computer Center
.gw country-code Fundação IT & MEDIA Universidade de Bissao
.gy country-code University of Guyana
.hk country-code Hong Kong Internet Registration Corporation Ltd.
.hm country-code HM Domain Registry
.hn country-code Red de Desarrollo Sostenible Honduras
.hr country-code CARNet – Croatian Academic and Research Network
.ht country-code Consortium FDS/RDDH
.hu country-code Council of Hungarian Internet Providers (CHIP)
.id country-code IDNIC-PPAU Mikroelektronika
.ie country-code University College Dublin Computing Services Computer Centre
.il country-code Internet Society of Israel
.im country-code Isle of Man Government
.in country-code National Internet Exchange of India
.info generic Afilias Limited
.int sponsored Internet Assigned Numbers Authority
.io country-code IO Top Level Domain Registry Cable and Wireless
.iq country-code Communications and Media Commission (CMC)
.ir country-code Institute for Research in Fundamental Sciences
.is country-code ISNIC – Internet Iceland ltd.
.it country-code IIT – CNR
.je country-code Island Networks (Jersey) Ltd.
.jm country-code University of West Indies
.jo country-code National Information Technology Center (NITC)
.jobs sponsored Employ Media LLC
.jp country-code Japan Registry Services Co., Ltd.
.ke country-code Kenya Network Information Center (KeNIC)
.kg country-code AsiaInfo Telecommunication Enterprise
.kh country-code Ministry of Post and Telecommunications
.ki country-code Ministry of Communications, Transport, and Tourism Development
.km country-code Comores Telecom
.kn country-code Ministry of Finance, Sustainable Development Information & Technology
.kp country-code Star Joint Venture Company
.kr country-code Korea Internet & Security Agency (KISA)
.kw country-code Ministry of Communications
.ky country-code The Information and Communications Technology Authority
.kz country-code Association of IT Companies of Kazakhstan
.la country-code Lao National Internet Committee (LANIC), Ministry of Posts and Telecommunications
.lb country-code American University of Beirut Computing and Networking Services
.lc country-code University of Puerto Rico
.li country-code Universitaet Liechtenstein
.lk country-code Council for Information Technology LK Domain Registrar
.lr country-code Data Technology Solutions, Inc.
.ls country-code National University of Lesotho
.lt country-code Kaunas University of Technology Information Technology Development Institute
.lu country-code RESTENA
.lv country-code University of Latvia Institute of Mathematics and Computer Science Department of Network Solutions (DNS)
.ly country-code General Post and Telecommunication Company
.ma country-code Agence Nationale de Réglementation des Télécommunications (ANRT)
.mc country-code Gouvernement de Monaco Direction des Communications Electroniques
.md country-code MoldData S.E.
.me country-code Government of Montenegro
.mf country-code Not assigned
.mg country-code NIC-MG (Network Information Center Madagascar)
.mh country-code Cabinet Office
.mil sponsored DoD Network Information Center
.mk country-code Ministry of Foreign Affairs
.ml country-code Agence des Technologies de l’Information et de la Communication
.mm country-code Ministry of Communications, Posts & Telegraphs
.mn country-code Datacom Co., Ltd.
.mo country-code Bureau of Telecommunications Regulation (DSRT)
.mobi sponsored Afilias Technologies Limited dba dotMobi
.mp country-code Saipan Datacom, Inc.
.mq country-code MEDIASERV
.mr country-code University of Nouakchott
.ms country-code MNI Networks Ltd.
.mt country-code NIC (Malta)
.mu country-code Internet Direct Ltd
.museum sponsored Museum Domain Management Association
.mv country-code Dhiraagu Pvt. Ltd. (DHIVEHINET)
.mw country-code Malawi Sustainable Development Network Programme (Malawi SDNP)
.mx country-code NIC-Mexico ITESM – Campus Monterrey
.my country-code MYNIC Berhad
.mz country-code Centro de Informatica de Universidade Eduardo Mondlane
.na country-code Namibian Network Information Center
.name generic-restricted VeriSign Information Services, Inc.
.nc country-code Office des Postes et Telecommunications
.ne country-code SONITEL
.net generic VeriSign Global Registry Services
.nf country-code Norfolk Island Data Services
.ng country-code Nigeria Internet Registration Association
.ni country-code Universidad Nacional del Ingernieria Centro de Computo
.nl country-code SIDN (Stichting Internet Domeinregistratie Nederland)
.no country-code UNINETT Norid A/S
.np country-code Mercantile Communications Pvt. Ltd.
.nr country-code CENPAC NET
.nu country-code The IUSN Foundation
.nz country-code InternetNZ
.om country-code Telecommunications Regulatory Authority (TRA)
.org generic Public Interest Registry (PIR)
.pa country-code Universidad Tecnologica de Panama
.pe country-code Red Cientifica Peruana
.pf country-code Gouvernement de la Polynésie française
.pg country-code PNG DNS Administration Vice Chancellors Office The Papua New Guinea University of Technology
.ph country-code PH Domain Foundation
.pk country-code PKNIC
.pl country-code Research and Academic Computer Network
.pm country-code AFNIC (NIC France) – Immeuble International
.pn country-code Pitcairn Island Administration
.post sponsored Universal Postal Union
.pr country-code Gauss Research Laboratory Inc.
.pro generic-restricted Registry Services Corporation dba RegistryPro
.ps country-code Ministry Of Telecommunications & Information Technology, Government Computer Center.
.pt country-code Fundação para a Computação Científica Nacional
.pw country-code Micronesia Investment and Development Corporation
.py country-code NIC-PY
.qa country-code The Supreme Council of Information and Communication Technology (ictQATAR)
.re country-code AFNIC (NIC France) – Immeuble International
.ro country-code National Institute for R&D in Informatics
.rs country-code Serbian National Register of Internet Domain Names (RNIDS)
.ru country-code Coordination Center for TLD RU
.rw country-code Rwanda Information Communication and Technology Association (RICTA)
.sa country-code Communications and Information Technology Commission
.sb country-code Solomon Telekom Company Limited
.sc country-code VCS Pty Ltd
.sd country-code Sudan Internet Society
.se country-code The Internet Infrastructure Foundation
.sg country-code Singapore Network Information Centre (SGNIC) Pte Ltd
.sh country-code Government of St. Helena
.si country-code Academic and Research Network of Slovenia (ARNES)
.sj country-code UNINETT Norid A/S
.sk country-code SK-NIC, a.s.
.sl country-code Sierratel
.sm country-code Telecom Italia San Marino S.p.A.
.sn country-code Universite Cheikh Anta Diop NIC Senegal
.so country-code Ministry of Post and Telecommunications
.sr country-code Telesur
.ss country-code Not assigned
.st country-code Tecnisys
.su country-code Russian Institute for Development of Public Networks (ROSNIIROS)
.sv country-code SVNet
.sx country-code SX Registry SA B.V.
.sy country-code National Agency for Network Services (NANS)
.sz country-code University of Swaziland Department of Computer Science
.tc country-code Melrex TC
.td country-code Société des télécommunications du Tchad (SOTEL TCHAD)
.tel sponsored Telnic Ltd.
.tf country-code AFNIC (NIC France) – Immeuble International
.tg country-code Cafe Informatique et Telecommunications
.th country-code Thai Network Information Center Foundation
.tj country-code Information Technology Center
.tk country-code Telecommunication Tokelau Corporation (Teletok)
.tl country-code Ministry of Infrastructure Information and Technology Division
.tm country-code TM Domain Registry Ltd
.tn country-code Agence Tunisienne d’Internet
.to country-code Government of the Kingdom of Tonga H.R.H. Crown Prince Tupouto’a c/o Consulate of Tonga
.tp country-code
.tr country-code Middle East Technical University Department of Computer Engineering
.travel sponsored Tralliance Registry Management Company, LLC.
.tt country-code University of the West Indies Faculty of Engineering
.tv country-code Ministry of Finance and Tourism
.tw country-code Taiwan Network Information Center (TWNIC)
.tz country-code Tanzania Network Information Centre (tzNIC)
.ua country-code Communication Systems Ltd
.ug country-code Uganda Online Ltd.
.uk country-code Nominet UK
.um country-code Not assigned
.us country-code NeuStar, Inc.
.uy country-code SeCIU – Universidad de la Republica
.uz country-code Computerization and Information Technologies Developing Center UZINFOCOM
.va country-code Holy See Secretariat of State Department of Telecommunications
.vc country-code Ministry of Telecommunications, Science, Technology and Industry
.ve country-code Comisión Nacional de Telecomunicaciones (CONATEL)
.vg country-code Pinebrook Developments Ltd
.vi country-code Virgin Islands Public Telcommunications System c/o COBEX Internet Services
.vn country-code Ministry of Information and Communications of Socialist Republic of Viet Nam
.vu country-code Telecom Vanuatu Limited
.wf country-code AFNIC (NIC France) – Immeuble International
.ws country-code Government of Samoa Ministry of Foreign Affairs & Trade
.测试 test Internet Assigned Numbers Authority
.परीक्षा test Internet Assigned Numbers Authority
.한국 country-code KISA (Korea Internet & Security Agency)
.ভারত country-code National Internet Exchange of India
.বাংলা country-code Not assigned
.испытание test Internet Assigned Numbers Authority
.қаз country-code Association of IT Companies of Kazakhstan
.срб country-code Serbian National Register of Internet Domain Names (RNIDS)
.테스트 test Internet Assigned Numbers Authority
.சிங்கப்பூர் country-code Singapore Network Information Centre (SGNIC) Pte Ltd
.טעסט test Internet Assigned Numbers Authority
.中国 country-code China Internet Network Information Center
.中國 country-code China Internet Network Information Center
.భారత్ country-code National Internet Exchange of India
.ලංකා country-code LK Domain Registry
.測試 test Internet Assigned Numbers Authority
.ભારત country-code National Internet Exchange of India
.भारत country-code National Internet Exchange of India
.آزمایشی test Internet Assigned Numbers Authority
.பரிட்சை test Internet Assigned Numbers Authority
.укр country-code Ukrainian Network Information Centre (UANIC), Inc.
.香港 country-code Hong Kong Internet Registration Corporation Ltd.
.δοκιμή test Internet Assigned Numbers Authority
.إختبار test Internet Assigned Numbers Authority
.台湾 country-code Taiwan Network Information Center (TWNIC)
.台灣 country-code Taiwan Network Information Center (TWNIC)
.мон country-code Not assigned
.الجزائر country-code CERIST
.عمان country-code Telecommunications Regulatory Authority (TRA)
.ایران country-code Not assigned
.امارات country-code Telecommunications Regulatory Authority (TRA)
.پاکستان country-code Not assigned
.الاردن country-code National Information Technology Center (NITC)
.بھارت country-code National Internet Exchange of India
.المغرب country-code Agence Nationale de Réglementation des Télécommunications (ANRT)
.السعودية country-code Communications and Information Technology Commission
.سودان country-code Not assigned
.مليسيا country-code MYNIC Berhad
.გე country-code Not assigned
.ไทย country-code Thai Network Information Center Foundation
.سورية country-code National Agency for Network Services (NANS)
.рф country-code Coordination Center for TLD RU
.تونس country-code Agence Tunisienne d’Internet
.ਭਾਰਤ country-code National Internet Exchange of India
.مصر country-code National Telecommunication Regulatory Authority – NTRA
.قطر country-code Supreme Council for Communications and Information Technology (ictQATAR)
.இலங்கை country-code LK Domain Registry
.இந்தியா country-code National Internet Exchange of India
.新加坡 country-code Singapore Network Information Centre (SGNIC) Pte Ltd
.فلسطين country-code Ministry of Telecom & Information Technology (MTIT)
.テスト test Internet Assigned Numbers Authority
.xxx sponsored ICM Registry LLC
.ye country-code TeleYemen
.yt country-code AFNIC (NIC France) – Immeuble International
.za country-code ZA Domain Name Authority
.zm country-code ZAMNET Communication Systems Ltd.
.zw country-code Postal and Telecommunications Regulatory Authority of Zimbabwe (POTRAZ)




from wiki

List of programming languages

From Wikipedia, the free encyclopedia
The aim of this list of programming languages is to include all notable programming languages in existence, both those in current use and historical ones, in alphabetical order, except for dialects of BASIC and esoteric programming languages.
Note: Dialects of BASIC have been moved to the separate List of BASIC dialects.
Note: This page does not list esoteric programming languages.

[edit]A

[edit]B

[edit]C

[edit]D

  • D
  • DASL (Datapoint’s Advanced Systems Language)
  • DASL (Distributed Application Specification Language)
  • Dart
  • DataFlex

[edit]E

[edit]F

[edit]G

[edit]H

[edit]I

[edit]J

[edit]K

[edit]L

[edit]M

[edit]N

[edit]O

[edit]P

[edit]Q

[edit]R

[edit]S

[edit]T

[edit]U

[edit]V

[edit]W

[edit]X

[edit]Y

[edit]Z






































JAVA SCRIPT(pro HTML SYNTAX)
web page external -conect with server-js examples provided on line
notes for lessons
(web page developer.moz.)
l01
java script is an object oriented language that is dynamic.
syntax related to C and Java
js does nt have classes – instead object prototypes

java script;s types are

A.numbers

– a js object -allowing numerical values- number object -Number() constructor
new Number(value)
the following example uses the Number object’s properties to assign values to several numeric variables:
var biggestNum = Number.MAX_VALUE;
var smallestNum = Number.MIN_VALUE;
var infiniteNum = Number.POSITIVE_INFINITY;
var negInfiniteNum = Number.NEGATIVE_INFINITY;
var notANum = Number.NaN;


The following example converts the Date object to a numerical value using Number as a function:

var d = new Date("December 17, 1995 03:24:00");

print(Number(d));// print


This displays "819199440000".


*

MAX_VALUE

The largest positive representable number.  The largest negative representable number is -MAX_VALUE.
MIN_VALUE
The smallest positive representable number -- that is, the positive number closest to zero (without actually being zero).  The smallest negative representable number is -MIN_VALUE.
NaN
Special "not a number" value.
NEGATIVE_INFINITY
Special value representing negative infinity; returned on overflow.
POSITIVE_INFINITY
Special value representing infinity; returned on overflow.
prototype
Allows the addition of properties to a Number object.
strings


charAt method

1.

 return ‘cat’.charAt(1)://returns “a”
return ‘cat”[1]:// returns”a”



c-strcmp()fuctin *
var a= “a”;
var b = “b” ;
if (a<b)
print (a+”is less than” +b);
else if (a>b)
print (a +”is greater than ” +b);
else 
print (a + “and”+b+”are equal.”);



string objects-string values

var s_prim=- “foo”:
var s_obj = new String (s_prim);
console.log(typeof s_prim); // logs string
console.log(typeof s_obj);// Logs ‘objects’









s1 = "2 + 2";               // creates a string primitive
s2 = new String("2 + 2");   // creates a String object
console.log(eval(s1));      // returns the number 4
console.log(eval(s2));      // returns the string "2 + 2"

valueOf method-convert a string object to its primitive counterpart
console.log(eval(s2.value)f())); // returns the number 4


properties of string instances —methods —methods of string instances

String generic methods

Generics are also available on Array methods.
var num = 15;
alert(String.replace(num, /5/, '2'));



/*globals define*/
// Assumes all supplied String instance methods already present (one may use shims for these if not available)
(function () {
    'use strict';
    var i,
        // We could also build the array of methods with the following, but the
        //   getOwnPropertyNames() method is non-shimable:
        // Object.getOwnPropertyNames(String).filter(function (methodName) {return typeof String[methodName] === 'function'});
        methods = [
            'quote', 'substring', 'toLowerCase', 'toUpperCase', 'charAt',
            'charCodeAt', 'indexOf', 'lastIndexOf', 'startsWith', 'endsWith',
            'trim', 'trimLeft', 'trimRight', 'toLocaleLowerCase',
            'toLocaleUpperCase', 'localeCompare', 'match', 'search',
            'replace', 'split', 'substr', 'concat', 'slice', 'fromCharCode'
        ],
        methodCount = methods.length,
        assignStringGeneric = function (methodName) {
            var method = String.prototype[methodName];
            String[methodName] = function (arg1) {
                return method.apply(arg1, Array.prototype.slice.call(arguments, 1));
            };
        };
    for (i = 0; i < methodCount; i++) {
        assignStringGeneric(methods[i]);
    }
}());



string instances-methods- non-native methods





3booleans




4fuctions




objects


number 



string



boolean



object





















example of a bounce game
analyze the code and underline the following 
fuctions
variables
objects







ex    game page





uowm2013-1lesson-javascript lanqauge code
















// explanations about i frme -examples 14years old Nyegen Phong, 

-change the gameHeight and gameWidth variables
-change the height and width attributes
 iframe.game class, in the style of the index page


//asigning variables
var gameHeight = 320
var gameWidth = 360

var intervalOne,intervalTwo,timeoutOne,x
var angle = 2
var tempX = 0
var tempY = 0
var block = 1
var square = 0
var squareTop = 0
var squareLeft = 0
var squareMotion = 1
var speed = 80
var getPad = 0
var nextScore = 0
var score = 0
var count = 0
var collisionOne = 0
var collisionTwo = 0
var collisionThree = 0


document.body.style.margin = “0px”
document.body.style.padding = “0px”

function setupGame()                                                                                     // about fuctions, doc., pad L.T,R,…
{
document.getElementById(“game”).style.borderRight = “1px solid #aaa”
document.getElementById(“game”).style.borderRight = “1px solid #aaa”
document.getElementById(“game”).style.borderBottom = “1px solid #aaa”
document.getElementById(“game”).style.width = gameWidth+”px”
document.getElementById(“game”).style.height = gameHeight+”px”
document.getElementById(“square0”).style.position = “absolute”
document.getElementById(“square0”).style.width = “40px”
document.getElementById(“square0”).style.height = “40px”
document.getElementById(“square0”).style.backgroundColor = “#444”
document.getElementById(“square0”).style.display = “none”
document.getElementById(“square1”).style.position = “absolute”
document.getElementById(“square1”).style.width = “40px”
document.getElementById(“square1”).style.height = “40px”
document.getElementById(“square1”).style.backgroundColor = “#444”
document.getElementById(“square1”).style.display = “none”
document.getElementById(“pad”).style.position = “absolute”
document.getElementById(“pad”).style.width = “60px”
document.getElementById(“pad”).style.height = “30px”
document.getElementById(“pad”).style.paddingTop = “10px”
document.getElementById(“pad”).style.textAlign = “center”
document.getElementById(“pad”).style.font = “15px Verdana, sans-serif”
document.getElementById(“pad”).style.backgroundColor = “#000”
document.getElementById(“pad”).style.color = “#fff”
document.getElementById(“pad”).innerHTML = “PLAY
document.getElementById(“play”).style.color = “#fff”
document.getElementById(“play”).style.textDecoration = “none”

padTop = Math.floor(gameHeight/2)-20
padLeft = Math.floor(gameWidth/2)-30

document.getElementById(“pad”).style.top = padTop+”px”
document.getElementById(“pad”).style.left = padLeft+”px”

document.getElementById(“notepad”).innerHTML = “BounceGame”
document.getElementById(“notepad”).style.padding = “10px”
document.getElementById(“notepad”).style.textAlign = “center”
document.getElementById(“notepad”).style.font = “2.0em Georgia, serif”
document.getElementById(“notepad”).style.fontWeight = “normal”
document.getElementById(“notepad”).style.color = “#222”

timeoutOne = setTimeout(“intervalTwo = setInterval(‘demoGame()’, speed)”, 4000)
}

function demoGame()
{
angle = 2
clearTimeout(timeoutOne)
document.getElementById(“square0”).style.display = “block”
document.getElementById(“square1”).style.display = “block”

if(square == 0)
{
x = document.getElementById(“square0”)
square = 1
}
else
{
x = document.getElementById(“square1”)
square = 0
}

bounceGame()
}

function newGame()
{
block = 0
angle = 2
tempX = 0
tempY = 0
square = 0
squareTop = 0
squareLeft = 0
squareMotion = 1
nextScore = 0
score = 0
count = 0
collisionOne = 0
collisionTwo = 0
collisionThree = 0

clearTimeout(timeoutOne)
clearInterval(intervalOne)
clearInterval(intervalTwo)
document.getElementById(“square0”).style.left = “0px”
document.getElementById(“square0”).style.top = “0px”
document.getElementById(“square0”).style.display = “block”
document.getElementById(“square1”).style.left = “0px”
document.getElementById(“square1”).style.top = “0px”
document.getElementById(“square1”).style.display = “block”
document.getElementById(“pad”).style.top = (gameHeight-40)+”px”
document.getElementById(“pad”).innerHTML = “”
document.getElementById(“notepad”).innerHTML = “”

intervalOne = setInterval(“playGame()”, speed) 
}

function playGame()
{
if(block)
{
return
}

if(square == 0)
{
x = document.getElementById(“square0”)
square = 1
}
else
{
x = document.getElementById(“square1”)
square = 0
}

bounceGame()
checkCollision()
}

function assignM(aM)
{
squareMotion = aM
}

function bounceGame()
{
if(squareMotion==1)

if(squareTop>=(gameHeight-40) && squareLeft>=(gameWidth-40))
{
assignM(3)
moveDR(-40)
}

if(squareTop>=(gameHeight-40)) 

assignM(2)
moveDL(-40)

else if(squareLeft>=(gameWidth-40))
{
assignM(4)
moveDL(40)
}
else {
moveDR(40)
}
}
else if(squareMotion==2)
{
if(squareTop=(gameWidth-40))
{
assignM(4)
moveDL(40)
}

if(squareLeft>=(gameWidth-40))
{
assignM(3)
moveDR(-40)

else if(squareTop<=0)
{
assignM(1)
moveDR(40)
}
else
{
moveDL(-40)
}
}
else if(squareMotion==3)
{
if(squareTop<=0 && squareLeft<=0)
{
assignM(1)
moveDR(40)
}

if(squareTop<=0)
{
assignM(4)
moveDL(40)

else if(squareLeft<=0)
{
assignM(2)
moveDL(-40)
}
else
{
moveDR(-40)
}
}
else if(squareMotion==4)
{
if(squareTop>=(gameHeight-40) && squareLeft<=0)
{
assignM(2)
moveDL(-40)
}

if(squareLeft<=0)
{
assignM(1)
moveDR(40)

else if(squareTop>=(gameHeight-40))
{
assignM(3)
moveDR(-40)
}
else
{
moveDL(40)
}
}
}

function moveDR(amount)

save = amount
amount = Math.floor(amount/angle)

if(angle == 0)
{
amount = 0
}

squareLeft += amount 
x.style.left = squareLeft+”px”
squareTop += save 
x.style.top = squareTop+”px”
}

function moveDL(amount)
{
save = amount
amount = Math.floor(amount/angle)

if(angle == 0)
{
amount = 0
}

squareLeft -= amount 
x.style.left = squareLeft+”px”
squareTop += save 
x.style.top = squareTop+”px”
}

function assignAngle(aa)
{
if(aa==1)
{
angle = 0
nextScore = 1000
}
if(aa==2)
{
angle = 2
nextScore = 100
}

score += nextScore

document.getElementById(“pad”).innerHTML = nextScore
}

function flashScore()
{
if(score > 0)
{
if(nextScore == “BounceGame”)
{
nextScore = score
}
else
{
nextScore = “BounceGame”
}

document.getElementById(“notepad”).innerHTML = nextScore
}
else
{
document.getElementById(“notepad”).innerHTML = “BounceGame”
}
}

function countUp()
{
if(count < (Math.floor(score/10)*8))
{
count += Math.floor(score/10)
}
else if(count >= (Math.floor(score/10)*8) && count <= (Math.floor(score/10)*9))
{
if((Math.floor(score/10)*9) > 200)
{
count += Math.floor(score/10)
}
else
{
count += 10
}
}
else
{
if(Math.floor(score/10) > 30)
{
count += 10
}
else
{
count += 1
}
}

if(count > score)
{
count = score
clearInterval(intervalOne)
intervalOne = setInterval(“flashScore()”, 2000) 
}

document.getElementById(“notepad”).innerHTML = count
}

function checkCollision()
{
var actualLeft = getPad-30

if(squareTop == 0)
{
document.getElementById(“pad”).innerHTML = “”
}

if((squareTop+40)==(gameHeight-40))
{
difference = Math.floor(squareLeft-actualLeft)

if(difference>=(-39)&&difference<4)
{
collisionOne++
collisionTwo = 0
collisionThree = 0

if(collisionOne > 3)
{
assignM(Math.floor(Math.random() * 2) + 2)
}
else
{
assignM(3)
}

assignAngle(2)
}
else if(difference>=5&&difference<15)
{
collisionOne = 0
collisionTwo++
collisionThree = 0

if(collisionTwo > 3)
{
assignM(Math.floor(Math.random() * 2) + 2)
assignAngle(2)
}
else
{
assignM(3)
assignAngle(1)
}
}
else if(difference>=15&&difference<59)
{
collisionOne = 0
collisionTwo = 0
collisionThree++

if(collisionThree > 3)
{
assignM(Math.floor(Math.random() * 2) + 2)                                      // examples by math creativity-flash creativity paul-
}
else
{
assignM(2)
}

assignAngle(2)
}
}
else if((squareTop+40)==gameHeight)
{
block = 1
clearInterval(intervalOne)
setupGame()
intervalOne = setInterval(“countUp()”, speed) 
}
}

function getMouseXY(e)
{
if(navigator.appName==”Netscape”)
{  
tempX = e.pageX
tempY = e.pageY
}  
else

tempX = event.clientX + document.body.scrollLeft
tempY = event.clientY + document.body.scrollTop
}

if(tempX < 0)
{
tempX = 0


getPad = tempX

if(getPad <= 30)
{
getPad = 30
}

if((getPad-30) > Math.floor(gameWidth-60))
{
getPad = Math.floor(gameWidth-60)+30
}

if(!block)
{
document.getElementById(“pad”).style.left = (getPad-30)+”px”
}

}

document.onmousemove = getMouseXY

setupGame()








Δεν υπάρχουν Σχόλια

  1. Nice Posting

    Σχόλιο by Ridwan Fauzi — 20 Ιουνίου 2019 @ 03:52

  2. good post, this really helps me

    Σχόλιο by Ridwan Fauzi — 20 Ιουνίου 2019 @ 05:38

RSS feed for comments on this post.

Sorry, the comment form is closed at this time.

Powered by WordPress

error: Content is protected !!