Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Damage tutorial
#1
If someone could make a damage tile tutorial, I have a kill tile, but that is very primitive.
Reply
#2
Just change the Kill command in the kill tile to:
Code:
Call SetPlayerHP(Index, GetPlayerHP(Index) - 5)
Reply
#3
lmao
Reply
#4
Woah. Lightning Source is gonna be a great engine :roll:
Quote:Robin:
Why aren't maps and shit loaded up in a dynamic array?
Jacob:
the 4 people that know how are lazy
Robin:
Who are those 4 people?
Jacob:
um
you, me, and 2 others?
Reply
#5
For your kill tile, make an editor, much like the warp or item tile. In this editor, have a scroll bar, scrlDamage, and use that scroll bar to set how much damage it does. Assign the amount of damage to the Tiles Data1.

Call SetPlayerHP(Index, GetPlayerHP(Index) - Map.Tile(getplayerx(index), getplayery(index)).data1)


Something like that will work. That's not exact code though

Also, you might want to go into sub that regenerates the players HP, and add a check so that their hp doesn't regenerate (or maybe even continues to go down) if they are standing on this tile
Reply
#6
I did this years ago with M:RPGe. Really easy. You just make a form for it so the map editor can define how much damage is taken off on that tile. Then just send the data in the packet. If you're unfamiliar with how to send and use tile attribute packets just copy the Kill tile and make the necessary changes. I'm adding this, as well as a new heal tile to my engine. I think it's a great trap that doesn't kill you, but reduces HP to make an area more challenging.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)