Hello! I want to create a few projectiles systems but I have no idea where to start could Anyone help me through this?
(Pixel Game)
Trying to Create 2 types of projectiles
1st: A lineal projectile
2nd: Create 8 projectiles and sends 1 each direction
Any help will be appreciated (Atleast something that I can start off with so I can keep testing while I learn)
Oct 5 2015, 11:40 am
|
|
Refer to the walk() process for projectiles. The elements it takes includes the direction.
|
Big switch() is unnecessary.
mob |
It isn't actually creating the projectile it does nothing when I use the verb
Obj: https://gyazo.com/b76cea1746a743339e22d68f4aa5b829 Do I have to add a proc to the obj etc? |
In response to Kakarot06
|
|
Sorry, I forgot to specify the initial location (which Konlet did too...).
|
In response to Kakarot06
|
|
If you check the DM Reference for the walk() proc, you'll see that there are optional parameters you can provide to set the lag (time between steps, useful for tile movement) and speed (number of pixels per step, enables pixel movement mode). Given the speed, you can limit its distance traveled by stopping/destroying it after a certain amount of time with sleep or spawn.
|
Or.. We could dumb it down to baby steps..
//updated this. I'm guessing he's a starter so we gotta make it more readable for him .. Nun of that fancy stuff as to we want him to learn gradually not just use everything we give him.. |
In response to Hebrons
|
|
Hebrons wrote:
Or.. We could dumb it down to baby steps.. > mob/verb/shoot() I'm guessing he's a starter so we gotta make it more readable for him .. Nun of that fancy stuff as to we want him to learn gradually not just use everything we give him.. True, i'm dumb in DM too.I know, ready code isn't good way. But i don't undestand in english a lot. When i see code with simpe comment - it's more readable for my. So in my opinion answers should looks like mob/verb/shoot() DM Reference say:
/* Sorry for my poor english :P |