Gyazo: What I want to accomplish is:
Gyazo: Current outcome:
Code: Projectile activation
ability/active/mage
roaringWaves
name = "Roaring Waves"
damage = list(130,140,150,160)
cooldown = 1//95
icon_state = "_gui_roaring_waves"
spiritCost = 1//22
perform(mob/a){
flick("Sword Slash1",a)
a.target = locate(a.x-5, a.y - 1, a.z)
new/pixel_projectile/mage/roaringWaves(a.loc)
a.target = locate(a.x, a.y - 1, a.z)
new/pixel_projectile/mage/roaringWaves(a.loc)
a.target = locate(a.x+5, a.y - 1, a.z)
new/pixel_projectile/mage/roaringWaves(a.loc)
}
Code: The actual projectile
pixel_projectile/mage/roaringWaves
icon = '_mage_effects.dmi'
layer = 4
icon_state = "_roaring_waves"
attackType = "spiritual"
moveLimit = 10
attackType = "spiritual"
collide(atom/a){
if(ismob(a)){
var/mob/attacker = owner
var/mob/defender = a
if(attacker.checkTeamate(defender)) return
var
damage = attacker.getDamage(defender = defender, attackType = src.attackType, guardIgnorant = src.guardIgnorant, damageAmount = src.damageAmount)
dmgShow = "<font color = #fff>[damage]"
image/aftermath/ia = new/image/aftermath/basicMageAttack
ia.aftermath(defender)
if(isnum(damage))
if(attacker.getProbability(attacker.getCriticalChance(defender)))
damage = attacker.getCriticalDamage(defender, damage)
dmgShow = "<font color = #ffa500><font size = 3>[damage]!"
defender.coreLoss(defender.health, damage, attacker)
//MAGE DOESN'T GET TO DEAL WOUND DAMAGE BUT INSTEAD DAMAGE IS INCREASED BY 1000% WOUND_DAMAGE
//Basic Attacks Generate 3% Spirit!
attacker.coreGain(attacker.spirit, attacker.spirit.maximum * 0.03)
//Roaring waves slows down enemies for 2 secs.
if(attacker.checkAbilitySpecial("RoaringWaves")) attacker.applyCondition(defender, "slow", 20)
attacker.showDamage(defender, "<b>[dmgShow]")
}
}
I just need help with the positions and fill in the blanks.
Thank you,
Luchasi
in your "what I want" and "What I Get" pictures, you don't quite draw attention to what details in the pictures matter, and what is just background.
Like, i noticed your what i get picture has hud icons that your what i want picture lacks. did you mean you wanted help removing the hud icons? most likely not, but if you don't spell that out for us, how can we know for sure?
Maybe you were referring to the fact that one is landscape, and one is portrait. I could certainly help you convert your monitor into a portrait monitor if it's supported by your hardware, but i don't think that's what you were aiming for was it?
I'm assuming, that the issue between the two is two fold, the projectiles don't beam out, and their position should be parallel.
For the position one, the issue is in perform(mob/a)
target says where the beam ends, not where it starts. I don't know enough about the projectile library to know for sure how to solve this, but i think what you need to do is change the a.loc yo pass to the projectile to be the turfs next to the mob instead, and then rework the a.target math, because thats picking the wrong targets.