News:

One Minute Game Review by The Happy Friar: https://ugetube.com/@OneMinteGameReviews
Also on Rumble: https://rumble.com/c/c-1115371

idTech 4 (aka Doom 3 tech) Discord Server! https://discord.gg/9wtCGHa

Main Menu

Spider mastermind model

Started by VGames, May 30, 2015, 01:05:43 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

VGames

Does anybody have the model and animations for the Spider Mastermind in this video?

https://m.youtube.com/watch?v=UTxyHbh-tzE

I tried the links but no good.
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

The Happy Friar

I want to say I have the recall to hell files SOMEWHERE.  Just not sure where...  Might of lost it when my HD went splat on me.

VGames

Hey thanks for the reply Friar but I was just about to post where I found a link to download a guys LMS add on that contains the very monster I was looking for. Here it is:

http://doom3coop.com/forum/viewtopic.php?t=3145&sid=6c4b007cbd7d83c093fb45e55dae3f8a
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

The Happy Friar

Cool, thanks for that link.

I'll still see if i can find the RTH zip.  I'm hesitant to post it publicly because it's not mine, but maybe a former team member can give permission or post it themselves.

The worst part about mods "these days" is that with Doom/Quake/Q2/Q3A there was no stigma if you released early and often: people loved seeing mods ASAP & didn't mind the bugs or unfinished content.  Now authors get heckled when it's not of good to AAA quality and they don't release early and often because of this.  Yeah, lots of old unfinished mods out there, but they can still be played vs an unfinished mod that "looks great" but is never "finished" and never released.

VGames

Yeah I was never part of that age in modding. When I got into it if u didn't have "good to AAA" quality stuff your mod was shunned. Releasing mods for me has always been a bit stressful. People tend to suck.
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

VGames

Ok I'm trying to implement this Spider Mastermind but I'm getting the error: Can't find function "Torso_Idle" in Monster_Boss_Asmoodeus

I know it has something to do with his animations in his script file but I don't think he's supposed to use this torso_idle function because when I add it he has no walking animations. He just slides around like an idiot. I'm no animator so I don't know how to get this going.

Here's his def file:

/***********************************************************************



monster_boss_spidermastermind.def



***********************************************************************/



model monster_boss_asmodeus {

mesh models/md5/monsters/asmodeus/Asmodeus.md5mesh
channel legs ( *origin )
anim death models/md5/monsters/asmodeus/Asmodeus_Death.md5anim {
frame 1 sound_voice snd_death
frame 10 sound_body snd_step
frame 25 sound_body snd_step
frame 40 sound_body snd_step
frame 55 sound_body snd_step }
anim idle models/md5/monsters/asmodeus/Asmodeus_Idle.md5anim {
frame 1 sound_voice snd_idle }
anim sight models/md5/monsters/asmodeus/Asmodeus_Pain.md5anim {
frame 1 sound_voice snd_sight
frame 20 sound_body snd_step
frame 50 sound_body snd_step }
// anim move models/md5/monsters/asmodeus/asmodeus_move.md5anim
anim pain models/md5/monsters/asmodeus/Asmodeus_Pain.md5anim {
frame 1 sound_body snd_pain
frame 20 sound_body snd_step
frame 50 sound_body snd_step  }
anim ranged_attack models/md5/monsters/asmodeus/Asmodeus_Ranged_Attack.md5anim
anim walk models/md5/monsters/asmodeus/Asmodeus_Walk.md5anim
// anim weaken models/md5/monsters/asmodeus/Asmodeus_Weaken.md5anim
}


