Help with Thunder

kdo

Member
I need some help here, im trying to make a palyer cast a thunder that fall from sky and damage enemy and players, but when the player spawn the thunder entity the engine crashes. im used this.

Player:
Pikachu.txt

anim freespecial2
        spawnframe  9 1 1 1 1
        subentity  Thu
bbox 85 72 18 26
delay 10
offset 94 102
frame data/chars/pikachu/ata1.png
frame data/chars/pikachu/ata2.png
frame data/chars/pikachu/ata3.png
frame data/chars/pikachu/ata4.png
frame data/chars/pikachu/ata5.png
frame data/chars/pikachu/ata6.png
frame data/chars/pikachu/ata7.png
frame data/chars/pikachu/ata8.png
frame data/chars/pikachu/ata9.png
frame data/chars/pikachu/ata10.png
frame data/chars/pikachu/ata11.png

Thunder entity :

Thu.txt

name Thu
health 1
speed 10
type enemy
shadow 0
candamage obstacle enemy player
setlayer 100




anim idle

offset 250 102
delay 6
loop 1
attack 45 2 87 263 0 0 1 0 0 0
frame data/chars/pikachu/thu1.png
frame data/chars/pikachu/thu2.png
frame data/chars/pikachu/thu3.png
        frame data/chars/pikachu/thu4.png
frame data/chars/pikachu/thu5.png
frame data/chars/pikachu/thu6.png
frame data/chars/pikachu/thu7.png
frame data/chars/pikachu/thu8.png



Ps: The Thunder entity is load in level txt and load in character txt flag.

Thanks...



 
Hello magggas, you was right about Thunder Walk  animation and speed command, now the entity dont crashes the engine, its works , but it still hesnt the behaviour  that i need, the thunder is spawned but keep walking on the screen and dont disappier, its creazy .
Btw, i just need a thunder thats fall from sky and hit the ground once  or an enemy, or a palyer and desappier after cause damage.

Any idea about that?

Thanks  for help magggas...
 
Now its works perfect magggas....thank you so much!!! 

Could you help me with the parrow question? its an unsolved problem...

Thanks again magggas....
 
Magggas , i have to create 4 parrow entity one for each player?

The "ANI_FREESPECIAL26" in the script.... what does it mean? i have to create this freespecial?
 
