+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2009
    Posts
    21
    Points
    93,359.00
    Rep Power
    180

    Cool Convert: Float to Integer, Integer to Float

    Code:
    #Float to Integer
    cvt.w.s $
    mfc1 $
    Code:
    #Integer to Float
    mtc1 $
    cvt.s.w $
    Integer: The Basic Hex (0x00000001 - 0xFFFFFFFF)
    Float: Whole Numbers in Digits (0x3F800000 = 1)

    Don't really know Just used it once awhile back..
    You just the Float You Want.
    Example:

    Code:
    #3 in FLOAT to 3 in Interger
    cvt.w.s $f4, $f4
    mfc1 $t0,$f4
    Code:
    #3 in Interger to 3 in FLOAT
    mtc1 $t0, $f0
    cvt.s.w $f0, $f0
    So Just Use Float Registers and Temporary Variables:
    Code:
    #Float Register
    $fx
    Code:
    #Temporary Variables
    $tx
    Enjoy Coding,
    -Creator

  2. #2
    Join Date
    Jan 2008
    Location
    Your mom's fresh shaven Cun+.
    Posts
    2,598
    Points
    1,729,141.43
    Rep Power
    211

    Default

    Or you can put it in ps2dis and type f or i





+ Reply to Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts