Welcome, Guest. Please login or register.

What openbor you prefer: Double dragon,battletoads or final fight !? by lirexpatrio
[December 07, 2012, 07:15:27 pm]


what are your favorite games OpenBOR?! by lirexpatrio
[December 07, 2012, 07:09:46 pm]


Post Some Awesome Videos by maxman
[December 07, 2012, 05:51:39 pm]


Can @cmd playmusic "aaaa" 1 also increse music sound ? by BeasTie
[December 07, 2012, 05:24:38 pm]


Streets of Rage: Silent Storm by mtrain
[December 07, 2012, 03:45:05 pm]


Site will be down for maintenance on 12/8/2012 thru 12/10/2012 by Damon Caskey
[December 07, 2012, 07:42:42 am]


Cancelled SOR 3d Remake by riccochet
[December 07, 2012, 03:58:33 am]


Dungeon Fighter: B.O.R. by msmalik681
[December 07, 2012, 03:24:27 am]


[TUTORIAL] How to create 4 Games of OpenBOR in 1 CD (650 MB) by magggas
[December 06, 2012, 09:46:25 pm]


custknife by Bloodbane
[December 06, 2012, 09:34:09 pm]


blockfx help by B.Kardi
[December 06, 2012, 04:09:14 pm]


street of age 4 hd by corradlo
[December 06, 2012, 01:41:36 pm]


ClaFan - Classic Fantasy ver 1.17 by soniczxblade
[December 06, 2012, 05:01:20 am]


Bug Archive by Bloodbane
[December 06, 2012, 02:00:44 am]


"Bio-Doom" and "Gears of Doom" by BulletBob
[December 05, 2012, 10:07:21 pm]


Contra Locked 'N' Loaded v2 by Bloodbane
[December 05, 2012, 09:39:43 pm]


Downloadable OpenBoR Manual by BeasTie
[December 05, 2012, 08:31:24 pm]


Having trouble testing changes by B.Kardi
[December 05, 2012, 03:05:53 pm]


DragonBall Absalon by msmalik681
[December 05, 2012, 02:52:13 pm]


[Hi-Res] Swamp by Vibrant
[December 05, 2012, 10:47:14 am]


  • Dot Guests: 155
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.



Author Topic: openBorStats Tool  (Read 41527 times)

0 Members and 1 Guest are viewing this topic.

Offline Orochi_X

  • Hero Member
  • *****
  • Posts: 3301
  • Now! Count up your crimes.
Re: openBorStats Tool
« Reply #15 on: June 24, 2009, 04:29:08 pm »
Yes , you can add script directly in to an entity.txt file....

You place them between @script and @end_script


* Orochi_X says : " Sore ga doushita? " :looney:

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #16 on: June 24, 2009, 04:34:23 pm »
Yes , you can add script directly in to an entity.txt file....

You place them between @script and @end_script

Thanx, really useful to know, plus will make adjustments to handle for future development.
« Last Edit: September 06, 2011, 06:47:34 pm by MatMan »

Offline Orochi_X

  • Hero Member
  • *****
  • Posts: 3301
  • Now! Count up your crimes.
Re: openBorStats Tool
« Reply #17 on: June 24, 2009, 04:39:31 pm »
No problem!

I was digging around for an example but you ninja'd me so , umm , here it is!

Code: [Select]
anim attack1
loop 0
delay 8
bbox 30 5 27 79
offset 37 90
@script
if(frame == 0){
void self = getlocalvar("self");
if(playerkeys(getentityproperty(self, "playerindex"), 0, "movedown"))
{
    changeentityproperty(self, "animation", openborconstant("ANI_FOLLOW5"));
}
}
@end_script
frame data/chars/mai/P12_A075
offset 35 92
delay 3
bbox 32 10 43 76
        attack4 61 16 62 20 15 0 0 0 8 15
frame data/chars/mai/P12_A076
offset 35 82
bbox 27 6 52 72
frame data/chars/mai/P12_A077
        attack  0
offset 36 90
delay 7
bbox 30 5 27 79
frame data/chars/mai/P12_A075
offset 34 91
bbox 15 5 31 80
frame data/chars/mai/P12_A078



* Orochi_X says : " Sore ga doushita? " :looney:

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #18 on: June 24, 2009, 04:47:14 pm »
Can you place a script block inside a anim block or does it have to be either before it and/or after it and if its before it does it only work for that anim block and can you have multiple script blocks?

Sorry for bugging but I'm not actually looking into scripts at the moment (I'm sure there's resources on it), I'd just like to know plus minus how they work as i'm creating a character editor but I want to be able to add a area for scripts.

Offline Orochi_X

  • Hero Member
  • *****
  • Posts: 3301
  • Now! Count up your crimes.
Re: openBorStats Tool
« Reply #19 on: June 24, 2009, 04:57:02 pm »
You need to place it before the frame(s) you want it triggered on so you can either do one large script at the beginning or several smaller ones...

Code: [Select]
#Musasabi no Mai
anim freespecial1
landframe 8
        loop    0
        delay   7
offset 53 113
bbox 15 13 19 52
@script
if(frame == 0){
void self = getlocalvar("self");
if(playerkeys(getentityproperty(self, "playerindex"), 0, "attack3"))
{
setentityvar(self, 4, 2);
}else{
                        setentityvar(self, 4, 0);
                }
changeentityproperty(self, "tosstime", getentityproperty(self, "tosstime") + 28);
}
@end_script
frame data/chars/mai/P12_A11F
offset 29 122
frame data/chars/mai/P12_A120
offset 35 150
frame data/chars/mai/P12_A121
offset 33 122
frame data/chars/mai/P12_A11E
offset 52 129
@script
if(frame == 4){
void self = getlocalvar("self");
int x = getentityvar(self, 4);
int dir = getentityproperty(self, "direction");
if(dir == 1)
{
changeentityproperty(self, "velocity", 7+x, 0, -8+(x/2));
}
else
{
changeentityproperty(self, "velocity", -7-x, 0, -8+(x/2));
}
}
@end_script
        delay   5
