Skocz do zawartości


Hello to all


  • Zaloguj się, aby dodać odpowiedź
4 odpowiedzi w tym temacie

#1 eisflash

  • Użytkownik
  • PipPip
  • 11 postów
  • Program:
    Alligator 8
  • Time Online: 5h 11m 13s

Napisano 15 październik 2011 - 19:55

Witam wszystkich,
dobre forum, ale niestety tylko w języku polskim,
z tego tekstu I googl ..... Mam nadzieję, że będzie to przetłumaczyć słowa z wszelkim złem.
Jestem nowym ActionScript i kupiłem osiem aligator,
Mam problem z samouczków ActionScript aligatora na Kirupa.com kilku staramy się, i zauważyłem, że masz umschriben z niektórymi aligatora, ale jak dotąd nie złe.
Teraz moje prioblem jest drugim swf tej strony: http://www.kirupa.co...hape_camera.htm
Nie wiem, jak mogę abspeichrn zdjęcia jako Bibliotek proszę o pomoc.
wiele wcześniej dan

#2 czesiowozny

  • FlashBoy
  • PipPipPipPip
  • 232 postów
  • Gadu-Gadu:
    10546960
  • LokalizacjaKowalewo Pomorskie
  • Program:
    Flash Designer 8
  • Time Online: 6h 51m 28s

Napisano 15 październik 2011 - 21:11

Hi.You think, were we do not support this program in english but you were in mistake. We try to answer on all questions in foreign language. You may write here with your problems but try do not use tranlators and write in english :)

#3 eisflash

  • Użytkownik
  • PipPip
  • 11 postów
  • Program:
    Alligator 8
  • Time Online: 5h 11m 13s

Napisano 16 październik 2011 - 11:40

:-)
thnx
hello im italian live in germany and my englisch is not perfct ;-)
I have a problem with alligator ActionScript tutorials on Kirupa.com and other sites.
Now my prioblem is the second swf of this page: http://www.kirupa.co...hape_camera.htm
I do not know how I can save pictures as Library to call it in scriptlike this:
//---------Beginn AS-----------------
this.createEmptyMovieClip("theScene", 1);
theScene._x = 150;
theScene._y = 150;
theScene.depth = 1;
objectsInScene = new Array();
cameraView = new Object();
cameraView.x = 0;
cameraView.y = -100;
cameraView.z = 0;
cameraView.velocity = 0;
focalLength = 300;
 
this.x = this.x - cameraView.x;
this.y = this.y - cameraView.y;
this.z = this.z - cameraView.z;
this.scaleRatio = focalLength/(focalLength + z);
this._x = x * scaleRatio;
this._y = y * scaleRatio;
this._xscale = 100 * scaleRatio;
this._yscale = 100 * scaleRatio;
this.swapDepths(Math.round(-z));
 
placeObjectIn3D = function(obj, x, y, z){
	var scaleRatio = focalLength/(focalLength + z);
	obj._x = x * scaleRatio;
	obj._y = y * scaleRatio;
	obj._xscale = 100 * scaleRatio;
		obj._yscale = 100 * scaleRatio;
	obj.swapDepths(Math.round(-z));
};
 
// CARS
displayCar = function(){
	var x = this.x - cameraView.x;
	var y = this.y - cameraView.y;
	var z = this.z - cameraView.z;
	if (z < 4000){
		if (z < 0){
			this.z += 3000;
			this.x = 200-Math.random()*400;
			x = this.x - cameraView.x;
		}
		this.z += this.velocity;
		z = this.z - cameraView.z;
	}
	placeObjectIn3D(this, x, y, z);
};
 
// TIRES
displayTire = function(){
	var x = this.x - cameraView.x;
	var y = this.y - cameraView.y;
	var z = this.z - cameraView.z;
	if (z < 0){
		this.z += 3000;
		z = this.z - cameraView.z;
	}
	placeObjectIn3D(this, x, y, z);
};
 
// CARS
for (i=0; i 200) cameraView.x = 200;
	
	for (var i = 0; i < objectsInScene.length; i++){
		objectsInScene[i].display();
	}
};
theScene.onEnterFrame = drive;
 
//------------End of As-----------

i have create two clips width relative name "car" and "tir" but Boooooo!
please help.
many thankx
in advance

#4 Ptimulka

  • FlashMan
  • PipPipPipPip
  • 907 postów
  • Gadu-Gadu:
    3739670
  • LokalizacjaGdańsk
  • Program:
    Flash Designer 8
  • Time Online: 5d 2h 53m 51s

Napisano 16 październik 2011 - 14:30

Hello, I've changed the code a llitle bit, so it works in Alligator now, and you don't have to call images from library in script, but you just import them into the file. I hope, it's ok.

Załączone pliki

  • Załączony plik  cars.sfd   174,53 KB   13 Ilość pobrań


#5 eisflash

  • Użytkownik
  • PipPip
  • 11 postów
  • Program:
    Alligator 8
  • Time Online: 5h 11m 13s

Napisano 16 październik 2011 - 15:35

Many thanks for the quick response.
But questions remain with me, with the beginning of the auto var mmich one, because I would like to distort images with 3D as the alligator, for example:
http://www.gotoandpl...d2634297a7504be
and that was just the beginning for me and the car loaded with ripe because here wirdt loaded image.
I have the As. kan you pls help me to understand this logick fro Fla As in the AS SDK to convert?
the As:
//-----bginn AS--------
function paint()
{
	var y0 = 0;
	var y1 = bar.tog1._y;
	var endScale = bar.tog2._y - bar.tog1._y;
	var k = 1;
	while (k < 50)
	{
		_root["msk" + k]._y = msk._y + (y1 - 0) / 50 * k;
		_root["msk" + k]._yscale = 100 - k * (100 - endScale) / 50;
		++k;
	} // end while
} // End of the function
msk.mc.attachMovie("mv2", mv22, 2);
var k = 1;
while (k < 50)
{
	duplicateMovieClip(msk, "msk" + k, k);
	_root["msk" + k]._x = _root["msk" + k]._x + 2 * k;
	_root["msk" + k].mc._x = _root["msk" + k].mc._x - 2 * k;
	_root["msk" + k].mc.attachMovie("mv2", mv22, 2);
	++k;
} // end while
bar._y = msk._y;
bar._x = msk._x + 100;
bar.tog1._y = 0;
bar.tog2._y = 100;
 
//--button as
on (press)
{
	startDrag (this, false, _x, -50, _x, 150);
	dragging = true;
}
 
on (release)
{
	this.stopDrag();//this give me Error
	dragging = false;
}
//-------End As-------

many thankx
in advance




Użytkownicy przeglądający ten temat: 1

0 użytkowników, 1 gości, 0 anonimowych