Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problems with non-despawning monster
Sazureth Offline
Junior Member

Posts: 20
Threads: 8
Joined: Jan 2012
Reputation: 0
#1
Problems with non-despawning monster

Is it possible to set the monster not despawn when the player dies? (Or spawn a new monster with exactly the same name when the player respawns)
(This post was last modified: 01-22-2012, 02:25 PM by Sazureth.)
01-20-2012, 10:27 PM
Find
Tripication Offline
Member

Posts: 172
Threads: 19
Joined: Dec 2011
Reputation: 6
#2
RE: Problems with non-despawning monster

Not sure, but if you try looping the path nodes, that might do the trick

[Image: speedart__2___yoshimitsu_by_kamofudge-d4yo6kk.png]
(This post was last modified: 01-20-2012, 10:39 PM by Tripication.)
01-20-2012, 10:38 PM
Find
Unearthlybrutal Offline
Posting Freak

Posts: 775
Threads: 12
Joined: May 2011
Reputation: 26
#3
RE: Problems with non-despawning monster

Make a checkpoint and make it call a function when you die:
Put there:

ResetProp("NAME OF THE ENEMY");

You'll need to make it active again and when its active,
its in the same position as it were when the map startedSmile

When Life No Longer Exists
Full-conversion mod
01-20-2012, 10:48 PM
Website Find
Statyk Offline
Schrödinger's Mod

Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation: 241
#4
RE: Problems with non-despawning monster

Or if you have the monster spawn on an area collide, make sure the "autoremove" is set to FALSE.. E.g...

AddEntityCollideCallback("Player", "COLLIDEAREA", "MONSTERFUNCTION", false, 1);

This allows the function to be called repeatedly, as the function is not deleted. Result, monster spawning after each death.
01-20-2012, 10:55 PM
Find
Your Computer Offline
SCAN ME!

Posts: 3,456
Threads: 32
Joined: Jul 2011
Reputation: 235
#5
RE: Problems with non-despawning monster

Monsters cannot be "respawned" if the player is killed by the monster within the same map session. You have to either reload the map or have another monster with a different name waiting to be enabled afterwards.

Tutorials: From Noob to Pro
01-21-2012, 12:14 AM
Website Find
Krymtel Offline
Member

Posts: 105
Threads: 9
Joined: Oct 2011
Reputation: 3
#6
RE: Problems with non-despawning monster

Try this maybe:

void SetEnemyDisabled(string& asName, bool abDisabled);

As in...

void SetEnemyDisabled("NAME OF ENEMY", true);


Or, if it's part of a function...

SetEnemyDisabled("NAME OF ENEMY", true);

Eidolon Total Conversion (WIP)
01-21-2012, 10:51 AM
Find
Sazureth Offline
Junior Member

Posts: 20
Threads: 8
Joined: Jan 2012
Reputation: 0
#7
RE: Problems with non-despawning monster

Your Computer really answered my question, thank you.
This means that I'm just going to make two version of the same map file and have a loading screen when the player dies..

Thanks for help!
01-22-2012, 02:25 PM
Find




Users browsing this thread: 1 Guest(s)