entityDef monster_boss_asmodeus {

"editor_mins" "-200 -245 0"

"editor_maxs" "200 245 385"


"inherit" "monster_default"

"scriptobject" "monster_boss_asmodeus"

"model" "monster_boss_asmodeus"

"size" "400 490 385"

"use_aas" "aas_mastermind"

"team" "4"

"rank" "3"

"health" "60000" // 4500

"melee_range" "300"

"score" "1500"
"print_name" "Spider Mastermind"
"print_form" " "
"respondByEntity" "1"
"af_push_moveables" "1"
"spread" "8" //determines horizontal spread of projectiles
"direct_accuracy" "4" //determines directDamage accuracy. Lower = More Accurate. Cannot be 0
"fov" "200"
"angle" "0"
"big_monster" "1"

"def_projectile" "projectile_asmodeus_bullet"


"blast_fx" "fx/asmodeus_blast"
"gunLight" "fx/asmodeus_gunlight"
"smokeParticleSystem" "Turret"

"turn_rate" "270"


"look_min" "-120 -150 0"

"look_max" "55 150 0"

"mass"    "2000000"



"ik_numLegs" "6"

"ik_footSize" "8"

"ik_footDownTrace" "64"

"ik_waist" "Body"

"ik_ankle1" "Rleg1"

"ik_ankle2" "Rleg2"

"ik_ankle3" "Rleg3"

"ik_ankle4" "Lleg1"

"ik_ankle5" "Lleg2"

"ik_ankle6" "Lleg3"

"ik_dir1" "Rknee1"

"ik_dir2" "Rknee2"

"ik_dir3" "Rknee3"

"ik_dir4" "Lknee1"

"ik_dir5" "Lknee2"

"ik_dir6" "Lknee3"

"ik_foot1" "Rfoot1"

"ik_foot2" "Rfoot2"
"ik_foot3" "Rfoot3"

"ik_foot4" "Lfoot1"


"ik_foot5" "Lfoot2"

"ik_foot6" "Lfoot3"





"snd_sight" "monster_boss_asmodeus_sight"

"snd_step" "monster_boss_asmodeus_step"

"snd_idle" "monster_boss_asmodeus_idle"

"snd_pain" "monster_boss_asmodeus_pain"

"snd_death" "monster_boss_asmodeus_death"

"snd_walk" "monster_boss_asmodeus_walk"

"snd_attack" "monster_boss_asmodeus_fire"
}



entityDef projectile_asmodeus_bullet {
"spawnclass" "idProjectile"
"mins" "-1 -1 -1"
"maxs" "1 1 1"
"cone" "4"
"scale" "0.1"
"noshadows" "1"
"tracers" "0"
"model_tracer" "models/particles/tracer/tracer.lwo"

"def_damage" "damage_asmodeus_bullet"

"launchFromBarrel" "1"
"health" "0"
"velocity" "3000 0 0"
"angular_velocity" "0 0 0"
"thrust" "0"
"thrust_start" "0"
"thrust_end" "0"
"linear_friction" "0"
"angular_friction" "0"
"contact_friction" "0"
"bounce" "0.7"
"mass" "5"
"gravity" "0"
"fuse" "4"

"detonate_on_fuse" "0"
"detonate_on_death" "0"
"detonate_on_world" "1"
"detonate_on_actor" "1"

"impact_damage_effect" "1"
"impact_gib" "1"

"mtr_detonate" "textures/decals/bulleth02"
"mtr_detonate_glass" "textures/decals/testbulletglass1"
"decal_size" "12"

"model_smokespark" "cgsmokeandspark.prt"
"model_ricochet" "bulletricochet.prt"

"smoke_wound_flesh" "burstysquirt.prt"
"smoke_detonate" "smokeandspark.smoke"
"smoke_residue" "" //particles/chaingun_residue.particle"
"smoke_bounce" "" //particles/chaingun_bounce.particle"
"smoke_fuse" ""

"mtr_light_shader" ""
"light_color" "0 0 0"
"light_radius" "0"
"light_offset" "0 0 0"

"mtr_explode_light_shader" ""
"explode_light_color" "0 0 0"
"explode_light_radius" "0"
"explode_light_fadetime" "0"

"snd_flesh" "bullet_impact_flesh"
"snd_metal" "bullet_impact_metal"
"snd_stone" "bullet_impact_stone"
"snd_wood" "bullet_impact_wood"
"snd_cardboard" "bullet_impact_cardboard"
"snd_glass" "bullet_impact_glass"
"snd_liquid" "bullet_impact_liquid"
"snd_plastic" "small_plastic"
"snd_ricochet" "bullet_ricochet"
"snd_tracer" "bullet_flight"
}

entityDef damage_asmodeus_bullet {
"damage" "7"
"kickDir" "1 0 0"

"mtr_blob" "genericDamage"
"blob_time" "400"
"blob_size" "500"
"blob_offset_x" "500"

"knockback" "1"

"gib" "1"
"smoke_wound_flesh" "bloodwound.ptr"
"mtr_wound_flesh" "textures/decals/hurt02"
"mtr_wound_metal" "textures/decals/hurtmetal"
"mtr_wound_ricochet" "textures/decals/hurtmetal"
"mtr_splat_flesh" "textures/decals/dsplat2"
"mtr_splat_flesh2" "textures/decals/dsplat5"
"mtr_splat_flesh3" "textures/decals/dsplat7"
"mtr_splat_flesh4" "textures/decals/dsplat11"

"kick_time" "200"
"kick_amplitude" "0.1"
}

