3038 {
3040 vector.X += velocity.X;
3041 vector.Y = (float)
Math.
Floor((
vector.Y + (
float)height) / 16f) * 16f - (
float)height;
3042 bool flag = false;
3043 int num = (int)(
vector.X / 16f);
3044 int num2 = (int)((
vector.X + (
float)width) / 16f);
3045 int num3 = (int)((
vector.Y + (
float)height + 4f) / 16f);
3046 int num4 = height / 16 + ((height % 16 != 0) ? 1 : 0);
3048 float num6 = Main.bottomWorld / 16f - 42f;
3049 for (
int i = num;
i <=
num2;
i++)
3050 {
3052 {
3054 {
3055 continue;
3056 }
3057 if (Main.tile[i,
j] ==
null)
3058 {
3059 Main.tile[
i,
j] =
new Tile();
3060 }
3061 if (Main.tile[i,
j - 1] ==
null)
3062 {
3063 Main.tile[
i,
j - 1] =
new Tile();
3064 }
3065 if (waterWalk && Main.tile[i,
j].liquid > 0 && Main.tile[i,
j - 1].liquid == 0)
3066 {
3067 int num7 = Main.tile[
i,
j].liquid / 32 * 2 + 2;
3070 {
3072 }
3073 }
3074 if ((
float)
j >=
num6 || (Main.tile[i,
j].nactive() && (Main.tileSolid[Main.tile[i,
j].type] || Main.tileSolidTop[Main.tile[i,
j].type])))
3075 {
3077 if (Main.tile[i,
j].halfBrick())
3078 {
3080 }
3081 if (Utils.FloatIntersect(i * 16,
j * 16 - 17, 16f, 16f, position.X, position.Y, width, height) && (
float)
num9 <
num5)
3082 {
3084 }
3085 }
3086 }
3087 }
3088 float num10 =
num5 - (position.Y + (float)height);
3090 {
3091 stepSpeed = 1.5f;
3093 {
3094 stepSpeed = 2.5f;
3095 }
3096 gfxOffY += position.Y + (float)height -
num5;
3097 position.Y =
num5 - (float)height;
3098 }
3099 }
static double Floor(double d)