;

PDA

Click to See Complete Forum and Search --> : Converting a File from v3.72 to v4 beta 3


ForumNewbie
04-18-2003, 09:48 AM
All,

I thought it would be useful to have a thread with 'not-too-techy' points about how to convert files from version 3.72 to version 4, since it's taken me a while to complete my first conversion. Here are the points I have seen so far:

Use of 'Playsound' action needs to be converted to nameofsound.start()

Use of timer() funtion needs to changed to use getTimer()

Use of mouse.show() and mouse.hide() needs to changed to use mouseShow() and mouseHide()

Scripts which are within layers/buttons don't seem to import well. Copy and paste these instead.

Colours of text, etc, seem to be lost after import. Change these manually straight after importing them.

Substring(a,b,c) has changed to a.substr(b,c)

Use of commands that aren't in scripts were allowed in the graphical interface in 3.72 eg. Let, If, Loadvariables, didn't have to be in scripts in v3.72. These need to be put into scripts in v4.



Having got to grips with it now, version 4 is great. I'm really looking forward to working out some of the new stuff like XML, but that's a way off yet. If anyone else has any other observations of converting from 3.72 to 4, please add them to this post !

Morgan.

carnwath
04-18-2003, 01:27 PM
for a newbie that's pretty darned concise.

Thank you, Well done.

ForumNewbie
04-18-2003, 05:13 PM
Found another one that might be useful:

Scale is now done in percentages in the scripting, so where you used to have an object scaled to value '1' in v3.72 for it to appear normal size, it will need scaling up to '100' in v4.

Took me ages to work this one out !

DmanPfeif
04-18-2003, 10:18 PM
Originaly Posted by carnwath

for a newbie that's pretty darned concise.

Agreed! I've been frantically trying to figure out how to convert this stuff. Are you sure you're a newbie?

:hubba: DAN

ForumNewbie
04-29-2003, 07:18 PM
Just a tiny observation:

Where you used the 'position' property for an element in a script in version 3.72, you can drop the word 'position' in version 4 to save some precious keystrokes.

ie. element.position.x can be abbreviated to element.x


Every little helps !

Morgan.

ForumNewbie
05-11-2003, 01:41 PM
Another little observation:

Don't name any of your own elements 'Text' if you're using the excellent new 'Build Menu' feature. The Build Menu feature uses this element name, and your scripts might not work right. Just use another name to avoid the problem.

Morgan.

ForumNewbie
06-11-2003, 04:05 PM
Just a note to keep this thread active, since there was a question today on how to use mouseShow() in V4 compared to version 3.72.

:D

M.

lopez1_de
07-02-2003, 12:02 PM
I can'T import anything.. :(

Unknown type 'ActionLoadMovie' cannot be created
Unknown type 'ejected_main.movie' cannot be created
Unknown type 'level' cannot be created


No movie opens. What the hell I must do? I don't understand.

ForumNewbie
07-02-2003, 05:13 PM
Hi There,

Can you post whatever files you have in a zip file?
Then we can help to confirm if it's the files that are the trouble, or something more wacky.

Did you create the files in v4 or an earlier version?

M.

ForumNewbie
07-17-2003, 08:16 PM
Here's a few conversion issues that have caused me a bit of trouble. I think people have mentioned these in one or two threads, but I've only just managed to properly understand them, so I thought I'd add them to this list of points for reference:

1. If you want to use a variable that was created in the starting script, or in a script in the main movie (ie. Not in a layer or child movie) then you must put 'root.' in front of it to access it in any scripts.

2. The same is true of functions that are created in the starting script. If you need to call them from scripts anywhere else in your movie, make sure you call them with 'root.functionname(arguments)'

3. If you're having trouble with 'loadVariables' and it seems not to be posting anything at all, try the following:

urlstring='url.php?variablename1='+variable1+'&variablename2='+variable2
loadVariables (urlstring,"POST")

Where:
'url.php' is the url of the file you're sending variables to.
'variablename1' is the variable name expected in the server side script, and variable1 is the value from 3dfa you want to pass.
'variablename2' is another variable name expected in the server side script, and variable2 is another value from 3dfa you want to pass.
Obviously, you can post loads of variables this way if required.

This worked on 2 of my movies that just refused to post variables normally, my Dart Game (http://www.morgan-multinational.com/dart_game_v4b3.html) (Much smaller file after conversion) and my 10 pin bowling game (http://www.morgan-multinational.com/bowling_game_(v9).html) .

Hope this is useful to someone else,

M.

ocabeza
09-06-2003, 12:58 PM
I can't open some of my older .movie files. Does anyone know how get around this? I need to make some updates and now up stuck. I really don't want to re-create all my old .movie files.
Here is the message:
Unknown type 'ActionLoadMovie' cannot be created
Unknown type 'main_menu.movie' cannot be created
Unknown type 'level' cannot be created

blanius
09-06-2003, 08:44 PM
You can either recreate them from scratch or edit them in the older version.