dantedevil
Well-known member
I have a really weird problem with Stage3-3.
I use custom system to eliminate all enemies when the boss dies (courtesy of Bloodbane).
Example:
Then in the enemies, I need set this script:
This system has always worked perfectly for me.
But now something strange is happening to me specifically in stage 3-3 and under conditions.
What happens to me is that the enemy marked in red, never spawn during the level.
But if I remove the script marked in blue, the enemies spawn normally.
The weirdest of all this, is that as I said before, you happen under certain conditions.
If I play the game normally, in Stage_3-1 I have a branch. From this point I can choose between 2 options that direct me Stage3-1-1 or continue right to the end by Stage3-1.
Path 1
Choosing Stage3-1-1 the way is like this:
Stage3-1-1 / Stage3-1-2 / Stage3-2-3 / Stage3-3
Path 2
Continue right to the end by Stage3-1 the way is like this:
Stage3-1 / Stage3-2 / Stage3-3
If I choose path 1, when I get to Stage 3-3, the bug is present.
If I choose path 2, when I get to Stage 3-3, If I choose path 1, when I get to Stage 3-3, everything works correctly.
And finally the strangest thing of all:
I decided to do some tests to find where the problem is. So set the levels.txt at the beginning of the levels.txt Stage3-2-3 and Stage3-3 to test the bug.
But to my surprise, everything worked correctly. Apparently the problem happens when playing the game usually from the beginning and get there. It is really very strange.
I use custom system to eliminate all enemies when the boss dies (courtesy of Bloodbane).
Example:
Here the bosser entity:spawn vega
item bosser
coords 330 240
at 0
Code:
name Bosser
type none
anim spawn
delay 1
offset 1 1
frame data/chars/misc/empty.png
anim idle
@script
if(frame==1){
void vEntity; //Target entity placeholder.
int iEntity; //Entity enumeration holder.
int iType; //Entity type.
int iHP; //Entity HP
int iMax = openborvariant("ent_max"); //Entity count.
//Enumerate and loop through entity collection.
for(iEntity=0; iEntity<iMax; iEntity++){
vEntity = getentity(iEntity); //Get target entity from current loop.
iType = getentityproperty(vEntity, "type"); //Get target type.
iHP = getentityproperty(vEntity, "health"); //Get target health
//Enemy type?
if (iType == openborconstant("TYPE_ENEMY") && iHP > 0){
damageentity(vEntity, vEntity, 2000, 1, openborconstant("ATK_NORMAL"));
}
}
changeopenborvariant("slowmotion", 1);
setindexedvar("Dead", 1);
}
if(frame==2){
void self = getlocalvar("self");
changeopenborvariant("slowmotion", 0);
killentity(self);
}
@end_script
loop 1
delay 1
offset 1 1
frame data/chars/misc/empty.png
delay 200 # slowmotion effect will be active for 2 seconds
frame data/chars/misc/empty.png
frame data/chars/misc/empty.png
Then in the enemies, I need set this script:
spawn buzz
alias Frederick
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 9
coords 630 270
at 774
This system has always worked perfectly for me.
But now something strange is happening to me specifically in stage 3-3 and under conditions.
What happens to me is that the enemy marked in red, never spawn during the level.
But if I remove the script marked in blue, the enemies spawn normally.
music data/music/stage3-3.ogg
fglayer data/bgs/stage3/stage3-3/fpanel.png 2 -0.1 0 527 0 0 0 1 1 1 0 0 0 0 0 0
panel data/bgs/stage3/stage3-3/panel0.png none none
order a
direction both
spawn1 40 50 135
spawn2 50 55 135
spawn3 60 60 135
#z 180 270
type 0
settime 99
notime 0
stagenumber 3
light -32 -32
at 0
shadowcolor 1
at 0
shadowalpha 6
at 0
shadowopacity 150
at 0
spawn continue
coords 100 200
at 0
#######################################
spawn inout
coords 240 272
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial1"));
} @end_script
coords 0 0
flip 1
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial2"));
} @end_script
coords 209 0
flip 1
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial3"));
} @end_script
coords 418 0
flip 1
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial4"));
} @end_script
coords 627 0
flip 1
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial5"));
} @end_script
coords 836 0
flip 1
at 0
spawn st3_3pan
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_freespecial6"));
} @end_script
coords 1045 0
flip 1
at 0
spawn locker
item randscore
flip 1
coords 90 170
at 0
#-------1
group 4 4
at 0
wait
at 0
spawn bee
alias Cabal
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_follow11"));
} @end_script
2phealth 80
3phealth 110
map 10
coords 245 180
flip 1
at 0
spawn slicer
alias Marvin
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_follow10"));
} @end_script
health 60
2phealth 90
3phealth 120
map 9
weapon Knife 0
coords 340 180
at 0
spawn tallman
alias Marcus
health 80
2phealth 110
3phealth 140
map 10
coords 780 270
at 0
spawn tallman
alias Lucius
health 80
2phealth 110
3phealth 140
coords 720 180
at 0
spawn shocker
2phealth 90
3phealth 120
map 9
coords 680 180
at 0
spawn slicer
alias Lars
health 60
2phealth 90
3phealth 120
weapon Knife 0
map 10
coords 530 225
at 0
spawn bee
2phealth 80
3phealth 110
coords 550 250
at 0
spawn shocker
2phealth 90
3phealth 120
map 10
coords 500 220
at 0
spawn brutus
alias Kenny
health 70
2phealth 100
3phealth 130
map 6
coords 550 270
at 0
2pspawn slicer
alias Jervis
health 90
3phealth 120
weapon Knife 0
coords 530 225
at 0
3pspawn tallman
alias Hector
health 140
map 6
coords 720 180
at 0
#-------
##################
group 1 1
at 0
spawn delay
health 200
coords -100 270 0
at 0
wait
at 0
##################
#-------
Group 1 1
at 0
spawn arrow
flip 1
coords 430 240 100
at 0
group 100 100
#-------
spawn scrolls
coords 480 270
at 0
##################
spawn locker
item 1upr
flip 1
coords 504 170
at 16
spawn locker
item gold
coords 585 170
at 16
#--------------
spawn host1
coords 760 203 58
map 4
flip 1
at 272
spawn host1
coords 790 203 58
map 3
flip 1
at 272
spawn host2
coords 820 203 58
map 5
at 272
spawn host1
coords 850 203 58
map 5
flip 1
at 272
spawn host2
coords 890 203 58
map 5
at 272
spawn host1
coords 745 204 61
at 272
spawn host2
coords 775 204 61
map 1
at 272
spawn host1
coords 802 204 61
map 1
flip 1
at 272
spawn host2
coords 835 204 61
map 2
at 272
spawn host1
coords 865 204 61
map 2
flip 1
at 272
spawn host2
coords 895 204 61
map 3
flip 1
at 272
spawn locker
item medikit
flip 1
coords 945 170
at 272
#-------2
group 3 3
at 273
spawn buzz
alias Jurguen
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_follow10"));
} @end_script
2phealth 250
3phealth 300
map 8
coords 580 179
flip 1
at 273
spawn buzz
alias Adolphus
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_follow11"));
} @end_script
2phealth 250
3phealth 300
map 9
coords 675 179
at 273
wait
at 774
spawn balrog
@script
void main() {
performattack(getlocalvar("self"), openborconstant("ANI_follow30"));
} @end_script
item bosser
2phealth 600
3phealth 700
coords 530 181
at 774
spawn buzz
alias Bernhard
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 10
coords -150 210
flip 1
at 774
spawn buzz
alias Dietrich
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
coords 630 250
at 774
spawn buzz
alias Franz
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 6
coords -150 230
flip 1
at 774
spawn buzz
alias Heinz
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 7
coords 630 270
at 774
spawn buzz
alias Karl
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 8
coords -150 230
flip 1
at 774
spawn buzz
alias Frederick
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
2phealth 230
3phealth 260
map 9
coords 630 270
at 774
2pspawn buzz
alias Geoff
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
health 230
3phealth 260
map 10
coords -150 230
flip 1
at 774
3pspawn buzz
alias Hans
@script
void main()
{
void self = getlocalvar("self");
int Kill = getindexedvar("Dead");
if(Kill == 1){
killentity(self);
}
}
@end_script
health 260
coords 630 270
at 774
#---------------------------------
group 1 1
at 774
spawn story
alias stage_3-3b
at 774
spawn endstage0
coords -500 270
at 774
spawn endstage2
coords 240 240 250
@script
void main()
{
changeopenborvariant("slowmotion", 0);
setindexedvar("Dead", NULL());
}
@end_script
at 774
blockade 774
at 774
The weirdest of all this, is that as I said before, you happen under certain conditions.
If I play the game normally, in Stage_3-1 I have a branch. From this point I can choose between 2 options that direct me Stage3-1-1 or continue right to the end by Stage3-1.
Path 1
Choosing Stage3-1-1 the way is like this:
Stage3-1-1 / Stage3-1-2 / Stage3-2-3 / Stage3-3
Path 2
Continue right to the end by Stage3-1 the way is like this:
Stage3-1 / Stage3-2 / Stage3-3
If I choose path 1, when I get to Stage 3-3, the bug is present.
If I choose path 2, when I get to Stage 3-3, If I choose path 1, when I get to Stage 3-3, everything works correctly.
#-----------MISSION 3--------------
z 185 270 185 #3-1
file data/levels/stage3-1.txt
branch Stage3-1-1
z 180 270 180 #3-1-1
file data/levels/stage3-1-1.txt
z 200 270 200 #3-1-2
file data/levels/stage3-1-2.txt
branch Stage3-2
z 195 270 195 #3-2
file data/levels/stage3-2.txt
branch Stage3-2-1
z 195 270 195 #3-2-1
file data/levels/stage3-2-1.txt
branch Stage3-3
z 180 270 180 #3-3
file data/levels/stage3-3.txt
z 180 270 180 #
file data/levels/bonus03.txt
next
And finally the strangest thing of all:
I decided to do some tests to find where the problem is. So set the levels.txt at the beginning of the levels.txt Stage3-2-3 and Stage3-3 to test the bug.
Code:
#----------------- MORTAL KOMBAT The Chosen One----------------#
set LA_CRUZADA
typemp 0
custfade 100
lives 3
credits 99
nosame 1
cansave 2
completebg 1
branch Stage3-2-1
z 195 270 195 #3-2-1
file data/levels/stage3-2-1.txt
branch Stage3-3
z 180 270 180 #3-3
file data/levels/stage3-3.txt
But to my surprise, everything worked correctly. Apparently the problem happens when playing the game usually from the beginning and get there. It is really very strange.
Last edited: