@ron michael khu
Hahahahahha ...ron, grabe wala pa gyud ka ni give up sa game of generals. Ka
remember ko sauna nag himo ka og imong own socket server sa gnu c and himo
pa gyud ka og command line og fully functional na ncruses na game of
generals that one of our instructors commented on(teehee!) Bisan imong
computer walay hardisk nga 286 hala sigi banat. Hantod karon sigi pa gihapon
ka anang game of generals!!! Hahaha! Naa pa sa balay ang imong carton na
cover sa board daan na kaayo! wa pa nimo gi kuha. hehehehe...

wegeg!

Anyway ang actionscript 3.0 mejo ga padulong na sa bag-o na coding style,
katong mga types naa na gyud diha. gipa klaro na ang katag. pero ang mga
daan, mejo pwede pa. maybe sa AS or AS2 pwede pa maka ikyas. Sa flex ron,
wala koy ma sulti kay di ko gagamit zero balance ko ana, utangan pa gyud.
Animator raman intawon ko, di man ko gahi. hehehe. La pa ko nag try pud sa
flex. ako trabaho intawon puros lang man php so mejo mao na lang gyud ni
akong magamit always. ang div bun-og na kaayo. mao ra ma daog-daog.
xmlhttprequest pa gyud. hehehe. and wala pud koy hanaw sa python, pero gusto
ko mag try.

pero kanang flash na sockets, akong ga buhaton kay katong lahi na style.
from flash, gamit lang ko og xmlsocket, then akong ipa communicate with a
socket server either c or php sockets. pwede plain bisan unsa agi na format,
like xml or json pero ang tinuod plain text ra gud, hehe,then mag hulat lang
ko if naa activity and then ayha ra mo lihok pag naa na. if naa sa lahi na
domain ang ga access, ako nalang gina butang ang iyang domain inside my
crossdomain.xml para pasudlon.pero kabasa ko peligro ning ingon ani. testing
raman hinuon.

sa modal window wa pud ko kabalo, ang akong na try,nag buhat man kog
animation isulod nakog isa ka movie clip then i load nako as a window. mejo
ilad ra nuon. sapawan ra para di ma hilabtan ang naa sa background. more
like kanang javascript na Lightbox2 not a real one. the background elements
are not really stopping, pero pwede ka mag code nasab para buhaton just
that. mao rana ako na try.

kung katong sa html and javascript and flash communication, akong ga buhaton
is ga setup lang ko og FSCommand sa flash and isa ka FSCommand na tig handle
or tig dawat from within the html page. Sa javascript cya, so from there,
pwede na nako ma padad-an ang akong html og updates gikan sa akong flash.
katong function na mo dawat sa mga gikan sa flash, pwede to nga mo exec na
pud og daghan updates sa html na mga divs, mo run og isa ka ajax call, or
attach or detach og node or dahon sa dom na kahoy or unsa ba. will work with
other js libraries etc. Pwede ka mag mootools, jquery, prototype,
scriptaculous, etc. Ang user input comes from the swf then adto sa server.
then from the server, ang reply, gina pasa using FSCommand paingon sa html
javascript. Mao to kintabi ang handler. Pwede na dayon ma control ang DOM
tungod naa naman to.

ang xmlsocket deadma kung di sakto ang end of string gpadala from a stream
socket.

kung basic lang, for starters, di man pud nuon kaayo grabe ka strikto nga mo
error nalang tanan ang flash. bisan sa adobe flash CS3 professional, pwede
man ka maka butang og isa ka dynamic text box, and assign it an instance
name na *txt* and variable name na *txt*
then sa isa ka frame, mag add kag actionscript (F9) nga something like this

var hello = 'world';
     _root.txt = hello;

then CTRL+enter to check. pag test nimo, mo work cya. pero ma gubot gyud ang
kalibutan sa code kung inana tanan. hehehe. from flash 4 paingon sa mx2004,
pwede 'kaayo' ingana ang style. ang naka tabla lang ana na sample kay
attached ang variable sa isa ka object, and kung imo cyang i access, imo
gyud na kwaon cya og asa cya na level na load.kani, dali raman kay naa sa
root. and ok lang if that's what you really need. pero og nasulod nani kun
asa na dapit na movieclip mrag taas na or samot na ka libog.pero acceptable
gyapon and mo work pud cya.

