MCServer Development Discussion
#52
(11-06-2011, 08:12 AM)Sebi Wrote: Notch's thoughts: *I'm running out of block ids!* *Idea! Let's use negative ids!* :V

Also, in cPlayer.cpp (and also somewhere in monster file) at line 265 you have
Code:
char block = GetWorld()->GetBlock( (int)m_Pos->x, (int)m_Pos->y, (int)m_Pos->z );
And there are some rounding issues with negative coords (you are set on fire one block off lava block)
Something like this shall do:
Code:
#define float2int(x) ((x)<0 ? ((int)(x))-1 : (int)(x))
char block = GetWorld()->GetBlock( float2int(m_Pos->x), float2int(m_Pos->y), float2int(m_Pos->z) );

Yeah, or just use floor() (slightly slower though), I got the same define you have in cNoise.cpp called FAST_FLOORTongue
Reply
Thanks given by:


Messages In This Thread
MCServer Development Discussion - by rs2k - 10-21-2011, 11:24 AM
RE: MCServer Development Discussion - by rs2k - 10-24-2011, 09:34 AM
RE: MCServer Development Discussion - by rs2k - 10-24-2011, 09:50 AM
RE: MCServer Development Discussion - by Sebi - 11-06-2011, 05:28 AM
RE: MCServer Development Discussion - by rs2k - 11-06-2011, 05:38 AM
RE: MCServer Development Discussion - by Sebi - 11-06-2011, 06:45 AM
RE: MCServer Development Discussion - by Sebi - 11-06-2011, 08:12 AM
RE: MCServer Development Discussion - by rs2k - 11-06-2011, 08:18 AM
RE: MCServer Development Discussion - by FakeTruth - 11-06-2011, 08:26 AM
RE: MCServer Development Discussion - by Sebi - 11-06-2011, 12:34 PM
RE: MCServer Development Discussion - by rs2k - 11-06-2011, 07:27 PM
RE: MCServer Development Discussion - by Sebi - 11-07-2011, 11:32 PM
RE: MCServer Development Discussion - by rs2k - 11-08-2011, 03:27 AM
RE: MCServer Development Discussion - by Sebi - 11-08-2011, 04:51 AM
RE: MCServer Development Discussion - by rs2k - 11-08-2011, 05:17 AM
RE: MCServer Development Discussion - by Sebi - 11-08-2011, 05:29 AM
RE: MCServer Development Discussion - by rs2k - 11-08-2011, 05:55 AM
RE: MCServer Development Discussion - by Sebi - 11-08-2011, 06:03 AM
RE: MCServer Development Discussion - by rs2k - 11-08-2011, 06:09 AM
RE: MCServer Development Discussion - by Sebi - 11-08-2011, 06:40 AM
RE: MCServer Development Discussion - by Sebi - 11-08-2011, 08:09 AM
RE: MCServer Development Discussion - by rs2k - 11-08-2011, 09:03 AM
RE: MCServer Development Discussion - by Sebi - 11-10-2011, 06:12 AM
RE: MCServer Development Discussion - by rs2k - 11-10-2011, 10:07 AM
RE: MCServer Development Discussion - by Sebi - 11-10-2011, 10:55 PM
RE: MCServer Development Discussion - by rs2k - 11-11-2011, 02:33 AM
RE: MCServer Development Discussion - by rs2k - 11-11-2011, 10:23 AM
RE: MCServer Development Discussion - by Boo - 02-05-2012, 02:31 AM
RE: MCServer Development Discussion - by tbar - 02-05-2012, 04:08 AM
RE: MCServer Development Discussion - by Boo - 02-05-2012, 04:39 PM
RE: MCServer Development Discussion - by rs2k - 02-05-2012, 05:41 PM
RE: MCServer Development Discussion - by Boo - 02-05-2012, 09:19 PM
RE: MCServer Development Discussion - by Boo - 02-05-2012, 11:21 PM
RE: MCServer Development Discussion - by tbar - 02-06-2012, 04:21 AM
RE: MCServer Development Discussion - by xoft - 02-06-2012, 01:42 AM
RE: MCServer is open source! - by AJIeKCaHDp - 10-21-2011, 08:04 PM
RE: MCServer is open source! - by rs2k - 10-21-2011, 08:23 PM
RE: MCServer is open source! - by AJIeKCaHDp - 10-21-2011, 09:00 PM
RE: MCServer is open source! - by rs2k - 10-21-2011, 10:23 PM
RE: MCServer is open source! - by AJIeKCaHDp - 10-21-2011, 10:29 PM
RE: MCServer is open source! - by FakeTruth - 10-21-2011, 11:51 PM
RE: MCServer is open source! - by AJIeKCaHDp - 10-21-2011, 11:55 PM
RE: MCServer is open source! - by FakeTruth - 10-22-2011, 12:18 AM
RE: MCServer is open source! - by AJIeKCaHDp - 10-22-2011, 12:56 AM
RE: MCServer is open source! - by FakeTruth - 10-22-2011, 01:51 AM
RE: MCServer is open source! - by rs2k - 10-22-2011, 04:21 AM
RE: MCServer is open source! - by AJIeKCaHDp - 10-22-2011, 06:21 AM
RE: MCServer is open source! - by vcnnews - 10-22-2011, 07:04 AM
RE: MCServer is open source! - by FakeTruth - 10-22-2011, 07:27 AM
RE: MCServer is open source! - by rs2k - 10-22-2011, 08:15 AM
RE: MCServer is open source! - by FakeTruth - 10-22-2011, 08:24 AM
RE: MCServer is open source! - by AJIeKCaHDp - 10-22-2011, 09:04 AM
RE: MCServer is open source! - by rs2k - 10-22-2011, 09:20 AM
RE: MCServer is open source! - by FakeTruth - 10-22-2011, 10:20 AM
RE: MCServer is open source! - by rs2k - 10-23-2011, 01:05 AM
RE: MCServer is open source! - by FakeTruth - 10-23-2011, 05:09 AM
RE: MCServer is open source! - by rs2k - 10-23-2011, 05:18 AM
RE: MCServer is open source! - by necavi - 10-23-2011, 03:27 PM
RE: MCServer is open source! - by rs2k - 10-24-2011, 02:20 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 03:59 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 05:04 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 06:51 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 06:55 AM
RE: MCServer is open source! - by necavi - 10-24-2011, 07:02 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 07:05 AM
RE: MCServer is open source! - by necavi - 10-24-2011, 07:08 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 07:40 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 08:03 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 08:11 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 08:29 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 08:30 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 08:55 AM
RE: MCServer is open source! - by rs2k - 10-24-2011, 09:04 AM
RE: MCServer is open source! - by FakeTruth - 10-24-2011, 09:20 AM



Users browsing this thread: 2 Guest(s)