Lua Experiments: Fake Explosion Effect(LARGE SCALE)

Demon666 - Custom level - from Android
PlayEdit31 players liked this.Log in to like this level.

the explosion breakes connections to near by objects and damages creatures

F: explode
slider: range (50 max)

also if anyone knows a better way to convert radians (-180 threw 180) to binary angles (0 threw 1) the please tell me.....

Views: 7728 Downloads: 3172 Unique objects: 1 Total objects: 39



Discuss this level

Log in to comment on this level.
  • Chad64: @Demon666: oh, so it can only be used inside the function, but not on other functions. Thanks! :D
  • Demon666: @Chad64: local makes a variable only accessible from inside the function that it was created within.

    function exp()
    local testvar="somethin"
    if testvar==nil then
    game:message("the variable doesnt exist")
    game:message("the variable exists")

    if you put the if/else statement inside of the function then the variable will exist but if you copy the if/else statement outside of the function where the "test" variable was created then the if/else statement
  • Chad64: @Demon666: How is Local used? And what does it do?
  • zardOz2: Damnit! I give up
  • zardOz2: Doh,
    if anghen result=(ang-.5)*-2 else result ang end
  • Demon666: @zardOz: i did something like that..... but i did if ang < 0 for -180 and 180. then divided by 360... it all look so messy tho... i was wondering if there was a cleaner way lol.
  • zardOz2: @Demon666: oh, it was just info on angles.. not actually what you described, you need something like,
    ang=angle%360/360; if ang>.5
  • Demon666: @Ctjet: love isn't a good enough word to describe the relationship lol...
  • Demon666: @zardOz: dosent work the blast wave is launching objects in all the wrong angles
  • Ctjet: You are loving 1.5 arent you
  • zardOz2: Oh this one is fun... angle%360/360 will convert any degree value into a gyro angle, -90=.75 270=.75 630=.75 -450=.75 etc.
  • JOELwindows7: Duper Awesome!!!

LEVEL ID: 10192