entityDef blastWave {
"damage" "100"
"radius" "350"
"knockback" "400"
"push" "10000"
}


And here's his script file:

/***********************************************************************

ai_monster_boss_asmodeus.script

monster_boss_spidermastermind

***********************************************************************/

#define ASMODEUS_RANGE_ATTACK_RANGE 3000
#define ASMODEUS_NEXTATTACK_DELAY 3
#define ASMODEUS_NOFOVATTACK_DELAY 3
#define ASMODEUS_NUM_PROJECTILES 70
#define ASMODEUS_ATTACK_RATE .1

// anim blend times
#define ASMODEUS_PAIN_TO_PAIN 7
#define ASMODEUS_PAIN_DELAY 2
#define ASMODEUS_PAIN_TO_IDLE 2
#define ASMODEUS_IDLE_TO_PAIN 2
#define ASMODEUS_SIGHT_TO_SIGHT 3
#define ASMODEUS_SIGHT_TO_IDLE 2
#define ASMODEUS_BLAST_TO_IDLE 3
#define ASMODEUS_IDLE_TO_BLAST 3
#define ASMODEUS_WALK_TO_IDLE 3
#define ASMODEUS_IDLE_TO_WALK 1
#define ASMODEUS_RANGE_TO_IDLE 1
#define ASMODEUS_IDLE_TO_RANGE 3
#define ASMODEUS_BLAST_DELAY 3.5

object monster_boss_asmodeus : monster_base {
float nextAttack;
float nextBlast;
float nextNoFOVAttack;
entity combat_node;
entity blast_entity;
float nextpain;

void Legs_RangeAttack();
void Legs_Walk();
void Legs_Idle();
void Legs_Pain();
void Legs_Sight();
void Legs_Death();

void init();
void state_Begin();
void state_Idle();
void do_attack(float attack_flags);
float check_attacks();
void combat_range();
void combat_blast();
void fire_shot();
};

/***********************************************************************

animation control

***********************************************************************/

void monster_boss_asmodeus::Legs_Sight() {
playAnim( ANIMCHANNEL_LEGS, "sight" );

while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_SIGHT_TO_SIGHT ) ) {
waitFrame();
}

animState( ANIMCHANNEL_LEGS, "Legs_Idle", ASMODEUS_SIGHT_TO_IDLE );
}

void monster_boss_asmodeus::Legs_Idle() {
idleAnim( ANIMCHANNEL_LEGS, "idle" );

eachFrame {
if ( AI_FORWARD ) {
animState( ANIMCHANNEL_LEGS, "Legs_Walk", ASMODEUS_IDLE_TO_WALK );
}
}
}

void monster_boss_asmodeus::Legs_Pain() {
float currenttime;

stopSound( 1, 1 );
currenttime = sys.getTime();

if ( currenttime > nextpain ) {
playAnim( ANIMCHANNEL_LEGS, "pain" );
nextpain = sys.getTime() + ASMODEUS_PAIN_TO_PAIN;
while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_PAIN_DELAY ) ) {
waitFrame();
}
animState( ANIMCHANNEL_LEGS, "Legs_Idle", ASMODEUS_PAIN_TO_IDLE );
}
}

void monster_boss_asmodeus::Legs_RangeAttack() {
playAnim( ANIMCHANNEL_LEGS, "ranged_attack" );

while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_RANGE_TO_IDLE ) ) {
waitFrame();
}

animState( ANIMCHANNEL_LEGS, "Legs_Idle", ASMODEUS_RANGE_TO_IDLE );
}

void monster_boss_asmodeus::Legs_Walk() {
playAnim( ANIMCHANNEL_LEGS, "walk" );
startSound( "snd_walk", 1, 1 );

while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_WALK_TO_IDLE ) ) {
waitFrame();
}

animState( ANIMCHANNEL_LEGS, "Legs_Idle", ASMODEUS_WALK_TO_IDLE );
}

void monster_boss_asmodeus::Legs_Death() {
playAnim( ANIMCHANNEL_LEGS, "death" );

while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_WALK_TO_IDLE ) ) {
waitFrame();
}
}

/***********************************************************************

AI

***********************************************************************/


