super fast speed(help(lua))

spyninja242001 - Custom level - from iOS
PlayEditLog in to be the first to like this level.

Views: 915 Downloads: 234 Unique objects: 6 Total objects: 22

Derivatives

Discuss this level

Log in to comment on this level.
  • spyninja242001: I'm just new at lua
  • spyninja242001: @cornfield gamer: it's still not working
  • spyninja242001: @zardOz: I don't know how to use it
  • spyninja242001: @zardOz: oh tnx
  • zardOz2: @spyninja242001: thats the ID# for the object you want to target, whatever it is
  • spyninja242001: @zardOz: what is the # for´╝č
  • cornfield gamer2: ok I was using if then to do that but this is better for the most part. all ways thought they would have that but I thought it would have been ||x||
    thank You for explaining it to me.
  • zardOz2: @cornfield gamer: when moving left the xvelocity is -x and when moving down the yvelocity is -y, math.abs will remove the negative from the number
  • spyninja242001: @zardOz: oh tnx
  • cornfield gamer2: @zardOz: I'm drawing a blank why math:abs()?
  • zardOz2: object=world:get_entity_by_id(#)
    x,y=object:get_velocity()
    speed=math.abs(x)
    game:show_numfeed(speed)

    That will give you the left-right speed
  • spyninja242001: @golden: or any kind
  • spyninja242001: @golden: yes
  • Golden: As you were looking for mph right?
    (Speed'o'meter)
  • Golden: I can help
  • spyninja242001: @TechZ: @zardOz:

LEVEL ID: 5540