pag mag code, estimate lang gyud cguro nato kun unsa gyud na functionalities
gi kinahanglan. pwede man ka mo gamit og mas daan na coding style kung
ganahan ka. isupport na sa mas ubos na player paingon sa bag-o. Kung mas
bag-o pud ka, naa ka access mas bag-o na mga functionalities and features
pero sa daan mejo mo wigig gamay. Anyhow, sakto si ron, mas maayo na ang
code nga limpyo og mas han-ay. Makatabang sa mosunoray og code og sa nag
code mismo kung maka limot na cya! Hahahahaha!!!!


On Nov 8, 2007 6:27 AM, Ron Michael Khu <[EMAIL PROTECTED]> wrote:

> Mungkey wrote:
> > >Ga follow raman gyapon ang flash actionscript sa ECMAScript. Kanang
> ECMA-262 specification sa javascript parehas ra halos tanan sa
> Actionscript. Same >>syntax and coding style, but dili DOM ang gina
> control, but flash elements like library items, buttons, movieclip
> instances, frames and other objects na gi offer sa >>Actionscript.
>
> OT:
> lisod man diay ni ang actionscript, mungkey, in the sense na kung ma
> anad ka sa mga semi-all powerful div
> na pwede nimo maski asa-ipapikit, mag lisod ka positioning sa mga
> elements sa flex kay kilanlan pa ka ug encompassing
> canvass.
>
> currently, ga himo ko ug game of the generals via flex. Wala ko atong
> editor kay dili free, so mano-mano. Sus,
> abi nako same sa javascript na dili type-based, medyo strongly typed man
> diay ang actionscript.  Good thing, naay DOM
> pud ang actiionscript/flex so sige nalang ko appendchild.
>
> naa tips mungkey para sa positioning?
>
> -------------------------------------
> asynchronous pud diay ni ang Alerts sa actioinscript, abi nako parehas
> sa javascript
> na modal in the sense na dili ma execute ang code below the alert if
> dili mawala ang dialog.
>
> Mungkey and other ppl,
> basin naa mo balan way para mahimong true-modal ni ang alert.show() in
> the sense, na ang code below
> the alert.show will not get executed unless the dialog is closed.
>
> -------------------------------------
>
> hapit lagi ko napahamak aning adobe flex. gi brute force nalang nako ang
> pag butang ug coordinates mismo sa mxml.
> gusto unta nako naa ang mga details sa css.
>
> initially, gusto ko javascript ang board ang then naa lang dayun gamay
> na flash app generated via flex na mo contain sa
> socket.. na ilad man gud ko atong Alert.show(), abi nako modal. Murag
> alert + glasspane man gud, na entice gyud ko.
> so gi pure flex nalang gyud nako ang client app.
>
> -------------------------------------
> Naa pa gyud kaning evil policy-file request kung mo gamit ka sa socket
> sa actionscript/flex; abi nako naay bug sa python
> or sa netstat kay naay established na connection pero dili ma trigger
> ang connect-event handler sa flex.
>
> Although for security purposes ni ang policy-file request. Evil ni cya
> in the sense kay wala gyud gi indicate didto
> sa sockets na api na naay diay lain connection, aside sa explicit
> connect na buhaton sa programmer, i-open ang socket api
> to request a policy file from the server.
>
> ------------------------------------
>
> Taas na ni na inquiry email, attached diay ang server and client sa game
> of the generals.
> dili pa ni bug-free, ha. Ipa opensource tingali nako ni kung ma
> girl-code na ang tanan,
> kay basin kataw-an lang ta sa gubot na code...
>
> Kung naa mo time, basin pwede mo serve as testers or reviewers sa source
> code.
>
> to run the server, u will need python: python server.py
> to run the client, u will need flash 9: gg.swf  (the rest, kay source
> files lang)
>
>
>
>
> _________________________________________________
> Kagay-Anon Linux Users' Group (KLUG) Mailing List
> [email protected] (http://cdo.linux.org.ph)
> Searchable Archives: http://archives.free.net.ph
>



-- 



--
Live free. Love free.
http://mungkey.deviantart.com
http://mungkey.blogspot.com
_________________________________________________
Kagay-Anon Linux Users' Group (KLUG) Mailing List
[email protected] (http://cdo.linux.org.ph)
Searchable Archives: http://archives.free.net.ph

Reply via email to