/*
=====================
monster_boss_asmodeus::state_Dead
=====================
*/
void monster_boss_asmodeus::state_Dead() {
becomeNonSolid();
clearEnemy();

playAnim( ANIMCHANNEL_LEGS, "death" );
sys.wait(7);

remove();
}

/*
=====================
monster_boss_asmodeus::init
=====================
*/
void monster_boss_asmodeus::init() {
setSmokeVisibility( 0, 0 );
nextpain = 0;
nextBlast = 0;
nextAttack = 0;

setState( "state_Begin" );
}

/*
=====================
monster_boss_asmodeus::state_Begin
=====================
*/
void monster_boss_asmodeus::state_Begin() {
animState( ANIMCHANNEL_LEGS, "Legs_Idle", 0 );
monster_begin();
setMoveType( MOVETYPE_ANIM );
setState( "state_Idle" );
}

/************************

Combat

************************/

/*
=====================
monster_boss_asmodeus::state_Idle
=====================
*/
void monster_boss_asmodeus::state_Idle() {
wait_for_enemy();

nextAttack = 0;
nextNoFOVAttack = 0;

setState( "state_Combat" );
}

/*
=====================
monster_boss_asmodeus::do_attack
=====================
*/
void monster_boss_asmodeus::do_attack( float attack_flags ) {
nextNoFOVAttack = sys.getTime() + ASMODEUS_NOFOVATTACK_DELAY;
if ( attack_flags & ATTACK_MISSILE ) {
combat_range();
} else if ( attack_flags & ATTACK_MELEE ) {
combat_blast();
} else if ( attack_flags & ATTACK_COMBAT_NODE ) {
combat_ainode( combat_node );
}
}

/*
=====================
monster_boss_asmodeus::check_attacks
=====================
*/
float monster_boss_asmodeus::check_attacks() {
float currentTime;
float attack_flags;
vector org;

attack_flags = 0;
currentTime = sys.getTime();

org = getOrigin();
blast_entity = findActorsInBounds( org + '-295 -295 0', org + '295 295 295' );
if ( blast_entity ) {
if(  sys.getTime() > nextBlast ) {
attack_flags |= ATTACK_MELEE;
}
}

if ( !blast_entity ) {
combat_node = getCombatNode();
if ( combat_node ) {
attack_flags |= ATTACK_COMBAT_NODE;
}
}

if ( ( ( sys.getTime() > nextNoFOVAttack ) && AI_ENEMY_VISIBLE ) || AI_ENEMY_IN_FOV ) {
if ( !canReachEnemy() || ( currentTime >= nextAttack ) ) {
if ( canHitEnemyFromJoint( "Turret" ) ) {
attack_flags |= ATTACK_MISSILE;
}
}
}

if ( AI_PAIN ) {
animState( ANIMCHANNEL_LEGS, "Legs_Pain", ASMODEUS_IDLE_TO_PAIN );
}

return attack_flags;
}

/*
=====================
monster_boss_asmodeus::combat_blast
=====================
*/
void monster_boss_asmodeus::combat_blast() {

startFx( getKey( "blast_fx" ) );
sys.radiusDamage( getOrigin(), self, self, self, "blastWave", 1.0 );

nextBlast = sys.getTime() + ASMODEUS_BLAST_DELAY;
}

/*
=====================
monster_boss_asmodeus::combat_range
=====================
*/
void monster_boss_asmodeus::combat_range() {

stopSound( 1, 1 );
fire_shot();

while( !animDone( ANIMCHANNEL_LEGS, ASMODEUS_RANGE_TO_IDLE ) ) {
waitFrame();
}

nextAttack = sys.getTime() + ASMODEUS_NEXTATTACK_DELAY;
nextNoFOVAttack = sys.getTime() + ASMODEUS_NOFOVATTACK_DELAY;
animState( ANIMCHANNEL_LEGS, "Legs_Idle", ASMODEUS_RANGE_TO_IDLE );
}