frame data/chars/mai/P12_A030
frame data/chars/mai/P12_A031
frame data/chars/mai/P12_A032
@script
if(frame == 7){
void self = getlocalvar("self");
updateframe(self,  4);
}
@end_script
frame data/chars/mai/P12_A032
offset 30 80
        delay   7
frame data/chars/mai/P12_A11E
offset 21 80
        frame   data/chars/mai/P12_A020
        delay   15
offset 27 57
bbox 15 13 19 52
frame data/chars/mai/P12_A026
        delay   8
offset 22 71
bbox 15 13 19 52
frame data/chars/mai/P12_A01E


I almost forgot! You can also call external functions by placing them in an animationscript (the path is definable in the character header , animationscript {path} ) and then calling it with @cmd

@cmd functionname arg arg arg

These are always fired on the frame defined immediately after @cmd


* Orochi_X says : " Sore ga doushita? " :looney:

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #20 on: June 24, 2009, 05:02:56 pm »
I presume that after a script + anime is done its ended by a empty line to indicated to openBor that a new (script+anime) or (anime) will start.

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #21 on: June 25, 2009, 08:14:24 am »
Could anyone please tell me what the default value to the "z axis" is in the attack box (ie the value used when its null).

Offline Orochi_X

  • Hero Member
  • *****
  • Posts: 3301
  • Now! Count up your crimes.
Re: openBorStats Tool
« Reply #22 on: June 25, 2009, 09:41:23 am »
It defaults to their grabdistance. That defaults to 36 if not declared , if memory serves.


* Orochi_X says : " Sore ga doushita? " :looney:

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #23 on: June 25, 2009, 09:47:17 am »
It defaults to their grabdistance. That defaults to 36 if not declared , if memory serves.

Cool, thanx.

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #24 on: June 25, 2009, 11:27:04 pm »
Is the script engine case sensitive?

Offline Damon Caskey

  • Hero Member
  • *****
  • Posts: 5335
    • The Gorge
Re: openBorStats Tool
« Reply #25 on: June 26, 2009, 08:48:00 am »
Partially at least. I don't know if function names are case sensitive but I do know variants are.

int X != int x

DC
OpenBOR Wiki.

Coming Soon:
Spoiler
Fatal Fury Chronicals


Offline Bloodbane

  • Hero Member
  • *****
  • Posts: 7113
  • Dark Dragon
Re: openBorStats Tool
« Reply #26 on: June 27, 2009, 01:02:07 am »
How openBorStats came about was that I got tired of manually going through each Entity file and writing down the details I was looking for, to be able to create a well balanced calculation for the game, might even add a difficulty calculator but I'm thinking to far ahead cause I'll need to understand alot more of openBor as I haven't even climbed into scripting.

 I keep thinking about balance definition and it turns out whatever it is, it's different and not same per person's view. So if you want to make balanced calculation, please explain what exactly you mean by balanced.
 Difficulty calculator is even tougher. Aggresive enemies aren't always hard, if you can perform counterattack, those enemies will be defeated easily and look like an idiot.
 And moreover, difficulty is relative to players too. Players are us not the character in the mod here.
OpenBoR Manual

Basic OpenBoR Tutorials

OpenBoR Tricks & Tutorials

"The more often enemies attack, the more open they are to counter attacks"

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #27 on: June 27, 2009, 01:16:19 am »
How openBorStats came about was that I got tired of manually going through each Entity file and writing down the details I was looking for, to be able to create a well balanced calculation for the game, might even add a difficulty calculator but I'm thinking to far ahead cause I'll need to understand alot more of openBor as I haven't even climbed into scripting.

 I keep thinking about balance definition and it turns out whatever it is, it's different and not same per person's view. So if you want to make balanced calculation, please explain what exactly you mean by balanced.
 Difficulty calculator is even tougher. Aggresive enemies aren't always hard, if you can perform counterattack, those enemies will be defeated easily and look like an idiot.
 And moreover, difficulty is relative to players too. Players are us not the character in the mod here.

It ain't a easy thing to get done but its always possible and every really advanced game has some sort of system they work of by using the engine rules, game genre rules etc.... but its something that I won't be really doing for a long while. it was just a idea.

Offline MatMan

  • Moderator
  • Hero Member
  • *****
  • Posts: 1320
Re: openBorStats Tool
« Reply #28 on: June 27, 2009, 01:21:56 am »
How does openBor calculate the Attack z Depth that is used in openBor. Lets say I set the z Depth to 40, does it measure (in a isometric view) from a point, 20 pixels in and 20 pixels out or is it more complicated than that?

Offline Bloodbane

  • Hero Member
  • *****
  • Posts: 7113
  • Dark Dragon
Re: openBorStats Tool
« Reply #29 on: June 27, 2009, 01:26:50 am »
Quote
It defaults to their grabdistance. That defaults to 36 if not declared , if memory serves.

 Utunnels said it's grabdistance/3 or 36/3 for default.

Quote
Lets say I set the z Depth to 40, does it measure (in a isometric view) from a point, 20 pixels in and 20 pixels out or is it more complicated than that?

 No, it's 40 pixels in and out. And it's NOT isometric.
OpenBoR Manual

Basic OpenBoR Tutorials

OpenBoR Tricks & Tutorials

"The more often enemies attack, the more open they are to counter attacks"

 



 0%




SimplePortal 2.3.3 © 2008-2010, SimplePortal