Magggas , more questions,  :-[.

1 - In the model txt, i have to declarate all parrows as know....is that correct?
2 - Do i have to load the parrow in character flag or just put the scrpit line?

PS.. im trying .....but not sucess yet....thanks
 
Thanks magggas , im trying , but there is something wrong.. maybe the animation script... i wasnt using this script, after you talk about this, i just copyed the script function that you gave me and past in a new txt file and named it aniscript.c and placed in script folder.... maybe this is the problem...
what should i do?
 
Magggas...thanks again for all hel and suport.... you great !!!  but i still success less... the engine crashes...take a look...

1 - i put the aniscript in scripts folder.

2 - in models txt.

load parrow data/sprites/parrow.txt
load parrow2 data/sprites/parrow2.txt
load parrow3 data/sprites/parrow3.txt
load parrow4 data/sprites/parrow4.txt

3- i put the parrows txt and the gif in sprites folder

parrow.txt

name      parrow
type      none
shadow    0
nomove    1
nolife          1
antigravity    100


anim idle
      loop  0
  delay  20
  offset  77 170
  frame  data/sprites/parow.gif
  frame  data/sprites/hole.gif
  frame  data/sprites/parow.gif

PS. parow ( ,2,3,4)is the name of the gif image with just one "R"

4- in Pikachu txt.

animationscript data/scripts/aniscript.c

and

anim spawn
loop 1
bbox 85 75 17 24
delay 10
offset 93 102
frame data/chars/pikachu/stand1.png
frame data/chars/pikachu/stand2.png
frame data/chars/pikachu/stand3.png
frame data/chars/pikachu/stand4.png
        @cmd    spawnbind2 "parrow" "parrow2"  "parrow3" "parrow4" 0 1 0 
frame data/chars/pikachu/stand5.png
frame data/chars/pikachu/stand6.png
frame data/chars/pikachu/stand7.png

anim respawn
loop 1
bbox 85 75 17 24
delay 10
offset 93 102
frame data/chars/pikachu/stand1.png
frame data/chars/pikachu/stand2.png
frame data/chars/pikachu/stand3.png
frame data/chars/pikachu/stand4.png
        @cmd    spawnbind2 "parrow" "parrow2"  "parrow3" "parrow4" 0 1 0   
frame data/chars/pikachu/stand5.png
frame data/chars/pikachu/stand6.png
frame data/chars/pikachu/stand7.png

 
Magggas here is the log....

OpenBoR v3.0 Build 2174, Compile Date: Mar 22 2009

Game Selected: ./Paks/My Mod.pak

Initilize Video.............. 320x240
Loading video mode........... Done!
Loading menu.txt............. Done!
Loading fonts................ Done!
Timer init................... Done!
Initilize Sound..............
Failed to load: data/sounds/block.wav

Loading sprites.............. Done!
Loading level order.......... Done!
Loading script settings...... Done!
Loading scripts.............. Done!
Loading models...............

Cacheing 'Flash'
Cacheing 'Fire1'
Cacheing 'flecha1'
Cacheing 'Fireball'
Cacheing 'dust'
Cacheing 'Ded'
Cacheing 'Mega'
Cacheing 'Mega2'
Cacheing 'sho'
Cacheing 'Thu'
Cacheing 'Attack'
Cacheing 'lukito'
Cacheing 'Mario'
Cacheing 'link'
Cacheing 'Pikachu'
Cacheing 'Megaman'
Cacheing 'Hagane'
Cacheing 'Apple'
Cacheing 'Meat'
Cacheing '1up'
Cacheing 'Money'
Cacheing 'Gold'
Cacheing 'Time'
Cacheing 'Empty'
Cacheing 'Plat03'
Cacheing 'SPlat'
Cacheing 'bloc'

Object engine init........... Done!
Input init................... No Joystick(s) Found!



************ Shutting Down ************

Total Ram: 1322106880 Bytes
Free  Ram: 1305247744 Bytes
Used  Ram: 16834560 Bytes

Release level data........... Done!
Release graphics data........ Done!
Release game data............ Done!
Release timer................ Done!
Release input hardware....... Done!
Release sound system......... Done!

**************** Done *****************

OpenBoR v3.0 Build 2174, Compile Date: Mar 22 2009
Presented by Team Senile.
This Version is unofficial and based on the Senile Source Code.

Special thanks to SEGA and SNK.

font_load: 90562 bytes in 512 allocs
Total Leaked Bytes 90562



Script log

####animationscript function main#####
# data/chars/pikachu/thu.txt
########################################
void main()
{
    int frame = getlocalvar("frame");
    int animnum = getlocalvar("animnum");
    if(animnum==0)
    {
        if(frame==8)
        {
            killentity(getlocalvar("self"));

        }
        return;
    }

}


 
Magggas , now im using OpenBOR_v3.0_Build_4082...im doing in this version couse this is suported by Dreamcast...i really want make it works for Dreamcast....this is something like a tribute for this great console.
Btw, chage to a newer version of openbor gave me some troubles, my stage has chage some position of panels ...it will give some work... the menu position in selecte game mode has change too...but...the goode new is that parrow in default mod works for all 4 player whithout script in respawn animation...but i'll try to use your's.
Thanks ...
 
Thanks magggas, This is my first mod, so im learning much with you and other guys here...its very cool!!! i will try to make a dreamcast version and probably another version when i get more skilled, anyway i'll try your script in this version of openbor...thanks ...probably i 'll ask you some help in other stuffs ... ;)
 
Back
Top Bottom