kikiyay, вопрос риторический. Можно сделать вообще всё. В чём только будет проявляться различие между оружиями - скорость снаряда, звук стрельбы, и.т.п.?
vladgalay, Вот if pge.controls.pressed(PGE_CTRL_CROSS) and switch == 1 and fire == false and bul > 0 then bul = bul - 1 fire = true fire:play() end if pge.controls.pressed(PGE_CTRL_CROSS) and switch == 2 and fire == false and bul > 0 then bul = bul - 1 fire = true fir:play() end Вот то что я выделил pge не читает.
vladgalay, нет, он не то что не читает он просто при смене переменной switch он всё равно воспроизводит if pge.controls.pressed(PGE_CTRL_CROSS) and switch == 1 and fire == false and bul > 0 then bul = bul - 1 fire = true fire:play() end
kikiyay, я попытаюсь сделать в игре хоть мало-мальскую структуризацию ресурсов, оптимизацию кода, и работоспособность смены оружия. Но от тебя требуется пояснить за что отвечает каждая переменная твоего кода. Сможешь?
"" and "PlayStation" are registered trademarks of Sony Computer Entertainment Inc. "", PSP and "UMD" are trademarks of Sony Computer Entertainment Inc. "", "XMB", "Memory Stick Duo" and the "Memory Stick Duo" logotype are trademarks of Sony Corp. All product titles, publisher names, trademarks, artwork and associated imagery are trademarks, registered trademarks and/or copyright material of the respective owners. All rights reserved.