SirCaliber
Member
I have an object, oCorpse, that creates a random amount of oLoot objects when it is created. In those oLoot objects' create event, they get a random hsp and vsp variable. But the hsp only works if it was created by oCorpse, not by oChest.
(oChest) On Collision with oBolt:
here's the create event for oLoot:
When the chest is shot with oBolt, the oLoot objects just go straight up and fall back down. No horizontal movement whatsoever. Any help I could get would be greatly appreciated.
(oChest) On Collision with oBolt:
Code:
with(other){
instance_destroy()
}
if(sprite_index = sBasicChestC){
repeat(irandom_range(5,8)){
instance_create_layer(x,y-2,"Main",oLoot)
}
}
sprite_index = sBasicChestO
hp -= 1
here's the create event for oLoot:
Code:
vsp = irandom_range(-3,-9)
image_xscale = 0.5
image_yscale = image_xscale
hsp = irandom_range(-10,10)
sprite_index = choose(sEmerald,sRuby,sCoin)
grv = 0.56
hitfrom = 0
When the chest is shot with oBolt, the oLoot objects just go straight up and fall back down. No horizontal movement whatsoever. Any help I could get would be greatly appreciated.