textField invisible

View: New views
3 Messages — Rating Filter:   Alert me  

textField invisible

by Jean-Christophe CORNIC :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello, i'm new using mtasc and i have a problem.
 
I'm using windows 2000, eclipse and mtasc to compile my swf project with AS2.
 
I'm trying to make the first tutorial (hello world) but it displays a white window without text...
 
This is my code Hello.as
class Hello{
public function Hello(){
// createEmptyMovieClip = MovieClip.prototype.createEmptyMovieClip;
_root.createTextField("textField",0,0,150,40);
_root.textField.text = "Hello World";
}
static public function main(){
var m = new Hello();
}
}
 
This is my console code
 
C:\flashOS\mtasc\mtasc.exe -main -version 8 -header 320:300:25 -swf "C:\flashOS\workspace\hello world\src\Hello.swf" "C:\flashOS\workspace\hello world\src\Hello.as"
 
IT creates a Hello.swf witch displays a white screen, no texte out...
 
Thx for help
 
++
JC
 
 


Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail
--
MTASC : no more coffee break while compiling

Re: textField invisible

by Luke Schreur-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

createTextField takes 6 parameters where the second is the depth on which to place the TextField.

_root.createTextField("textField",_root.getNextHighestDepth(),0,0,150,40);

- Luke


On 01/12/2007, at 7:11 PM, Jean-Christophe CORNIC wrote:

Hello, i'm new using mtasc and i have a problem.
 
I'm using windows 2000, eclipse and mtasc to compile my swf project with AS2.
 
I'm trying to make the first tutorial (hello world) but it displays a white window without text...
 
This is my code Hello.as
class Hello{
public function Hello(){
// createEmptyMovieClip = MovieClip.prototype.createEmptyMovieClip;
_root.createTextField("textField",0,0,150,40);
_root.textField.text = "Hello World";
}
static public function main(){
var m = new Hello();
}
}
 
This is my console code
 
C:\flashOS\mtasc\mtasc.exe -main -version 8 -header 320:300:25 -swf "C:\flashOS\workspace\hello world\src\Hello.swf" "C:\flashOS\workspace\hello world\src\Hello.as"
 
IT creates a Hello.swf witch displays a white screen, no texte out...
 
Thx for help
 
++
JC
 
 


Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail

Click here to report this email as spam.

-- 
MTASC : no more coffee break while compiling





--
MTASC : no more coffee break while compiling

RE : Re: textField invisible

by Jean-Christophe CORNIC :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thx, it works fine now ;)
 
++
JC

Luke Schreur <luke.schreur@...> a écrit :
Hi,

createTextField takes 6 parameters where the second is the depth on which to place the TextField.

_root.createTextField("textField",_root.getNextHighestDepth(),0,0,150,40);

- Luke


On 01/12/2007, at 7:11 PM, Jean-Christophe CORNIC wrote:

Hello, i'm new using mtasc and i have a problem.
 
I'm using windows 2000, eclipse and mtasc to compile my swf project with AS2.
 
I'm trying to make the first tutorial (hello world) but it displays a white window without text...
 
This is my code Hello.as
class Hello{
public function Hello(){
// createEmptyMovieClip = MovieClip.prototype.createEmptyMovieClip;
_root.createTextField("textField",0,0,150,40);
_root.textField.text = "Hello World";
}
static public function main(){
var m = new Hello();
}
}
 
This is my console code
 
C:\flashOS\mtasc\mtasc.exe -main -version 8 -header 320:300:25 -swf "C:\flashOS\workspace\hello world\src\Hello.swf" "C:\flashOS\workspace\hello world\src\Hello.as"
 
IT creates a Hello.swf witch displays a white screen, no texte out...
 
Thx for help
 
++
JC
 
 


Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail

Click here to report this email as spam.
-- 
MTASC : no more coffee break while compiling




--
MTASC : no more coffee break while compiling


Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail
--
MTASC : no more coffee break while compiling