/*
=====================
monster_boss_asmodeus::fire_shot
=====================
*/
void monster_boss_asmodeus::fire_shot() {
vector orgOne;
vector orgTwo;
float turretJoint;
vector ang;
float x;
entity enemy;
vector enemyPos;
float spread;
float directAccuracy;
float hypotenuse;
float opposite;

turretJoint = getJointHandle( "Turret" );
spread = getIntKey( "spread" );
directAccuracy = getIntKey( "direct_accuracy" );

startSound( "snd_attack", 1, 1 );
setSmokeVisibility( 0, 1 );

for ( x = 0; x < ASMODEUS_NUM_PROJECTILES; x++ ) {
enemy = getEnemy();
orgOne = getOrigin();
if( !canHitEnemyFromJoint( "Turret" ) ) {
break;
}

if( AI_ENEMY_DEAD ) {
break;
}

blast_entity = findActorsInBounds( orgOne + '-295 -295 0', orgOne + '295 295 295' );
if ( blast_entity ) {
if(  sys.getTime() > nextBlast ) {
combat_blast();
}
}

faceEnemy();
orgTwo = getJointPos( turretJoint );
ang = getAngles();

playAnim( ANIMCHANNEL_LEGS, "ranged_attack" );
startFx( getKey( "gunLight" ) );

if( sys.random( spread ) <= spread/directAccuracy ) {
directDamage( enemy, "damage_asmodeus_bullet" );
} else {
if ( int( sys.random( 2 ) ) + 1 == 1 ) {
ang_y -= sys.random( spread );
} else {
ang_y += sys.random( spread );
}

enemyPos = enemy.getJointPos( getJointHandle( "Body" ) );

opposite = enemyRange2D();
hypotenuse = sys.sqrt( enemyRange2D()*enemyRange2D() + (orgTwo_z - enemyPos_z)*(orgTwo_z - enemyPos_z) );

if( hypotenuse == 0 ) {
break;
}

if( orgTwo_z > enemyPos_z ) {
ang_x = 90 - arcsin( opposite/hypotenuse );
} else {
ang_x = arcsin( opposite/hypotenuse ) - 90;
}

launchMissile( orgTwo, ang );
}
sys.wait( ASMODEUS_ATTACK_RATE );
}
stopSound( 1, 1 );
setSmokeVisibility( 0, 0 );
}


Please help if you can. I got big plans for this beast.
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

VGames

Anybody got an idea on how to fix this?
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

BielBdeLuna

what is the actual error message? in the script there isn't any "Torso_Idle"

VGames

Yeah I know. The monster wasn't designed to have one yet the game is telling me there isn't one. Does it need one?
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

BielBdeLuna

it shouldn't, iirc c++ code only calls for a init() script function because the Torso_Idle is an animation state, which shouldn't be called by c++ only by the script code, and in the c++ code in either actor.cpp or ai/ai.cpp there is no reference to any "Torso_idle"

the only option that this only leaves is that you might be calling a function in the super scriptobject "monster_base" that actually calls the "Torso_idle" check the whole loop to see if something doesn't replace something in monster_base that actually calls for that function

specially the checks for the attacks or the actual attacks, that might incorporate some indications to an actual torso that doesn't exist in your sub scriptobject but that the super scriptobjects gets to call. this kind of trouble is due the spaghetti code in the original FSMs. if we come up with an open source replacement of that code we should watch out to not include source with spaghetti code that could lead to that kind of troubles.


motorsep

Check Cacodemon and Lost Soul and Trite. Afaik they all have Torso_Idle.

BielBdeLuna

#11
can you post the actual message?

in the lms mod extension there is a monster_base.script alongside the ai_monster_boss_asmodeus.script (which I guess that is the one you are using) in the monster_base there are calls to the torso_idle, I guess that is where the asmodeus script fails if indeed your actual error message points to a script error.

VGames


script\ai_monster_base.script : monster_base::wake_on_enemy
script\ai_monster_base.script : monster_base::wake_on_enemy
script\ai_monster_base.script : monster_base::monster_begin
script\ai_monster_boss_asmodeus.script : monster_boss_asmodeus::state_Begin
<NO FUNCTION>
--------- Game Map Shutdown ----------
--------------------------------------
********************
ERROR: script\ai_monster_base.script(884): Thread 'idAI_monster_boss_asmodeus_
40': Can't find function 'Torso_Idle' in object 'monster_boss_asmodeus'

********************
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500

BielBdeLuna

there you got it the error is in line 884 of ai_monster_base.script wich is the super script function of ai_monster_boss_asmodeus.script

you might want to create your own separate AI script for that monster which doesn't use any super class or implement a super class for monster_base for single mesh monsters rather than torso + legs monsters, this is up to you.

VGames

Couldn't I just take that part of the monster base script and add it to the spider masterminds script and change the torso idle part to legs idle? I'm really not good at coding AI scripts.
Get the latest on Perfected Doom 3 here - http://www.moddb.com/mods/perfected-doom-3-version-500