You are not logged in.
Hmmm, I haven`t any blams, but player is teleported twice, and i don`t know why.
Mayby if I close "
we chr_inv_reset 0
chr_teleport 0 22
chr_set_health 200
dmsg " Walcz z Syndykatem. "
sleep 70
chr_giveweapon 0 w3_phr
chr_givepowerup 0 ammo 1
chr_givepowerup 0 cell 1 " in "func begin"
and add
"if (my_save_point eq 0)
{ fork begin
fork wave1
}.
I can`t try it because i have a virus so when i load savepoint my script didn`t work (konoko is in "start position" and nothing do[nice])
Hmmm, and
bool did_kill_griffen(void) returns true=1 if the (nameless) variable "we killed Griffin" is set and false=0 otherwise.
void killed_griffen(bool) sets the (nameless) variable "we killed Griffin" to the same value as its argument.
I don`t understand it ;( ( i Know I`m stupid)
And I`m sorry because I waste your time ;|.
~~~~~~~~~~
Edit: I don`t read your post paradoks
Which dmsg-line is broken??
Last edited by Tantir (06/18/07 15:06)
Offline
in wave2
dmsg "Wiedz, ze ten agent TCTF ma wszczepiony eksperymentalny Crystalis i
jego pasek zycia jest o 1/3 wiekszy niz zwykle."
oh and add "restore_game" so that konoko will be spawn at the right place (otherwise she will go where's her out-of-the-sky-landing-place)
(code for SP1 to SP3)
save_point=1;
restore_game
GrifOPS01respawn
fork wave2
and this .. it seems that it deactivate SP2 and 3. You should delete "save_point= 2;" and the others of that kind of structure.
fork wave3
save_point= 2; save_game 2 autosave
Last question for today: you have "wave5" (Muro) and don't wrote something in savepoint4. Wanted by you?
Your task for griffin/griffen: look up the original compound script, search for grif... Maybe you will get what you need. (I can't tell you because I run out of time, don't know if I get some til weekend again.)
Last edited by paradox-01 (06/19/07 08:06)
Offline
i have a virus so when i load savepoint my script didn`t work (konoko is in "start position" and nothing do[nice])
That's not a "virus"... Just an invalid command/statement somewhere in the scripts.
To find out what is wrong, I suggest you backup the corrupt scripts, and then rebuild your logic piece by piece, starting with "func main", and then adding one function at a time, commenting out (#) the calls to functions that you haven't added yet.
Of course that way your script will not work completely, but it's a sure way to find where the error was, and to make the whole thing work, eventually.
Knowing how to track down a mistake is the essence of intelligent debugging.
If your scripts are corrupt and don't load at all, you can always rebuild them like I said, one function at a time, until you find the function where the problem is.
You can also comment/uncomment (#) blocks of statements (lines) if you suspect there's a mistake there. Another thing you can use is debug messages (dmsg).
Oh, and the Dev Mode also helps when making any kind of mod, so you might want to get it if you haven't already.
There are a lot of tips of how to "script well"... In your case (corrupt scripts), you should definitely rebuild your logic piece-by-piece to find the mistake (see above).
bool did_kill_griffen(void) returns true=1 if the (nameless) variable "we killed Griffin" is set and false=0 otherwise.
void killed_griffen(bool) sets the (nameless) variable "we killed Griffin" to the same value as its argument.I don`t understand it ;( ( i Know I`m stupid)
No one is stupid.
We are talking about saved game data. Oni writes saved game data in persist.dat. Some of the data is savepoint-specific (position, health, inventory).
But there are also variables that apply for the whole game. Oni remembers the screen resolution, the invert-mouse setting, the difficulty level, etc.
Among the global variables Oni remembers, there is a "boolean" variable (an ON/OFF flag) that is "true" if we "killed Griffin" and "false" if we didn't.
This variable is used to "remember" what we did at the end of Chapter 13, so that Oni can use the corresponding ending at the end of Chapter 14.
This variable does not have a name (like "we_killled_griffin"), so you can't write stuff like "if(SomethingHappened()) we_killed_griffen= true;" or "if(we_killed_griffen) DoWhatever();"
But there is a way to change/set the true/false state of that variable: you call killed_griffen(true) or killed_griffen(false)
And there also is a way to read the true/false state of that variable: you use if(did_kill_griffen()) {DoSomething();} else {DoSomethingElse();}
You can look for "griffen" in the scripts for the last 2 chapters to see how the original scripts store and retrieve the information "we killed Griffin" (true/false).
A few more things. Like paradox, I say you should remove "save_point= whatever;". You are not supposed to change save_point. It doesn't hurt, but it's "illegal".
I also recommend you reindex your waves, starting at wave0. It's just less confusing when you work with savepoints which are 0-based. So if you're easily confused...
Behold the power of that which is yet unborn! For the swirling images that flow forth from the Chrysalis are only a shadow of the sleeper's true power.
Offline
Hmm, on the first page in my 7th post, is code. Yesterday it working perfecly, but now it isn`t working, why is that? I try my script on other PC and it isn`t working, paradox`s version isn`t working too. It strange. So i can`t do anything.
Offline
Hm right. I didn't notice my remaining "fork dead". Here's the (hopefully 100% bug-free) script. (Load the attachment.)
And go sure you've no other scripts in the compound folder.
Last edited by paradox-01 (06/19/07 08:06)
Offline
damn i love this mod
Offline
I`m very glad, you like it Dr.Genya.
func GrifoPS01DeathCheck {
chr_wait_health GrifOps01 0
chr_givepowerup 0 lsi
}
### this func blaming Oni.
I searching in 13 and 14 chapters abaut Grifindies but i only find "killed_griffen 1""if (did_kill_griffen() eq 0)" I think only this func is a problem. I think abaut this 4 hours and I`m think" geyser is wrong. I`m stupid" :(
[b]
func GrifOps02DeathCheck {
chr_wait_health GrifOps02 0
killed_griffen(1)}[/b]
func GrifOPS01respawn {
if(!chr_has_lsi(0))
SpawnNameFlagHealthReset GrifOps01 23
}
func GrifOps02respawn {
if (did_kill_griffen() eq 0)
SpawnNameFlagHealthReset GrifOps02 23
}
Offline
Like it alot as well (bit hard imo, but that's just me )
Hm right. I didn't notice my remaining "fork dead". Here's the (hopefully 100% bug-free) script. (Load the attachment.)
And go sure you've no other scripts in the compound folder.
Would be nice if someone could also translate the messages to English in another version to make it more enjoyable .
Last edited by Tyr (06/19/07 13:06)
Offline
@ Tantir: BBCode doesn't work within a "code" tag. Neither do smilies
I searched for "Griffin dies" in chapters 13 and 14 but i only found killed_griffen 1 and if (did_kill_griffen() eq 0)
I think only this func is a problem. I've been thinking about this for 4 hours and now I think "geyser is wrong. I am stupid"func GrifOps02DeathCheck { chr_wait_health GrifOps02 0 killed_griffen(1)}
Check out Loser here. That's an inferiority complex you can't beat. So why even try?
The mistake is that the closing brace (}) is where it shouldn't be (it's always the closing brace, isn't it? )
Unless you finish a statement with a semicolon (;), it's supposed to be finished by an end-of-line.
So killed_griffen(1)} is incorrect. killed_griffen(1);} would be correct, but don't do that.
It's always better to use consistent indentation (tabulation) to visualize logical blocks. So just write:
func GrifOps02DeathCheck {
chr_wait_health GrifOps02 0
killed_griffen 1
}
(the closing brace at the end of the function is aligned with "func")
(you can use brackets and semicolons but you don't have to here)
The rest looks OK, but I recommend to write:
func GrifOPS01respawn {
if(!chr_has_lsi(0))
SpawnNameFlagHealthReset GrifOps01 23
}
func GrifOps02respawn {
if(did_kill_griffen() eq 0)
SpawnNameFlagHealthReset GrifOps02 23
}
(add an extra indent for the second half of the if statement, just to show it's not a separate statement)
Two more tips.
You can use give_powerup lsi instead of chr_give_powerup 0 lsi
You can use if(!did_kill_griffen()) instead of if(did_kill_griffen() eq 0)
And one warning about "did_kill_griffen" and "killed_griffen".
What do you think will happen if GrifOps02 is alive when you reach SP2, then he dies, and then you try to reload SP2?
It turns out that the global Griffin flag is maybe not as suitable as the LSI item to store savepoint-specific information
Last edited by geyser (06/19/07 13:06)
Behold the power of that which is yet unborn! For the swirling images that flow forth from the Chrysalis are only a shadow of the sleeper's true power.
Offline
@ Tantir: Play from savepoint3 If you like the script look a bit into it. (Attachement2 ... well, that should happen at least ^^)
Last edited by paradox-01 (06/19/07 15:06)
Offline
(a little video - attachment don't wok, args.. ok try this link)
click on the button "free", in netx window enter the big fat code, and download
Last edited by paradox-01 (06/19/07 15:06)
Offline
Nice video. Attachments may be limited in size.
I still didn't test any of this ingame, but flipping through paradox's latest, I can see a few things worth mentioning:
# test-wise we will spawn him with 0 HP, so he's dead..
SpawnNameFlagHealthReset C_Eb30 22 0
SpawnNameFlagHealthReset doesn't set the health if you specify a health of 0...
var int FriendsAlive=1;
# ...
fork GrifAndFriendsAliveCheck
if (FriendsAlive eq 1)
{
# fork surprise_timer_0
fork test2
}
Note that you "fork GrifAndFriendsAliveCheck" (separate thread...) and then check on FriendsAlive before GrifAndFriendsAliveCheck has a chance of setting it to 0.
Also note that it doesn't make sense to "fork test2". If you don't fork it, you can remove the next "sleep 600", and you'll automatically avoid overlapping (visible in your video).
fork GrifoPS02DeathCheck
if (did_kill_griffen() eq 1)
{
Same thing. You don't give "GrifoPS02DeathCheck" (capitalization liberties... hmph) the chance to set the flag, because it runs in a separate thread. And as for the checking itself...
did_kill_griffen=0;
There is no such variable. You have to use void killed_griffen(bool). however, note the global effect of that variable: you can only use this flag for a friend that is spawned on the next-to-last savepoint.
fork GrifoPS01DeathCheck
save_game 2 autosave
Same thing. A separate thread for the checkand no sleep before the saving means that you have no guarantee that Konoko will get the LSI in time.
my_save_point = save_point;
...
if (my_save_point eq 1)
{
save_point=1;
What did I say about setting save_point and using my_save_point?
chr_wait_health GrifElite02
Eh? (there are other typos here and there, but they're not critical... yet )
(actually, the default value of the 2nd argument is 0, but I bet you didn't omit it on purpose )
save_game 1 autosave
wave1
I would put "save_game 1 autosave" at the start of "wave1" (etc). And I would definitely use "fork wave1" here (otherwise wave1 is nested in wave0, and so on, so you get 6 layers of nesting: that's at the limit of the stack)
Other messy stuff here and there... Generally, your comments make little to no sense to me.
Last edited by geyser (06/19/07 16:06)
Behold the power of that which is yet unborn! For the swirling images that flow forth from the Chrysalis are only a shadow of the sleeper's true power.
Offline
#
# "Phalanx" v0.3b (including some code ideas ..)
#
#######################################################
var int my_save_point=0;
func pre(void) {
# launch Oni Menu if you have it
# fork om_core_3
fork super_kick
fork super_punch
# following is for testing
# fork surprise_timer_0
}
func super_punch(void) {
chr_wait_animation 0 KONCOMcomb_p_p_p
slowmo 240
chr_animate 0 KONCOMsuper_punch
sleep 50
fork super_punch
}
func super_kick(void) {
chr_wait_animation 0 KONCOMcomb_p_p_k
slowmo 240
chr_animate 0 KONCOMsuper_kick
sleep 50
fork super_kick
}
func SpawnNameFlagHealthReset(string n, int f, int h, int r){
ai2_spawn(n); chr_teleport(n, f)
if(h) chr_set_health(n, h)
if(r) chr_inv_reset(n)
}
func SpawnNameFlagReset(string n, int f, int r){
ai2_spawn(n); chr_teleport(n, f)
if(r) chr_inv_reset(n)
}
#######################################################
func void main(void)
{
env_show 401 1
env_shade 401 913 .2 .4 .2
env_show 402 1
env_shade 401 913 .2 .1 .3
env_show 403 1
env_shade 401 913 .3 .1 .3
env_show 404 1
env_shade 401 913 .3 .2 .1
env_show 405 1
env_shade 401 913 .1 .3 .2
env_show 406 1
env_shade 401 913 .2 .1 .4
env_show 407 1
env_shade 401 913 .1 .4 .1
env_show 408 1
env_shade 401 913 .4 .4 .1
env_show 409 1
particle dishpulse do start
particle sturm_ambient start
fork pre
gl_fog_blue=0.0
gl_fog_red=0.0
gl_fog_green=0.0
gl_fog_start=.989
gs_farclipplane_set 5000
my_save_point = save_point;
if (my_save_point eq 0) {
dmsg "Zaraz zacznie sie mlucka kolo hangarow."
chr_inv_reset 0
chr_teleport 0 22
chr_set_health 200
dmsg " Walcz z Syndykatem. "
chr_giveweapon 0 w3_phr
chr_givepowerup 0 ammo 1
chr_givepowerup 0 cell 1
chr_givepowerup 0 shield 51
sleep 100
fork wave0
killed_griffen 1
}
if (my_save_point eq 1)
{
save_point=1;
restore_game
GrifOPS01respawn
fork wave1
}
if (my_save_point eq 2)
{
save_point=2;
restore_game
GrifOPS01respawn
GrifOps02respawn
fork wave2
}
if (my_save_point eq 3)
{
save_point=3;
restore_game
GrifOPS01respawn
GrifOps02respawn
fork wave3
}
if (my_save_point eq 4)
{
}
}
#######################################################
func void GrifoPS01DeathCheck(void) {
chr_wait_health GrifOps01 0
chr_givepowerup 0 lsi
# givepowerup lsi
}
func GrifOps02DeathCheck {
chr_wait_health GrifOps02 0
killed_griffen 1
}
func GrifOPS01respawn {
if(!chr_has_lsi(0))
SpawnNameFlagHealthReset GrifOps01 23
}
func GrifOps02respawn {
if(did_kill_griffen() eq 0)
SpawnNameFlagHealthReset GrifOps02 23
}
#######################################################
func void wave0(void){
dmsg " Pomoga ci w tym agenci TCTF. "
sleep 200
dmsg "[r. Druzyna Pyrpeciarza.]"
SpawnNameFlagHealthReset GrifOps01 23
SpawnNameFlagReset F_C62 22
SpawnNameFlagHealthReset shooter_dummy 22 30 1
SpawnNameFlagReset A_E5b 22 1
chr_givepowerup GrifOps01 shield 110
chr_wait_health A_E5b 0
dmsg "[g. Pyrpeciarz zabity.]"
chr_wait_health shooter_dummy 0
chr_wait_health F_C62 0
dmsg "[r. Druzyna Mlyna .]"
SpawnNameFlagHealthReset ParkStriker 22
SpawnNameFlagHealthReset A_Sb8 22
SpawnNameFlagHealthReset C_Sr18 22
chr_set_health GrifOps01 90
chr_wait_health C_Sr18 0
dmsg "[g. Mlynek Zabity.]"
chr_wait_health A_Sb8 0
chr_wait_health ParkStriker 0
sleep 400
dmsg "[r. Druzyna Krowy.]"
SpawnNameFlagHealthReset C_Sr19 22
SpawnNameFlagHealthReset C_Eb22 22
SpawnNameFlagHealthReset C_Sb26 22
SpawnNameFlagHealthReset C_Eb21 22
chr_set_health GrifOps01 90
ai2_attack C_Eb21 0
chr_wait_health C_Eb21 0
chr_wait_health C_Eb22 0
chr_wait_health C_Sb26 0
chr_wait_health C_Sr19 0
sleep 200
fork GrifoPS01DeathCheck
save_game 1 autosave
wave1
}
func void wave1(void){
sleep 100
ai2_spawn A_S1
chr_teleport A_S1 24
chr_givepowerup 0 shield 50
chr_givepowerup GrifOps01 shield 50
chr_set_health GrifOps01 90
sleep 600
SpawnNameFlagHealthReset C_Sb78 22
SpawnNameFlagHealthReset C_Sb76 22
SpawnNameFlagHealthReset target_dummy 22
chr_set_health target_dummy 45
ai2_attack A_S1 0
chr_givepowerup GrifOps01 cell 3
chr_wait_health A_S1 0
dmsg "[g. Snajper unieszkodliwiony.]"
chr_wait_health C_Sb76 0
chr_wait_health C_Eb22 0
chr_wait_health target_dummy 0
sleep 100
dmsg "[g. Pomoc z kwatery glownej.]"
SpawnNameFlagHealthReset GrifOps02 23
chr_giveweapon GrifOps02 w3_phr
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_givepowerup GrifOps02 ammo 1
chr_givepowerup GrifOps01 cell 1
chr_givepowerup GrifOps02 cell 1
chr_givepowerup GrifOps01 ammo 2
dmsg "Wiedz, ze ten agent TCTF ma wszczepiony eksperymentalny Crystalis i jego pasek zycia jest o 1/3 wiekszy niz zwykle."
sleep 88
dmsg "Agenci maja apteczki ktorych uzywaja po kazdej walce"
sleep 100
dmsg "[r. Kobitki atakuja]"
SpawnNameFlagReset GrifElite03 22 1
SpawnNameFlagHealthReset GrifElite02 22
SpawnNameFlagReset D_R31 22 1
SpawnNameFlagReset D_R33 22 1
SpawnNameFlagHealthReset F_R61 22
dmsg "[g. Burdelmama nie zyje.]"
chr_wait_health GrifElite02
chr_wait_health D_R31 0
chr_wait_health D_R33 0
chr_wait_health F_R61 0
fork GrifoPS01DeathCheck
fork GrifOps02DeathCheck
save_game 2 autosave
wave2
}
func void wave2(void){
sleep 100
dmsg "[r. Nindza z Pincza.]"
SpawnNameFlagReset C_Tr28 22 1
SpawnNameFlagReset E_Nr36 22 1
SpawnNameFlagReset E_Nb38 22 1
SpawnNameFlagReset E_Tr40 22 1
SpawnNameFlagReset E_Nr39 22 1
SpawnNameFlagReset GrifElite06 23 1
chr_givepowerup GrifOps02 ammo 1
chr_givepowerup GrifOps01 cell 1
chr_givepowerup GrifOps02 cell 1
chr_givepowerup GrifOps01 ammo 2
chr_teleport GrifElite06 22
chr_set_health GrifOps01 90
chr_set_health GrifOps02 120
chr_giveweapon GrifOps02 w1_tap
chr_giveweapon GrifOps01 w2_sap
chr_wait_health C_Tr28 0
chr_wait_health E_Nr36 0
chr_wait_health E_Nb38 0
chr_wait_health E_Tr40
sleep 900
dmsg "[r. Uwaga!!! Snajper.]"
SpawnNameFlagHealthReset A_S2 24
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_wait_health A_S2 0
dmsg "[g. Snajper unieszkodliwiony.]"
sleep 600
SpawnNameFlagHealthReset A_E5 22
SpawnNameFlagHealthReset B_Eb11 22
SpawnNameFlagHealthReset B_Esb15 22
SpawnNameFlagHealthReset E_Eb35 22
SpawnNameFlagHealthReset GrifElite01 22
chr_wait_health GrifElite01 0
dmsg "[g. Mucka padla na ziemie.]"
chr_wait_health A_E5 0
chr_wait_health B_Eb11 0
chr_wait_health B_Esb15 0
chr_wait_health E_Eb35 0
dmsg "[g. Posilki z TCTF.]"
SpawnNameFlagHealthReset GrifOps03 23 150
chr_giveweapon GrifOps03 w3_phr
chr_giveweapon GrifOps02 w1_tap
chr_giveweapon GrifOps01 w2_sap
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_givepowerup GrifOps01 cell 3
chr_givepowerup GrifOps02 cell 2
chr_givepowerup GrifOps03 cell 1
chr_givepowerup GrifOps01 ammo 3
chr_givepowerup GrifOps02 ammo 2
chr_givepowerup GrifOps03 ammo 1
chr_givepowerup GrifOps01 shield 200
chr_givepowerup GrifOps02 shield 80
chr_givepowerup GrifOps03 shield 40
fork GrifoPS01DeathCheck
fork GrifOps02DeathCheck
save_game 3 autosave
fork wave3
}
func void wave3(void){
dmsg "[g. Udalo sie.]"
sleep 300
dmsg "[r. Mieszanka Krakowska atakuje.]"
SpawnNameFlagHealthReset A_E3
ai2_spawn A_E4
SpawnNameFlagHealthReset A_Sb7 22
SpawnNameFlagHealthReset C_Sr17 22
SpawnNameFlagHealthReset F_Nr60 22
SpawnNameFlagHealthReset E_R46 22
SpawnNameFlagHealthReset E_Nr46 22
chr_teleport A_E3 22
chr_teleport A_E4 22
chr_teleport C_Sr17 22
chr_wait_health A_E4 0
dmsg "[g. Cukierek wypadl z papierka.]"
chr_wait_health A_E3 0
chr_wait_health A_Sb7 0
chr_wait_health C_Sr17 0
chr_wait_health F_Nr60 0
chr_wait_health E_R46 0
chr_wait_health E_Nr46 0
sleep 900
dmsg "[r. Ulemniacy nadchodza.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
SpawnNameFlagReset new_2 22 1
SpawnNameFlagHealthReset F_Er89 22 80 1
SpawnNameFlagHealthReset F_Nr87 22 55 1
SpawnNameFlagHealthReset C_Sb77 22 50 1
SpawnNameFlagHealthReset C_Sb75 22 60 1
SpawnNameFlagHealthReset F_Eb47 22 40 1
SpawnNameFlagHealthReset A_E3b 22 50 1
SpawnNameFlagHealthReset E_Nb37 22 30 1
SpawnNameFlagHealthReset C_Eb30 22 79 1
SpawnNameFlagHealthReset B_N1 22 55 1
chr_changeteam B_N1 Syndicate
chr_wait_health new_2 0
chr_wait_health F_Nr87 0
chr_wait_health F_Er89 0
chr_wait_health C_Sb77 0
chr_wait_health C_Sb75 0
chr_wait_health F_Eb47 0
chr_wait_health A_E3b 0
chr_wait_health E_Nb37 0
chr_wait_health C_Eb30 0
#chr_wait_health B_N1 1
chr_wait_health B_N1 0
dmsg "[g. Griffin przybywa.]"
SpawnNameFlagHealthReset Griffin 23 600
# I'm trying to prevent a bug.. (paradox-01)
SpawnNameFlagHealthReset GrifOps01 22 90
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
# chr_set_health GrifOps01 90
sleep 300
dmsg "[r. Muro!!!.]"
# SpawnNameFlagHealthReset Muro 22 2500
# for tests
# remember that griffen = GrifOps02 here...
# if GrifOps don't died MutantMuro will appear .. omg^^
# ähm, no instead of GrifOps02 I took a 'bad guy'
# test-wise we will spawn him with 0 HP, so he's dead..
SpawnNameFlagHealthReset C_Eb30 22 0
fork GrifoPS02DeathCheck
fork mutant
fork muro
}
func mutant{
if (did_kill_griffen() eq 0)
{
SpawnNameFlagHealthReset MutantMuro 22 400
chr_boss_shield MutantMuro
chr_wait_health MutantMuro 0
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_set_health Griffin 600
sleep 300
dmsg "[g. Zwyciestwo.]"
sleep 100
dmsg "[g. Narka.]
sleep 200
dmsg "[g. Brawo, calkowice wygrales.]
#it means " Bravo, you win completly"
sleep 600
endgame
}
}
# we could write "if(!did_kill_griffen())" .. what's the matter, geyser ^^
func muro{
if (did_kill_griffen() eq 1)
{
SpawnNameFlagHealthReset Muro 22 300
chr_wait_health Muro
}
sleep 300
dmsg "[g. Udalo sie.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_set_health Griffin 600
sleep 300
dmsg "[g. Zwyciestwo.]"
sleep 100
dmsg "[g. Narka.]
sleep 200
dmsg "[g. Sprobuj dojsc tutaj, z zywymi agentami TCTF.]
#it means " try kill muro withch alive TCTF agents"
sleep 600
endgame
}
########################
func void you_lose(string ai_name)
{
sleep 240
fade_out 0 0 0 180
sleep 240
lose
}
########################
func void endgame(string ai_name)
{
sleep f120
chr_animate 0 KONOKOendpowerup
sleep f120
cm_interpolate EndCam 600
sleep f500
fade_out 0 0 0 120
sleep f120
win
}
########################
#snow for the airfield
func void snow1_start(string ai_name)
{
dprint snow1_start
particle snow1 start
}
func void snow2_start(string ai_name)
{
dprint snow2_start
particle snow2 start
}
func void snow3_start(string ai_name)
{
dprint snow3_start
particle snow3 start
}
hmmm, i use that and everything is working perfecly.
Only muro isn`t spawn, hmmm, i try repeair this evening.
And i hate Rapidshare because i have static IP with 1000 other people so now i must wait 141 minutes or 121 ;(
edit: why i can`t spawn muro?? i i try spawn him before griffin but he doesn`t spawn. I searching for "}{" and i don`t find anything ;(
Last edited by Tantir (06/20/07 09:06)
Offline
How about this provider then? http://www.savefile.com/files/825550
Idea about your code (but I didn't tested yet):
func mutant{
if (did_kill_griffen() eq 0)
{
SpawnNameFlagHealthReset MutantMuro 22 400
chr_boss_shield MutantMuro
chr_wait_health MutantMuro 0
maybe placing a } here? instead at the end of func muro (no double, you know).
______________________________
Test results:
- I load SP3, kill some guys, griffin spawned, then: crash...
- I changed the position of } Okay it didn't crashed but Muro didn't appear and "endgame" came next...
Last edited by paradox-01 (06/20/07 10:06)
Offline
Forgot the } You was right Tantir. But I found the bug why muro is not spawning.
You wrote:
func GrifOps02DeathCheck {...}
and then
fork GrifoPS02DeathCheck
Do you see the difference? Hm, Oni is very exactly so we have to be^^
Offline
SpawnNameFlagHealthReset Griffin 23 600
SpawnNameFlagHealthReset muro 22 400
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
sleep 300
GrifOps02DeathCheck
fork muro
fork mutant
}
func muro
{
if (did_kill_griffen() eq 1)
{ SpawnNameFlagHealthReset Muro 22 600 }
sleep 300
dmsg "[g. Udalo sie.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_set_health Griffin 600
sleep 300
dmsg "[g. Zwyciestwo.]"
sleep 100
dmsg "[g. Narka.]
sleep 200
dmsg "[g. Sprobuj dojsc tutaj, z zywymi agentami TCTF.]
#it means " try kill muro withch alive TCTF agents"
sleep 600
endgame }
func mutant {
if (did_kill_griffen() eq 0)
{
SpawnNameFlagHealthReset MutantMuro 22 400
}
chr_wait_health MutantMuro 0
sleep 300
dmsg "[g. Udalo sie.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_set_health Griffin 600
sleep 300
dmsg "[g. Zwyciestwo.]"
sleep 100
dmsg "[g. Narka.]
sleep 200
Now everything works. Only Muro not spawned.
hmm, and when we understood why muro is not spawned, should clean script ;P.
Offline
hmm, and when we understood why muro is not spawned, should clean script ;P.
hmmmmmmmmmmmmmmmmmmmmmmmmm, no
You have to clean up the script in order to understand.
Or go through my last list of remarks and warnings...
There I already told you why Muro will never spawn.
EDIT: I can give you a totally debugged version tonight.
But I suggest you try to understand what's wrong before I do.
Muro is not the only problem (there are many other bugs...)
But Muro is the one I already detailed in one of my posts.
I also told you how to track down mistakes efficiently.
(by simplifying the logic and using dprint or dmsg)
Last edited by geyser (06/20/07 13:06)
Behold the power of that which is yet unborn! For the swirling images that flow forth from the Chrysalis are only a shadow of the sleeper's true power.
Offline
Ahm, where do "chr_wait_health Muro 0" get lost ?
No - unfortunately there are enough bugs, okay geyser just do it. (Really, I fell a bit sorry for you )
@ Tantir: Hey the ultra mode ("chr_ultra_mode") is back.^^ Lets add it after geyser finish debugging.
Last edited by paradox-01 (06/20/07 15:06)
Offline
I would like to request an English translation of the ingame messages, please.
Last edited by EdT (06/20/07 15:06)
Offline
EdT - of coure, i translete it. I don`t do that yet, because when i creating (copying) this script i don`t think I send it to this forum. I translete it after geyser finish debuging.
And I know (i guess) why muro is not spawned.
func muro
{
if (did_kill_griffen() eq 1)
{ SpawnNameFlagHealthReset Muro 22 600 }
{
sleep 300
dmsg "[g. Udalo sie.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_set_health Griffin 600
sleep 300
dmsg "[g. Zwyciestwo.]"
sleep 100
dmsg "[g. Narka.]
sleep 200
dmsg "[g. Sprobuj dojsc tutaj, z zywymi agentami TCTF.]
#it means " try kill muro withch alive TCTF agents"
sleep 600
endgame }
}
I can`t try it because I useing "virusedcomp" and lastest version of my script is on diffrent PC and i haven`t access to them. (I`m probably wrong)
Offline
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
sleep 300
GrifOps02DeathCheck
fork muro
fork mutant
sleep 200
fork murodeathcheck
fork mutantdeathcheck
}
func muro {
if(did_kill_griffen() eq 1)
SpawnNameFlagHealthReset Muro 22
}
func mutant {
if(did_kill_griffen() eq 0)
SpawnNameFlagHealthReset MutantMuro 22
}
func murodeathcheck {
chr_wait_health Muro 0
endgame }
func mutantdeathcheck {
chr_wait_health MutantMuro 0
endgame }
########################
func void you_lose(string ai_name)
{
sleep 24
fade_out 0 0 0 180
sleep 240
Don`t read my post above. Its @@@@.
I add extra {} so muro was not spawned. Now everything (really) is working.
Offline
Maybe my PC hates me. ^^
However.. I'm not sure having a totally synchronized script yet.
So please make a attachment of your whole working file.
Offline
Hmmm, in my PC everything working. I can`t make attachment now but I make it soon;).
Offline
Everything, are you sure?
Behold the power of that which is yet unborn! For the swirling images that flow forth from the Chrysalis are only a shadow of the sleeper's true power.
Offline
Hmm, maybe NOT everything, but Muro yes.
Edit
var int my_save_point=0;
func pre(void) {
# launch Oni Menu if you have it
# fork om_core_3
fork super_kick
fork super_punch
# following is for testing
# fork surprise_timer_0
}
func super_punch(void) {
chr_wait_animation 0 KONCOMcomb_p_p_p
slowmo 240
chr_animate 0 KONCOMsuper_punch
sleep 50
fork super_punch
}
func super_kick(void) {
chr_wait_animation 0 KONCOMcomb_p_p_k
slowmo 240
chr_animate 0 KONCOMsuper_kick
sleep 50
fork super_kick
}
func SpawnNameFlagHealthReset(string n, int f, int h, int r){
ai2_spawn(n); chr_teleport(n, f)
if(h) chr_set_health(n, h)
if(r) chr_inv_reset(n)
}
func SpawnNameFlagReset(string n, int f, int r){
ai2_spawn(n); chr_teleport(n, f)
if(r) chr_inv_reset(n)
}
#######################################################
func void main(void)
{
env_show 401 1
env_shade 401 913 .2 .4 .2
env_show 402 1
env_shade 401 913 .2 .1 .3
env_show 403 1
env_shade 401 913 .3 .1 .3
env_show 404 1
env_shade 401 913 .3 .2 .1
env_show 405 1
env_shade 401 913 .1 .3 .2
env_show 406 1
env_shade 401 913 .2 .1 .4
env_show 407 1
env_shade 401 913 .1 .4 .1
env_show 408 1
env_shade 401 913 .4 .4 .1
env_show 409 1
particle dishpulse do start
particle sturm_ambient start
fork pre
gl_fog_blue=0.0
gl_fog_red=0.0
gl_fog_green=0.0
gl_fog_start=.989
gs_farclipplane_set 5000
my_save_point = save_point;
if (my_save_point eq 0) {
dmsg "Zaraz zacznie sie mlucka kolo hangarow."
chr_inv_reset 0
chr_teleport 0 22
chr_set_health 200
dmsg " Walcz z Syndykatem. "
chr_giveweapon 0 w3_phr
chr_givepowerup 0 ammo 1
chr_givepowerup 0 cell 1
chr_givepowerup 0 shield 51
sleep 100
fork wave0
killed_griffen 0
}
if (my_save_point eq 1)
{
save_point=1;
restore_game
GrifOPS01respawn
fork wave1
}
if (my_save_point eq 2)
{
save_point=2;
restore_game
GrifOPS01respawn
GrifOps02respawn
fork wave2
}
if (my_save_point eq 3)
{
save_point=3;
restore_game
GrifOPS01respawn
GrifOps02respawn
fork wave3
}
if (my_save_point eq 4)
{
}
}
#######################################################
func void GrifoPS01DeathCheck(void) {
chr_wait_health GrifOps01 0
chr_givepowerup 0 lsi
# givepowerup lsi
}
func GrifOps02DeathCheck {
chr_wait_health GrifOps02 0
killed_griffen 1
}
func GrifOPS01respawn {
if(!chr_has_lsi(0))
SpawnNameFlagHealthReset GrifOps01 23
}
func GrifOps02respawn {
if(did_kill_griffen() eq 0)
SpawnNameFlagHealthReset GrifOps02 23
}
#######################################################
func void wave0(void){
dmsg " Pomoga ci w tym agenci TCTF. "
sleep 200
dmsg "[r. Druzyna Pyrpeciarza.]"
SpawnNameFlagHealthReset GrifOps01 23
SpawnNameFlagReset F_C62 22
SpawnNameFlagHealthReset shooter_dummy 22 30 1
SpawnNameFlagReset A_E5b 22 1
chr_givepowerup GrifOps01 shield 110
chr_wait_health A_E5b 0
dmsg "[g. Pyrpeciarz zabity.]"
chr_wait_health shooter_dummy 0
chr_wait_health F_C62 0
dmsg "[r. Druzyna Mlyna .]"
SpawnNameFlagHealthReset ParkStriker 22
SpawnNameFlagHealthReset A_Sb8 22
SpawnNameFlagHealthReset C_Sr18 22
chr_set_health GrifOps01 90
chr_wait_health C_Sr18 0
dmsg "[g. Mlynek Zabity.]"
chr_wait_health A_Sb8 0
chr_wait_health ParkStriker 0
sleep 400
dmsg "[r. Druzyna Krowy.]"
SpawnNameFlagHealthReset C_Sr19 22
SpawnNameFlagHealthReset C_Eb22 22
SpawnNameFlagHealthReset C_Sb26 22
SpawnNameFlagHealthReset C_Eb21 22
chr_set_health GrifOps01 90
ai2_attack C_Eb21 0
chr_wait_health C_Eb21 0
chr_wait_health C_Eb22 0
chr_wait_health C_Sb26 0
chr_wait_health C_Sr19 0
sleep 200
fork GrifoPS01DeathCheck
save_game 1 autosave
wave1
}
func void wave1(void){
sleep 100
ai2_spawn A_S1
chr_teleport A_S1 24
chr_givepowerup 0 shield 50
chr_givepowerup GrifOps01 shield 50
chr_set_health GrifOps01 90
sleep 600
SpawnNameFlagHealthReset C_Sb78 22
SpawnNameFlagHealthReset C_Sb76 22
SpawnNameFlagHealthReset target_dummy 22
chr_set_health target_dummy 45
ai2_attack A_S1 0
chr_givepowerup GrifOps01 cell 3
chr_wait_health A_S1 0
dmsg "[g. Snajper unieszkodliwiony.]"
chr_wait_health C_Sb76 0
chr_wait_health C_Eb22 0
chr_wait_health target_dummy 0
sleep 100
dmsg "[g. Pomoc z kwatery glownej.]"
SpawnNameFlagHealthReset GrifOps02 23
chr_giveweapon GrifOps02 w3_phr
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_givepowerup GrifOps02 ammo 1
chr_givepowerup GrifOps01 cell 1
chr_givepowerup GrifOps02 cell 1
chr_givepowerup GrifOps01 ammo 2
dmsg "Wiedz, ze ten agent TCTF ma wszczepiony eksperymentalny Crystalis i jego pasek zycia jest o 1/3 wiekszy niz zwykle."
sleep 88
dmsg "Agenci maja apteczki ktorych uzywaja po kazdej walce"
sleep 100
dmsg "[r. Kobitki atakuja]"
SpawnNameFlagReset GrifElite03 22 1
SpawnNameFlagHealthReset GrifElite02 22
SpawnNameFlagReset D_R31 22 1
SpawnNameFlagReset D_R33 22 1
SpawnNameFlagHealthReset F_R61 22
dmsg "[g. Burdelmama nie zyje.]"
chr_wait_health GrifElite02
chr_wait_health D_R31 0
chr_wait_health D_R33 0
chr_wait_health F_R61 0
fork GrifoPS01DeathCheck
fork GrifOps02DeathCheck
save_game 2 autosave
wave2
}
func void wave2(void){
sleep 100
dmsg "[r. Nindza z Pincza.]"
SpawnNameFlagReset C_Tr28 22 1
SpawnNameFlagReset E_Nr36 22 1
SpawnNameFlagReset E_Nb38 22 1
SpawnNameFlagReset E_Tr40 22 1
SpawnNameFlagReset E_Nr39 22 1
SpawnNameFlagReset GrifElite06 23 1
chr_givepowerup GrifOps02 ammo 1
chr_givepowerup GrifOps01 cell 1
chr_givepowerup GrifOps02 cell 1
chr_givepowerup GrifOps01 ammo 2
chr_teleport GrifElite06 22
chr_set_health GrifOps01 90
chr_set_health GrifOps02 120
chr_giveweapon GrifOps02 w1_tap
chr_giveweapon GrifOps01 w2_sap
chr_wait_health C_Tr28 0
chr_wait_health E_Nr36 0
chr_wait_health E_Nb38 0
chr_wait_health E_Tr40
sleep 900
dmsg "[r. Uwaga!!! Snajper.]"
SpawnNameFlagHealthReset A_S2 24
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_wait_health A_S2 0
dmsg "[g. Snajper unieszkodliwiony.]"
sleep 600
SpawnNameFlagHealthReset A_E5 22
SpawnNameFlagHealthReset B_Eb11 22
SpawnNameFlagHealthReset B_Esb15 22
SpawnNameFlagHealthReset E_Eb35 22
SpawnNameFlagHealthReset GrifElite01 22
chr_wait_health GrifElite01 0
dmsg "[g. Mucka padla na ziemie.]"
chr_wait_health A_E5 0
chr_wait_health B_Eb11 0
chr_wait_health B_Esb15 0
chr_wait_health E_Eb35 0
dmsg "[g. Posilki z TCTF.]"
SpawnNameFlagHealthReset GrifOps03 23 150
chr_giveweapon GrifOps03 w3_phr
chr_giveweapon GrifOps02 w1_tap
chr_giveweapon GrifOps01 w2_sap
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
chr_givepowerup GrifOps01 cell 3
chr_givepowerup GrifOps02 cell 2
chr_givepowerup GrifOps03 cell 1
chr_givepowerup GrifOps01 ammo 3
chr_givepowerup GrifOps02 ammo 2
chr_givepowerup GrifOps03 ammo 1
chr_givepowerup GrifOps01 shield 200
chr_givepowerup GrifOps02 shield 80
chr_givepowerup GrifOps03 shield 40
fork GrifoPS01DeathCheck
fork GrifOps02DeathCheck
save_game 3 autosave
fork wave3
}
func void wave3(void){
dmsg "[g. Udalo sie.]"
sleep 300
dmsg "[r. Mieszanka Krakowska atakuje.]"
SpawnNameFlagHealthReset A_E3
ai2_spawn A_E4
SpawnNameFlagHealthReset A_Sb7 22
SpawnNameFlagHealthReset C_Sr17 22
SpawnNameFlagHealthReset F_Nr60 22
SpawnNameFlagHealthReset E_R46 22
SpawnNameFlagHealthReset E_Nr46 22
chr_teleport A_E3 22
chr_teleport A_E4 22
chr_teleport C_Sr17 22
chr_wait_health A_E4 0
dmsg "[g. Cukierek wypadl z papierka.]"
chr_wait_health A_E3 0
chr_wait_health A_Sb7 0
chr_wait_health C_Sr17 0
chr_wait_health F_Nr60 0
chr_wait_health E_R46 0
chr_wait_health E_Nr46 0
sleep 900
dmsg "[r. Ulemniacy nadchodza.]"
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
SpawnNameFlagReset new_2 22 1
SpawnNameFlagHealthReset F_Er89 22 80 1
SpawnNameFlagHealthReset F_Nr87 22 55 1
SpawnNameFlagHealthReset C_Sb77 22 50 1
SpawnNameFlagHealthReset C_Sb75 22 60 1
SpawnNameFlagHealthReset F_Eb47 22 40 1
SpawnNameFlagHealthReset A_E3b 22 50 1
SpawnNameFlagHealthReset E_Nb37 22 30 1
SpawnNameFlagHealthReset C_Eb30 22 79 1
SpawnNameFlagHealthReset B_N1 22 55 1
chr_changeteam B_N1 Syndicate
chr_wait_health new_2 0
chr_wait_health F_Nr87 0
chr_wait_health F_Er89 0
chr_wait_health C_Sb77 0
chr_wait_health C_Sb75 0
chr_wait_health F_Eb47 0
chr_wait_health A_E3b 0
chr_wait_health E_Nb37 0
chr_wait_health C_Eb30 0
#chr_wait_health B_N1 1
chr_wait_health B_N1 0
dmsg "[g. Griffin przybywa.]"
SpawnNameFlagHealthReset Griffin 23 600
SpawnNameFlagHealthReset muro 22 400
chr_set_health GrifOps03 150
chr_set_health GrifOps02 120
chr_set_health GrifOps01 90
sleep 300
GrifOps02DeathCheck
fork muro
fork mutant
sleep 100
fork murodeathcheck
fork mutantdeathcheck
}
func muro {
if(did_kill_griffen() eq 1)
SpawnNameFlagHealthReset Muro 22
}
func mutant {
if(did_kill_griffen() eq 0)
SpawnNameFlagHealthReset MutantMuro 22
}
func murodeathcheck {
chr_wait_health Muro 0
fork endgame }
func mutantdeathcheck {
chr_wait_health Muro 0
fork endgame }
########################
func void you_lose(string ai_name)
{
sleep 24
fade_out 0 0 0 180
sleep 240
lose
}
########################
func void endgame(string ai_name)
{
sleep f120
chr_animate 0 KONOKOendpowerup
sleep f120
cm_interpolate EndCam 600
sleep f500
fade_out 0 0 0 120
sleep f120
win
}
########################
#snow for the airfield
func void snow1_start(string ai_name)
{
dprint snow1_start
particle snow1 start
}
func void snow2_start(string ai_name)
{
dprint snow2_start
particle snow2 start
}
func void snow3_start(string ai_name)
{
dprint snow3_start
particle snow3 start
}
Hmm, I was wrong. Muro is spawned but murodeathcheck isnt working. D@@n i have holydays and i have less time then normal....
Last edited by Tantir (06/23/07 07:06)
Offline