# How to conevrt a fortran method to a Macromedia flahs method

**URL:** <https://forum.kirupa.com/t/how-to-conevrt-a-fortran-method-to-a-macromedia-flahs-method/317519>\
**Category:** Uncategorized\
**Created:** [December 23, 2010, 8:41am UTC](https://forum.kirupa.com/t/how-to-conevrt-a-fortran-method-to-a-macromedia-flahs-method/317519 "2010-12-23T08:41:49Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![zisis](https://avatars.discourse-cdn.com/v4/letter/z/b2d939/32.png) [@zisis](https://forum.kirupa.com/u/zisis)\
**Post date:** [December 23, 2010, 8:41am UTC](https://forum.kirupa.com/t/how-to-conevrt-a-fortran-method-to-a-macromedia-flahs-method/317519/1 "2010-12-23T08:41:49Z")

</div>

i have a fortran method which creates random numbers.  
i want to convert this method to a flash method .  
I want to get numbers from this method and use them in the delay method of flash.

the fortran method is the folowing

real znew1 , zold1 ,a,m,z1,p,TIME1  
a= 16807.  
m=2147483647  
B=2  
!creates a random number

p=nint((a_zold1)/m)  
znew1 = nint (a_zold1-(p\*m))  
z1=(znew1/m)   
IF(Z1.LE.0) THEN  
z1=z1+1.0  
else  
ENDIF

!creates the time which i will use in the delay method  
TIME1=-B\*LOG(1-Z1)
