Permalink
Browse files

Whoa! Huge bug in Eve death location for Eve respawn. Was not actuall…

…y using her death location, but instead the weighted average of recent placements on the map. This would make her respawn in some other more-developed village later, which is why there was so much player confusion around this mechanic.
  • Loading branch information...
jasonrohrer committed Dec 25, 2018
1 parent f7a113a commit ce5dc723837a8769c82ca0175a13bec94c57d866
Showing with 17 additions and 23 deletions.
  1. +7 −0 documentation/changeLog.txt
  2. +3 −1 server/lifeLog.cpp
  3. +6 −21 server/map.cpp
  4. +1 −1 server/map.h
@@ -11,6 +11,13 @@ Version 185 ???
--Eve old-age death-location respawn blocked if there are 4 or more fertile
females on server. That is supposed to be a solo-play mechanic.

--Whoa! Huge bug in Eve death location for Eve respawn. Was not actually
using her death location, but instead the weighted average of recent
placements on the map. This would make her respawn in some other
more-developed village later, which is why there was so much player
confusion around this mechanic.




Version 183 2018-December-20
@@ -206,7 +206,9 @@ void logDeath( int inPlayerID, char *inPlayerEmail,

if( inEve ) {

mapEveDeath( inPlayerEmail, inAge );
GridPos deathPos = { inMapX, inMapY };

mapEveDeath( inPlayerEmail, inAge, deathPos );

if( inAge > 20 ) {
resetEveRadius();
@@ -6372,7 +6372,7 @@ void getEvePosition( char *inEmail, int *outX, int *outY,



void mapEveDeath( char *inEmail, double inAge ) {
void mapEveDeath( char *inEmail, double inAge, GridPos inDeathMapPos ) {

// record exists?

@@ -6395,9 +6395,6 @@ void mapEveDeath( char *inEmail, double inAge ) {
}


int num = 0;

doublePair ave = computeRecentCampAve( &num );

int result = eveDBGet( inEmail, &pX, &pY, &pR );

@@ -6418,25 +6415,13 @@ void mapEveDeath( char *inEmail, double inAge ) {
// not found in DB

// must overwrite no matter what
pX = lrint( ave.x );
pY = lrint( ave.y );

pR = eveRadiusStart;
}


if( num > 0 ) {
// overwrite middle from last life with new middle of placements
// from this life
pX = lrint( ave.x );
pY = lrint( ave.y );
}
else {
// otherwise, leave last life's average alone
printf( "Logging Eve death: "
"Keeping camp average (%d,%d) from last life\n",
pX, pY );
}


// their next camp will start where they last died
pX = inDeathMapPos.x;
pY = inDeathMapPos.y;


printf( "Remembering Eve's camp in database (%d,%d) r=%d for %s\n",
@@ -60,7 +60,7 @@ void getEvePosition( char *inEmail, int *outX, int *outY,

// save recent placements on Eve's death so that this player can spawn
// near them if they are ever Eve again
void mapEveDeath( char *inEmail, double inAge );
void mapEveDeath( char *inEmail, double inAge, GridPos inDeathMapPos );



0 comments on commit ce5dc72

Please sign in to comment.