Franco1227
Member
Hello, I'm creating a game for a game jam. But, I need help to solve a problem: I created peaceful enemies, you only kill them and get points. I duplicated them by pressing alt in the room editor. But, when I kill only one, I kill all of them. The deadline is short, so, if I need, I'll create one object for each clone. But I'd like a simpler method. See my code:
if (place_meeting(x,y,obj_enemy)){
global.kill = 1;}
else { global.kill = 0; }
if global.kill = 1 and keyboard_check(vk_space) {
instance_destroy(obj_enemy);}
(note: global.kill means the possibility of killing) PLS HELP ME
if (place_meeting(x,y,obj_enemy)){
global.kill = 1;}
else { global.kill = 0; }
if global.kill = 1 and keyboard_check(vk_space) {
instance_destroy(obj_enemy);}
(note: global.kill means the possibility of killing) PLS HELP ME