Merge branch '1.9'
This commit is contained in:
commit
f5781488d9
745 changed files with 18019 additions and 14550 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -8,6 +8,7 @@
|
|||
|
||||
#idea
|
||||
/.idea
|
||||
/classes
|
||||
*.iml
|
||||
|
||||
#gradle
|
||||
|
@ -20,7 +21,6 @@
|
|||
/buildSrc
|
||||
|
||||
#Patch rejects
|
||||
*.rej
|
||||
/patches-/
|
||||
|
||||
# FML changelog
|
||||
|
|
483
LICENSE-new.txt
Normal file
483
LICENSE-new.txt
Normal file
|
@ -0,0 +1,483 @@
|
|||
Minecraft Forge is licensed under the terms of the LGPL 2.1 found
|
||||
here http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt and copied
|
||||
below.
|
||||
|
||||
A note on authorship:
|
||||
All source artifacts are property of their original author, with
|
||||
the exclusion of the contents of the patches directory and others
|
||||
copied from it from time to time. Authorship of the contents of
|
||||
the patches directory is retained by the Minecraft Forge project.
|
||||
This is because the patches are partially machine generated
|
||||
artifacts, and are changed heavily due to the way forge works.
|
||||
Individual attribution within them is impossible.
|
||||
|
||||
Consent:
|
||||
All contributions to Forge must consent to the release of any
|
||||
patch content to the Forge project.
|
||||
|
||||
A note on infectivity:
|
||||
The LGPL is chosen specifically so that projects may depend on Forge
|
||||
features without being infected with its license. That is the
|
||||
purpose of the LGPL. Mods and others using this code via ordinary
|
||||
Java mechanics for referencing libraries are specifically not bound
|
||||
by Forge's license for the Mod code.
|
||||
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
Version 2.1, February 1999
|
||||
|
||||
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
[This is the first released version of the Lesser GPL. It also counts
|
||||
as the successor of the GNU Library Public License, version 2, hence
|
||||
the version number 2.1.]
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
Licenses are intended to guarantee your freedom to share and change
|
||||
free software--to make sure the software is free for all its users.
|
||||
|
||||
This license, the Lesser General Public License, applies to some
|
||||
specially designated software packages--typically libraries--of the
|
||||
Free Software Foundation and other authors who decide to use it. You
|
||||
can use it too, but we suggest you first think carefully about whether
|
||||
this license or the ordinary General Public License is the better
|
||||
strategy to use in any particular case, based on the explanations below.
|
||||
|
||||
When we speak of free software, we are referring to freedom of use,
|
||||
not price. Our General Public Licenses are designed to make sure that
|
||||
you have the freedom to distribute copies of free software (and charge
|
||||
for this service if you wish); that you receive source code or can get
|
||||
it if you want it; that you can change the software and use pieces of
|
||||
it in new free programs; and that you are informed that you can do
|
||||
these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
distributors to deny you these rights or to ask you to surrender these
|
||||
rights. These restrictions translate to certain responsibilities for
|
||||
you if you distribute copies of the library or if you modify it.
|
||||
|
||||
For example, if you distribute copies of the library, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that we gave
|
||||
you. You must make sure that they, too, receive or can get the source
|
||||
code. If you link other code with the library, you must provide
|
||||
complete object files to the recipients, so that they can relink them
|
||||
with the library after making changes to the library and recompiling
|
||||
it. And you must show them these terms so they know their rights.
|
||||
|
||||
We protect your rights with a two-step method: (1) we copyright the
|
||||
library, and (2) we offer you this license, which gives you legal
|
||||
permission to copy, distribute and/or modify the library.
|
||||
|
||||
To protect each distributor, we want to make it very clear that
|
||||
there is no warranty for the free library. Also, if the library is
|
||||
modified by someone else and passed on, the recipients should know
|
||||
that what they have is not the original version, so that the original
|
||||
author's reputation will not be affected by problems that might be
|
||||
introduced by others.
|
||||
|
||||
Finally, software patents pose a constant threat to the existence of
|
||||
any free program. We wish to make sure that a company cannot
|
||||
effectively restrict the users of a free program by obtaining a
|
||||
restrictive license from a patent holder. Therefore, we insist that
|
||||
any patent license obtained for a version of the library must be
|
||||
consistent with the full freedom of use specified in this license.
|
||||
|
||||
Most GNU software, including some libraries, is covered by the
|
||||
ordinary GNU General Public License. This license, the GNU Lesser
|
||||
General Public License, applies to certain designated libraries, and
|
||||
is quite different from the ordinary General Public License. We use
|
||||
this license for certain libraries in order to permit linking those
|
||||
libraries into non-free programs.
|
||||
|
||||
When a program is linked with a library, whether statically or using
|
||||
a shared library, the combination of the two is legally speaking a
|
||||
combined work, a derivative of the original library. The ordinary
|
||||
General Public License therefore permits such linking only if the
|
||||
entire combination fits its criteria of freedom. The Lesser General
|
||||
Public License permits more lax criteria for linking other code with
|
||||
the library.
|
||||
|
||||
We call this license the "Lesser" General Public License because it
|
||||
does Less to protect the user's freedom than the ordinary General
|
||||
Public License. It also provides other free software developers Less
|
||||
of an advantage over competing non-free programs. These disadvantages
|
||||
are the reason we use the ordinary General Public License for many
|
||||
libraries. However, the Lesser license provides advantages in certain
|
||||
special circumstances.
|
||||
|
||||
For example, on rare occasions, there may be a special need to
|
||||
encourage the widest possible use of a certain library, so that it becomes
|
||||
a de-facto standard. To achieve this, non-free programs must be
|
||||
allowed to use the library. A more frequent case is that a free
|
||||
library does the same job as widely used non-free libraries. In this
|
||||
case, there is little to gain by limiting the free library to free
|
||||
software only, so we use the Lesser General Public License.
|
||||
|
||||
In other cases, permission to use a particular library in non-free
|
||||
programs enables a greater number of people to use a large body of
|
||||
free software. For example, permission to use the GNU C Library in
|
||||
non-free programs enables many more people to use the whole GNU
|
||||
operating system, as well as its variant, the GNU/Linux operating
|
||||
system.
|
||||
|
||||
Although the Lesser General Public License is Less protective of the
|
||||
users' freedom, it does ensure that the user of a program that is
|
||||
linked with the Library has the freedom and the wherewithal to run
|
||||
that program using a modified version of the Library.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow. Pay close attention to the difference between a
|
||||
"work based on the library" and a "work that uses the library". The
|
||||
former contains code derived from the library, whereas the latter must
|
||||
be combined with the library in order to run.
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License Agreement applies to any software library or other
|
||||
program which contains a notice placed by the copyright holder or
|
||||
other authorized party saying it may be distributed under the terms of
|
||||
this Lesser General Public License (also called "this License").
|
||||
Each licensee is addressed as "you".
|
||||
|
||||
A "library" means a collection of software functions and/or data
|
||||
prepared so as to be conveniently linked with application programs
|
||||
(which use some of those functions and data) to form executables.
|
||||
|
||||
The "Library", below, refers to any such software library or work
|
||||
which has been distributed under these terms. A "work based on the
|
||||
Library" means either the Library or any derivative work under
|
||||
copyright law: that is to say, a work containing the Library or a
|
||||
portion of it, either verbatim or with modifications and/or translated
|
||||
straightforwardly into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".)
|
||||
|
||||
"Source code" for a work means the preferred form of the work for
|
||||
making modifications to it. For a library, complete source code means
|
||||
all the source code for all modules it contains, plus any associated
|
||||
interface definition files, plus the scripts used to control compilation
|
||||
and installation of the library.
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running a program using the Library is not restricted, and output from
|
||||
such a program is covered only if its contents constitute a work based
|
||||
on the Library (independent of the use of the Library in a tool for
|
||||
writing it). Whether that is true depends on what the Library does
|
||||
and what the program that uses the Library does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Library's
|
||||
complete source code as you receive it, in any medium, provided that
|
||||
you conspicuously and appropriately publish on each copy an
|
||||
appropriate copyright notice and disclaimer of warranty; keep intact
|
||||
all the notices that refer to this License and to the absence of any
|
||||
warranty; and distribute a copy of this License along with the
|
||||
Library.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange for a
|
||||
fee.
|
||||
|
||||
2. You may modify your copy or copies of the Library or any portion
|
||||
of it, thus forming a work based on the Library, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) The modified work must itself be a software library.
|
||||
|
||||
b) You must cause the files modified to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
c) You must cause the whole of the work to be licensed at no
|
||||
charge to all third parties under the terms of this License.
|
||||
|
||||
d) If a facility in the modified Library refers to a function or a
|
||||
table of data to be supplied by an application program that uses
|
||||
the facility, other than as an argument passed when the facility
|
||||
is invoked, then you must make a good faith effort to ensure that,
|
||||
in the event an application does not supply such function or
|
||||
table, the facility still operates, and performs whatever part of
|
||||
its purpose remains meaningful.
|
||||
|
||||
(For example, a function in a library to compute square roots has
|
||||
a purpose that is entirely well-defined independent of the
|
||||
application. Therefore, Subsection 2d requires that any
|
||||
application-supplied function or table used by this function must
|
||||
be optional: if the application does not supply it, the square
|
||||
root function must still compute square roots.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Library,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Library, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote
|
||||
it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Library.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Library
|
||||
with the Library (or with a work based on the Library) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may opt to apply the terms of the ordinary GNU General Public
|
||||
License instead of this License to a given copy of the Library. To do
|
||||
this, you must alter all the notices that refer to this License, so
|
||||
that they refer to the ordinary GNU General Public License, version 2,
|
||||
instead of to this License. (If a newer version than version 2 of the
|
||||
ordinary GNU General Public License has appeared, then you can specify
|
||||
that version instead if you wish.) Do not make any other change in
|
||||
these notices.
|
||||
|
||||
Once this change is made in a given copy, it is irreversible for
|
||||
that copy, so the ordinary GNU General Public License applies to all
|
||||
subsequent copies and derivative works made from that copy.
|
||||
|
||||
This option is useful when you wish to copy part of the code of
|
||||
the Library into a program that is not a library.
|
||||
|
||||
4. You may copy and distribute the Library (or a portion or
|
||||
derivative of it, under Section 2) in object code or executable form
|
||||
under the terms of Sections 1 and 2 above provided that you accompany
|
||||
it with the complete corresponding machine-readable source code, which
|
||||
must be distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange.
|
||||
|
||||
If distribution of object code is made by offering access to copy
|
||||
from a designated place, then offering equivalent access to copy the
|
||||
source code from the same place satisfies the requirement to
|
||||
distribute the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
5. A program that contains no derivative of any portion of the
|
||||
Library, but is designed to work with the Library by being compiled or
|
||||
linked with it, is called a "work that uses the Library". Such a
|
||||
work, in isolation, is not a derivative work of the Library, and
|
||||
therefore falls outside the scope of this License.
|
||||
|
||||
However, linking a "work that uses the Library" with the Library
|
||||
creates an executable that is a derivative of the Library (because it
|
||||
contains portions of the Library), rather than a "work that uses the
|
||||
library". The executable is therefore covered by this License.
|
||||
Section 6 states terms for distribution of such executables.
|
||||
|
||||
When a "work that uses the Library" uses material from a header file
|
||||
that is part of the Library, the object code for the work may be a
|
||||
derivative work of the Library even though the source code is not.
|
||||
Whether this is true is especially significant if the work can be
|
||||
linked without the Library, or if the work is itself a library. The
|
||||
threshold for this to be true is not precisely defined by law.
|
||||
|
||||
If such an object file uses only numerical parameters, data
|
||||
structure layouts and accessors, and small macros and small inline
|
||||
functions (ten lines or less in length), then the use of the object
|
||||
file is unrestricted, regardless of whether it is legally a derivative
|
||||
work. (Executables containing this object code plus portions of the
|
||||
Library will still fall under Section 6.)
|
||||
|
||||
Otherwise, if the work is a derivative of the Library, you may
|
||||
distribute the object code for the work under the terms of Section 6.
|
||||
Any executables containing that work also fall under Section 6,
|
||||
whether or not they are linked directly with the Library itself.
|
||||
|
||||
6. As an exception to the Sections above, you may also combine or
|
||||
link a "work that uses the Library" with the Library to produce a
|
||||
work containing portions of the Library, and distribute that work
|
||||
under terms of your choice, provided that the terms permit
|
||||
modification of the work for the customer's own use and reverse
|
||||
engineering for debugging such modifications.
|
||||
|
||||
You must give prominent notice with each copy of the work that the
|
||||
Library is used in it and that the Library and its use are covered by
|
||||
this License. You must supply a copy of this License. If the work
|
||||
during execution displays copyright notices, you must include the
|
||||
copyright notice for the Library among them, as well as a reference
|
||||
directing the user to the copy of this License. Also, you must do one
|
||||
of these things:
|
||||
|
||||
a) Accompany the work with the complete corresponding
|
||||
machine-readable source code for the Library including whatever
|
||||
changes were used in the work (which must be distributed under
|
||||
Sections 1 and 2 above); and, if the work is an executable linked
|
||||
with the Library, with the complete machine-readable "work that
|
||||
uses the Library", as object code and/or source code, so that the
|
||||
user can modify the Library and then relink to produce a modified
|
||||
executable containing the modified Library. (It is understood
|
||||
that the user who changes the contents of definitions files in the
|
||||
Library will not necessarily be able to recompile the application
|
||||
to use the modified definitions.)
|
||||
|
||||
b) Use a suitable shared library mechanism for linking with the
|
||||
Library. A suitable mechanism is one that (1) uses at run time a
|
||||
copy of the library already present on the user's computer system,
|
||||
rather than copying library functions into the executable, and (2)
|
||||
will operate properly with a modified version of the library, if
|
||||
the user installs one, as long as the modified version is
|
||||
interface-compatible with the version that the work was made with.
|
||||
|
||||
c) Accompany the work with a written offer, valid for at
|
||||
least three years, to give the same user the materials
|
||||
specified in Subsection 6a, above, for a charge no more
|
||||
than the cost of performing this distribution.
|
||||
|
||||
d) If distribution of the work is made by offering access to copy
|
||||
from a designated place, offer equivalent access to copy the above
|
||||
specified materials from the same place.
|
||||
|
||||
e) Verify that the user has already received a copy of these
|
||||
materials or that you have already sent this user a copy.
|
||||
|
||||
For an executable, the required form of the "work that uses the
|
||||
Library" must include any data and utility programs needed for
|
||||
reproducing the executable from it. However, as a special exception,
|
||||
the materials to be distributed need not include anything that is
|
||||
normally distributed (in either source or binary form) with the major
|
||||
components (compiler, kernel, and so on) of the operating system on
|
||||
which the executable runs, unless that component itself accompanies
|
||||
the executable.
|
||||
|
||||
It may happen that this requirement contradicts the license
|
||||
restrictions of other proprietary libraries that do not normally
|
||||
accompany the operating system. Such a contradiction means you cannot
|
||||
use both them and the Library together in an executable that you
|
||||
distribute.
|
||||
|
||||
7. You may place library facilities that are a work based on the
|
||||
Library side-by-side in a single library together with other library
|
||||
facilities not covered by this License, and distribute such a combined
|
||||
library, provided that the separate distribution of the work based on
|
||||
the Library and of the other library facilities is otherwise
|
||||
permitted, and provided that you do these two things:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work
|
||||
based on the Library, uncombined with any other library
|
||||
facilities. This must be distributed under the terms of the
|
||||
Sections above.
|
||||
|
||||
b) Give prominent notice with the combined library of the fact
|
||||
that part of it is a work based on the Library, and explaining
|
||||
where to find the accompanying uncombined form of the same work.
|
||||
|
||||
8. You may not copy, modify, sublicense, link with, or distribute
|
||||
the Library except as expressly provided under this License. Any
|
||||
attempt otherwise to copy, modify, sublicense, link with, or
|
||||
distribute the Library is void, and will automatically terminate your
|
||||
rights under this License. However, parties who have received copies,
|
||||
or rights, from you under this License will not have their licenses
|
||||
terminated so long as such parties remain in full compliance.
|
||||
|
||||
9. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Library or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Library (or any work based on the
|
||||
Library), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Library or works based on it.
|
||||
|
||||
10. Each time you redistribute the Library (or any work based on the
|
||||
Library), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute, link with or modify the Library
|
||||
subject to these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties with
|
||||
this License.
|
||||
|
||||
11. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Library at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Library by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Library.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under any
|
||||
particular circumstance, the balance of the section is intended to apply,
|
||||
and the section as a whole is intended to apply in other circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
12. If the distribution and/or use of the Library is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Library under this License may add
|
||||
an explicit geographical distribution limitation excluding those countries,
|
||||
so that distribution is permitted only in or among countries not thus
|
||||
excluded. In such case, this License incorporates the limitation as if
|
||||
written in the body of this License.
|
||||
|
||||
13. The Free Software Foundation may publish revised and/or new
|
||||
versions of the Lesser General Public License from time to time.
|
||||
Such new versions will be similar in spirit to the present version,
|
||||
but may differ in detail to address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Library
|
||||
specifies a version number of this License which applies to it and
|
||||
"any later version", you have the option of following the terms and
|
||||
conditions either of that version or of any later version published by
|
||||
the Free Software Foundation. If the Library does not specify a
|
||||
license version number, you may choose any version ever published by
|
||||
the Free Software Foundation.
|
||||
|
||||
14. If you wish to incorporate parts of the Library into other free
|
||||
programs whose distribution conditions are incompatible with these,
|
||||
write to the author to ask for permission. For software which is
|
||||
copyrighted by the Free Software Foundation, write to the Free
|
||||
Software Foundation; we sometimes make exceptions for this. Our
|
||||
decision will be guided by the two goals of preserving the free status
|
||||
of all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
|
||||
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
|
||||
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
|
||||
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
|
||||
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
|
||||
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
|
||||
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
|
||||
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
|
||||
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
|
||||
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
|
||||
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
|
||||
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
|
||||
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
|
||||
DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
45
build.gradle
45
build.gradle
|
@ -26,11 +26,11 @@ apply plugin: "net.minecraftforge.gradle.patcher"
|
|||
apply plugin: "net.minecraftforge.gradle.launch4j"
|
||||
|
||||
minecraft {
|
||||
version = "1.8.9"
|
||||
mappings = 'stable_20'
|
||||
version = "1.9"
|
||||
mappings = 'snapshot_nodoc_20160312'
|
||||
//mappings = "snapshot_nodoc_20151122"
|
||||
workspaceDir = "projects"
|
||||
versionJson = "jsons/1.8.9-dev.json"
|
||||
versionJson = "jsons/1.9-dev.json"
|
||||
buildUserdev = true
|
||||
buildInstaller = true
|
||||
installerVersion = "1.4"
|
||||
|
@ -66,7 +66,7 @@ extractForgeResources { exclude "**/log4j2.xml" }
|
|||
genGradleProjects { addTestCompileDep "junit:junit:4.12" }
|
||||
|
||||
processJson {
|
||||
releaseJson = "jsons/1.8.9-rel.json"
|
||||
releaseJson = "jsons/1.9-rel.json"
|
||||
addReplacements([
|
||||
"@minecraft_version@": project.minecraft.version,
|
||||
"@version@": project.version,
|
||||
|
@ -171,25 +171,25 @@ task makeMdk(type: Zip) {
|
|||
from 'gradlew'
|
||||
from 'gradlew.bat'
|
||||
into ('gradle') {
|
||||
from 'gradle'
|
||||
from 'gradle'
|
||||
}
|
||||
into ('eclipse') {
|
||||
from 'mdk/eclipse'
|
||||
}
|
||||
from changelog.output
|
||||
from ('mdk') {
|
||||
filter(ReplaceTokens, tokens: [
|
||||
VERSION: project.version,
|
||||
MAPPINGS: minecraft.mappings.replace('nodoc_', '')
|
||||
])
|
||||
exclude 'eclipse'
|
||||
rename 'gitignore\\.txt', '.gitignore'
|
||||
from 'MinecraftForge-Credits.txt'
|
||||
from 'MinecraftForge-License.txt'
|
||||
from 'Paulscode IBXM Library License.txt'
|
||||
from 'Paulscode SoundSystem CodecIBXM License.txt'
|
||||
from 'CREDITS-fml.txt'
|
||||
from 'LICENSE-fml.txt'
|
||||
filter(ReplaceTokens, tokens: [
|
||||
VERSION: project.version,
|
||||
MAPPINGS: minecraft.mappings.replace('nodoc_', '')
|
||||
])
|
||||
exclude 'eclipse'
|
||||
rename 'gitignore\\.txt', '.gitignore'
|
||||
from 'MinecraftForge-Credits.txt'
|
||||
from 'MinecraftForge-License.txt'
|
||||
from 'Paulscode IBXM Library License.txt'
|
||||
from 'Paulscode SoundSystem CodecIBXM License.txt'
|
||||
from 'CREDITS-fml.txt'
|
||||
from 'LICENSE-fml.txt'
|
||||
}
|
||||
}
|
||||
tasks.build.dependsOn makeMdk
|
||||
|
@ -374,3 +374,14 @@ String getVersionFromJava(File file)
|
|||
// should be remvoed, and the jenkisn fixed when no longer building with FG 1.2
|
||||
task setupForge { dependsOn 'setup' }
|
||||
task buildPackages { dependsOn 'build' }
|
||||
|
||||
//Temporary hack to fix compile errors caused by mappings shading in Bootstrap
|
||||
task fixParams << {
|
||||
logger.lifecycle('Fixing param names!')
|
||||
def params = new File(extractMcpMappings.destinationDir, 'params.csv')
|
||||
def text = params.text
|
||||
text = text.replaceAll('p_82499_3_,stack,', 'p_82499_3_,stackIn,')
|
||||
params.write(text)
|
||||
}
|
||||
fixParams.dependsOn('extractMcpMappings')
|
||||
extractMcpMappings.finalizedBy('fixParams')
|
||||
|
|
95
jsons/1.9-dev.json
Normal file
95
jsons/1.9-dev.json
Normal file
|
@ -0,0 +1,95 @@
|
|||
{
|
||||
"id": "@minecraft_version@-@project@@version@",
|
||||
"time": "@timestamp@",
|
||||
"releaseTime": "1960-01-01T00:00:00-0700",
|
||||
"type": "release",
|
||||
"inheritsFrom": "1.9",
|
||||
"minecraftArguments": "--version FML_DEV --tweakClass net.minecraftforge.fml.common.launcher.FMLTweaker",
|
||||
"libraries": [
|
||||
{
|
||||
"name": "net.minecraft:launchwrapper:1.12"
|
||||
},
|
||||
{
|
||||
"name": "jline:jline:2.13",
|
||||
"children": ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "com.google.code.findbugs:jsr305:1.3.9",
|
||||
"children": ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.ow2.asm:asm-debug-all:5.0.3",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "com.typesafe.akka:akka-actor_2.11:2.3.3",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "com.typesafe:config:1.2.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-actors-migration_2.11:1.1.0",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-compiler:2.11.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.plugins:scala-continuations-library_2.11:1.0.2",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.plugins:scala-continuations-plugin_2.11.1:1.0.2",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-library:2.11.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.modules:scala-parser-combinators_2.11:1.0.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-reflect:2.11.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.modules:scala-swing_2.11:1.0.1",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.modules:scala-xml_2.11:1.0.2",
|
||||
"children" : ["sources"],
|
||||
"url" : "http://repo.maven.apache.org/maven2"
|
||||
},
|
||||
{
|
||||
"name": "lzma:lzma:0.0.1"
|
||||
},
|
||||
{
|
||||
"name": "java3d:vecmath:1.5.2"
|
||||
},
|
||||
{
|
||||
"name": "net.sf.trove4j:trove4j:3.0.3"
|
||||
}
|
||||
],
|
||||
"mainClass": "net.minecraft.launchwrapper.Launch",
|
||||
"minimumLauncherVersion": 14,
|
||||
"assets": "1.8"
|
||||
}
|
144
jsons/1.9-rel.json
Normal file
144
jsons/1.9-rel.json
Normal file
|
@ -0,0 +1,144 @@
|
|||
{
|
||||
"install": {
|
||||
"profileName": "@project@",
|
||||
"target":"@minecraft_version@-@project@@version@",
|
||||
"path":"@artifact@",
|
||||
"version":"@project@ @version@",
|
||||
"filePath":"@universal_jar@",
|
||||
"welcome":"Welcome to the simple @project@ installer.",
|
||||
"minecraft":"@minecraft_version@",
|
||||
"mirrorList" : "http://files.minecraftforge.net/mirror-brand.list",
|
||||
"logo":"/big_logo.png"
|
||||
},
|
||||
"versionInfo": {
|
||||
"id": "@minecraft_version@-@project@@version@",
|
||||
"time": "@timestamp@",
|
||||
"releaseTime": "1960-01-01T00:00:00-0700",
|
||||
"type": "release",
|
||||
"minecraftArguments": "--username ${auth_player_name} --version ${version_name} --gameDir ${game_directory} --assetsDir ${assets_root} --assetIndex ${assets_index_name} --uuid ${auth_uuid} --accessToken ${auth_access_token} --userType ${user_type} --tweakClass net.minecraftforge.fml.common.launcher.FMLTweaker --versionType Forge",
|
||||
"mainClass": "net.minecraft.launchwrapper.Launch",
|
||||
"minimumLauncherVersion": 14,
|
||||
"inheritsFrom": "1.9",
|
||||
"libraries": [
|
||||
{
|
||||
"name": "@artifact@",
|
||||
"url": "http://files.minecraftforge.net/maven/"
|
||||
},
|
||||
{
|
||||
"comment": "Force the downgrade on dedicated server to match client. Netty bug: https://github.com/MinecraftForge/MinecraftForge/issues/1848",
|
||||
"name": "io.netty:netty-all:4.0.23.Final",
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "net.minecraft:launchwrapper:1.12",
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.ow2.asm:asm-all:5.0.3",
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "jline:jline:2.13",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "2d9530d0a25daffaffda7c35037b046b627bb171" ],
|
||||
"serverreq":true,
|
||||
"clientreq":false
|
||||
},
|
||||
{
|
||||
"name": "com.typesafe.akka:akka-actor_2.11:2.3.3",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "ed62e9fc709ca0f2ff1a3220daa8b70a2870078e", "25a86ccfdb6f6dfe08971f4825d0a01be83a6f2e" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "com.typesafe:config:1.2.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "f771f71fdae3df231bcd54d5ca2d57f0bf93f467", "7d7bc36df0989d72f2d5d057309675777acc528b" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-actors-migration_2.11:1.1.0",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "dfa8bc42b181d5b9f1a5dd147f8ae308b893eb6f", "8c9aaeeb68487ca519411a14068e1b4d69739207" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-compiler:2.11.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "56ea2e6c025e0821f28d73ca271218b8dd04926a", "1444992390544ba3780867a13ff696a89d7d1639" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.plugins:scala-continuations-library_2.11:1.0.2",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "87213338cd5a153a7712cb574c0ddd2edfee0386", "0b4c1bf8d48993f138d6e10c0c144e50acfff581" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang.plugins:scala-continuations-plugin_2.11.1:1.0.2",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "1f7371605d4ba42aa26d3443440c0083c587b4e9", "1ea655dda4504ae0a367327e2340cd3beaee6c73" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-library:2.11.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "0e11da23da3eabab9f4777b9220e60d44c1aab6a", "1e4df76e835201c6eabd43adca89ab11f225f134" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-parser-combinators_2.11:1.0.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "f05d7345bf5a58924f2837c6c1f4d73a938e1ff0", "a1cbbcbde1dcc614f4253ed1aa0b320bc78d8f1d" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-reflect:2.11.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "6580347e61cc7f8e802941e7fde40fa83b8badeb", "91ce0f0be20f4a536321724b4b3bbc6530ddcd88" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-swing_2.11:1.0.1",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "b1cdd92bd47b1e1837139c1c53020e86bb9112ae", "d77152691dcf5bbdb00529af37aa7d3d887b3e63" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "org.scala-lang:scala-xml_2.11:1.0.2",
|
||||
"url" : "http://files.minecraftforge.net/maven/",
|
||||
"checksums" : [ "7a80ec00aec122fba7cd4e0d4cdd87ff7e4cb6d0", "62736b01689d56b6d09a0164b7ef9da2b0b9633d" ],
|
||||
"serverreq":true,
|
||||
"clientreq":true
|
||||
},
|
||||
{
|
||||
"name": "lzma:lzma:0.0.1",
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "net.sf.jopt-simple:jopt-simple:4.6",
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "java3d:vecmath:1.5.2",
|
||||
"clientreq":true,
|
||||
"serverreq":true
|
||||
},
|
||||
{
|
||||
"name": "net.sf.trove4j:trove4j:3.0.3",
|
||||
"clientreq":true,
|
||||
"serverreq":true
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
218
jsons/1.9.json
Normal file
218
jsons/1.9.json
Normal file
|
@ -0,0 +1,218 @@
|
|||
{
|
||||
"id": "1.9",
|
||||
"time": "2016-02-29T08:50:46-05:00",
|
||||
"releaseTime": "2016-02-29T08:49:54-05:00",
|
||||
"type": "release",
|
||||
"minecraftArguments": "--username ${auth_player_name} --version ${version_name} --gameDir ${game_directory} --assetsDir ${assets_root} --assetIndex ${assets_index_name} --uuid ${auth_uuid} --accessToken ${auth_access_token} --userType ${user_type} --versionType ${version_type}",
|
||||
"libraries": [
|
||||
{
|
||||
"name": "oshi-project:oshi-core:1.1"
|
||||
},
|
||||
{
|
||||
"name": "net.java.dev.jna:jna:3.4.0"
|
||||
},
|
||||
{
|
||||
"name": "net.java.dev.jna:platform:3.4.0"
|
||||
},
|
||||
{
|
||||
"name": "com.ibm.icu:icu4j-core-mojang:51.2"
|
||||
},
|
||||
{
|
||||
"name": "net.sf.jopt-simple:jopt-simple:4.6"
|
||||
},
|
||||
{
|
||||
"name": "com.paulscode:codecjorbis:20101023"
|
||||
},
|
||||
{
|
||||
"name": "com.paulscode:codecwav:20101023"
|
||||
},
|
||||
{
|
||||
"name": "com.paulscode:libraryjavasound:20101123"
|
||||
},
|
||||
{
|
||||
"name": "com.paulscode:librarylwjglopenal:20100824"
|
||||
},
|
||||
{
|
||||
"name": "com.paulscode:soundsystem:20120107"
|
||||
},
|
||||
{
|
||||
"name": "io.netty:netty-all:4.0.23.Final"
|
||||
},
|
||||
{
|
||||
"name": "com.google.guava:guava:17.0"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.commons:commons-lang3:3.3.2"
|
||||
},
|
||||
{
|
||||
"name": "commons-io:commons-io:2.4"
|
||||
},
|
||||
{
|
||||
"name": "commons-codec:commons-codec:1.9"
|
||||
},
|
||||
{
|
||||
"name": "net.java.jinput:jinput:2.0.5"
|
||||
},
|
||||
{
|
||||
"name": "net.java.jutils:jutils:1.0.0"
|
||||
},
|
||||
{
|
||||
"name": "com.google.code.gson:gson:2.2.4"
|
||||
},
|
||||
{
|
||||
"name": "com.mojang:authlib:1.5.22"
|
||||
},
|
||||
{
|
||||
"name": "com.mojang:realms:1.8.3"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.commons:commons-compress:1.8.1"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.httpcomponents:httpclient:4.3.3"
|
||||
},
|
||||
{
|
||||
"name": "commons-logging:commons-logging:1.1.3"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.httpcomponents:httpcore:4.3.2"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.logging.log4j:log4j-api:2.0-beta9"
|
||||
},
|
||||
{
|
||||
"name": "org.apache.logging.log4j:log4j-core:2.0-beta9"
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl:2.9.4-nightly-20150209",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow"
|
||||
},
|
||||
{
|
||||
"action": "disallow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl_util:2.9.4-nightly-20150209",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow"
|
||||
},
|
||||
{
|
||||
"action": "disallow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl-platform:2.9.4-nightly-20150209",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow"
|
||||
},
|
||||
{
|
||||
"action": "disallow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
],
|
||||
"natives": {
|
||||
"linux": "natives-linux",
|
||||
"osx": "natives-osx",
|
||||
"windows": "natives-windows"
|
||||
},
|
||||
"extract": {
|
||||
"exclude": [
|
||||
"META-INF/"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl:2.9.2-nightly-20140822",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl_util:2.9.2-nightly-20140822",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "org.lwjgl.lwjgl:lwjgl-platform:2.9.2-nightly-20140822",
|
||||
"rules": [
|
||||
{
|
||||
"action": "allow",
|
||||
"os": {
|
||||
"name": "osx"
|
||||
}
|
||||
}
|
||||
],
|
||||
"natives": {
|
||||
"linux": "natives-linux",
|
||||
"osx": "natives-osx",
|
||||
"windows": "natives-windows"
|
||||
},
|
||||
"extract": {
|
||||
"exclude": [
|
||||
"META-INF/"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "net.java.jinput:jinput-platform:2.0.5",
|
||||
"natives": {
|
||||
"linux": "natives-linux",
|
||||
"osx": "natives-osx",
|
||||
"windows": "natives-windows"
|
||||
},
|
||||
"extract": {
|
||||
"exclude": [
|
||||
"META-INF/"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"mainClass": "net.minecraft.client.main.Main",
|
||||
"minimumLauncherVersion": 18,
|
||||
"assets": "1.9",
|
||||
"downloads": {
|
||||
"client": {
|
||||
"url": "https://launcher.mojang.com/mc/game/1.9/client/2f67dfe8953299440d1902f9124f0f2c3a2c940f/client.jar",
|
||||
"sha1": "2f67dfe8953299440d1902f9124f0f2c3a2c940f",
|
||||
"size": 8697592
|
||||
},
|
||||
"server": {
|
||||
"url": "https://launcher.mojang.com/mc/game/1.9/server/b4d449cf2918e0f3bd8aa18954b916a4d1880f0d/server.jar",
|
||||
"sha1": "b4d449cf2918e0f3bd8aa18954b916a4d1880f0d",
|
||||
"size": 8848015
|
||||
}
|
||||
},
|
||||
"assetIndex": {
|
||||
"totalSize": 119917473,
|
||||
"id": "1.9",
|
||||
"known": true,
|
||||
"url": "https://launchermeta.mojang.com/mc-staging/assets/1.9/cde65b47a43f638653ab1da3848b53f8a7477b16/1.9.json",
|
||||
"sha1": "cde65b47a43f638653ab1da3848b53f8a7477b16",
|
||||
"size": 136916
|
||||
}
|
||||
}
|
|
@ -1,28 +1,22 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/Block.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/Block.java
|
||||
@@ -38,8 +38,9 @@
|
||||
public class Block
|
||||
@@ -43,11 +43,12 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
-public class Block
|
||||
+public class Block extends net.minecraftforge.fml.common.registry.IForgeRegistryEntry.Impl<Block>
|
||||
{
|
||||
private static final ResourceLocation field_176230_a = new ResourceLocation("air");
|
||||
- public static final RegistryNamespacedDefaultedByKey<ResourceLocation, Block> field_149771_c = new RegistryNamespacedDefaultedByKey(field_176230_a);
|
||||
- public static final ObjectIntIdentityMap<IBlockState> field_176229_d = new ObjectIntIdentityMap();
|
||||
+ public static final RegistryNamespacedDefaultedByKey<ResourceLocation,Block> field_149771_c = net.minecraftforge.fml.common.registry.GameData.getBlockRegistry();
|
||||
+ public static final RegistryNamespacedDefaultedByKey<ResourceLocation, Block> field_149771_c = net.minecraftforge.fml.common.registry.GameData.getBlockRegistry();
|
||||
+ @Deprecated //Modders: DO NOT use this! Use GameRegistry
|
||||
+ public static final ObjectIntIdentityMap<IBlockState> field_176229_d = net.minecraftforge.fml.common.registry.GameData.getBlockStateIDMap();
|
||||
public static final AxisAlignedBB field_185505_j = new AxisAlignedBB(0.0D, 0.0D, 0.0D, 1.0D, 1.0D, 1.0D);
|
||||
public static final AxisAlignedBB field_185506_k = null;
|
||||
private CreativeTabs field_149772_a;
|
||||
public static final Block.SoundType field_149769_e = new Block.SoundType("stone", 1.0F, 1.0F);
|
||||
public static final Block.SoundType field_149766_f = new Block.SoundType("wood", 1.0F, 1.0F);
|
||||
@@ -119,6 +120,9 @@
|
||||
private IBlockState field_176228_M;
|
||||
private String field_149770_b;
|
||||
|
||||
+ public final net.minecraftforge.fml.common.registry.RegistryDelegate<Block> delegate =
|
||||
+ ((net.minecraftforge.fml.common.registry.FMLControlledNamespacedRegistry)field_149771_c).getDelegate(this, Block.class);
|
||||
+
|
||||
public static int func_149682_b(Block p_149682_0_)
|
||||
{
|
||||
return field_149771_c.func_148757_b(p_149682_0_);
|
||||
@@ -132,7 +136,8 @@
|
||||
@@ -83,7 +84,8 @@
|
||||
|
||||
public static Block func_149729_e(int p_149729_0_)
|
||||
{
|
||||
|
@ -32,16 +26,16 @@
|
|||
}
|
||||
|
||||
public static IBlockState func_176220_d(int p_176220_0_)
|
||||
@@ -303,7 +308,7 @@
|
||||
@@ -268,7 +270,7 @@
|
||||
|
||||
public boolean func_176200_f(World p_176200_1_, BlockPos p_176200_2_)
|
||||
public boolean func_176200_f(IBlockAccess p_176200_1_, BlockPos p_176200_2_)
|
||||
{
|
||||
- return false;
|
||||
+ return func_149688_o().func_76222_j();
|
||||
+ return p_176200_1_.func_180495_p(p_176200_2_).func_185904_a().func_76222_j();
|
||||
}
|
||||
|
||||
public Block func_149711_c(float p_149711_1_)
|
||||
@@ -340,9 +345,10 @@
|
||||
@@ -305,9 +307,10 @@
|
||||
return this.field_149789_z;
|
||||
}
|
||||
|
||||
|
@ -52,33 +46,33 @@
|
|||
+ return hasTileEntity(func_176223_P());
|
||||
}
|
||||
|
||||
public final void func_149676_a(float p_149676_1_, float p_149676_2_, float p_149676_3_, float p_149676_4_, float p_149676_5_, float p_149676_6_)
|
||||
@@ -359,13 +365,13 @@
|
||||
public int func_176207_c(IBlockAccess p_176207_1_, BlockPos p_176207_2_)
|
||||
public AxisAlignedBB func_185496_a(IBlockState p_185496_1_, IBlockAccess p_185496_2_, BlockPos p_185496_3_)
|
||||
@@ -346,13 +349,13 @@
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int func_185484_c(IBlockState p_185484_1_, IBlockAccess p_185484_2_, BlockPos p_185484_3_)
|
||||
{
|
||||
Block block = p_176207_1_.func_180495_p(p_176207_2_).func_177230_c();
|
||||
- int i = p_176207_1_.func_175626_b(p_176207_2_, block.func_149750_m());
|
||||
+ int i = p_176207_1_.func_175626_b(p_176207_2_, block.getLightValue(p_176207_1_, p_176207_2_));
|
||||
- int i = p_185484_2_.func_175626_b(p_185484_3_, p_185484_1_.func_185906_d());
|
||||
+ int i = p_185484_2_.func_175626_b(p_185484_3_, p_185484_1_.getLightValue(p_185484_2_, p_185484_3_));
|
||||
|
||||
if (i == 0 && block instanceof BlockSlab)
|
||||
if (i == 0 && p_185484_1_.func_177230_c() instanceof BlockSlab)
|
||||
{
|
||||
p_176207_2_ = p_176207_2_.func_177977_b();
|
||||
block = p_176207_1_.func_180495_p(p_176207_2_).func_177230_c();
|
||||
- return p_176207_1_.func_175626_b(p_176207_2_, block.func_149750_m());
|
||||
+ return p_176207_1_.func_175626_b(p_176207_2_, block.getLightValue(p_176207_1_, p_176207_2_));
|
||||
p_185484_3_ = p_185484_3_.func_177977_b();
|
||||
p_185484_1_ = p_185484_2_.func_180495_p(p_185484_3_);
|
||||
- return p_185484_2_.func_175626_b(p_185484_3_, p_185484_1_.func_185906_d());
|
||||
+ return p_185484_2_.func_175626_b(p_185484_3_, p_185484_1_.getLightValue(p_185484_2_, p_185484_3_));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -376,7 +382,7 @@
|
||||
@SideOnly(Side.CLIENT)
|
||||
public boolean func_176225_a(IBlockAccess p_176225_1_, BlockPos p_176225_2_, EnumFacing p_176225_3_)
|
||||
{
|
||||
- return p_176225_3_ == EnumFacing.DOWN && this.field_149760_C > 0.0D ? true : (p_176225_3_ == EnumFacing.UP && this.field_149756_F < 1.0D ? true : (p_176225_3_ == EnumFacing.NORTH && this.field_149754_D > 0.0D ? true : (p_176225_3_ == EnumFacing.SOUTH && this.field_149757_G < 1.0D ? true : (p_176225_3_ == EnumFacing.WEST && this.field_149759_B > 0.0D ? true : (p_176225_3_ == EnumFacing.EAST && this.field_149755_E < 1.0D ? true : !p_176225_1_.func_180495_p(p_176225_2_).func_177230_c().func_149662_c())))));
|
||||
+ return p_176225_3_ == EnumFacing.DOWN && this.field_149760_C > 0.0D ? true : (p_176225_3_ == EnumFacing.UP && this.field_149756_F < 1.0D ? true : (p_176225_3_ == EnumFacing.NORTH && this.field_149754_D > 0.0D ? true : (p_176225_3_ == EnumFacing.SOUTH && this.field_149757_G < 1.0D ? true : (p_176225_3_ == EnumFacing.WEST && this.field_149759_B > 0.0D ? true : (p_176225_3_ == EnumFacing.EAST && this.field_149755_E < 1.0D ? true : !p_176225_1_.func_180495_p(p_176225_2_).func_177230_c().doesSideBlockRendering(p_176225_1_, p_176225_2_, p_176225_3_))))));
|
||||
@@ -415,7 +418,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- return !p_176225_2_.func_180495_p(p_176225_3_.func_177972_a(p_176225_4_)).func_185914_p();
|
||||
+ return !p_176225_2_.func_180495_p(p_176225_3_.func_177972_a(p_176225_4_)).doesSideBlockRendering(p_176225_2_, p_176225_3_.func_177972_a(p_176225_4_), p_176225_4_.func_176734_d());
|
||||
}
|
||||
|
||||
public boolean func_176212_b(IBlockAccess p_176212_1_, BlockPos p_176212_2_, EnumFacing p_176212_3_)
|
||||
@@ -453,6 +459,10 @@
|
||||
@SideOnly(Side.CLIENT)
|
||||
@@ -472,6 +475,10 @@
|
||||
|
||||
public void func_180663_b(World p_180663_1_, BlockPos p_180663_2_, IBlockState p_180663_3_)
|
||||
{
|
||||
|
@ -89,17 +83,17 @@
|
|||
}
|
||||
|
||||
public int func_149745_a(Random p_149745_1_)
|
||||
@@ -467,8 +477,7 @@
|
||||
@@ -486,8 +493,7 @@
|
||||
|
||||
public float func_180647_a(EntityPlayer p_180647_1_, World p_180647_2_, BlockPos p_180647_3_)
|
||||
public float func_180647_a(IBlockState p_180647_1_, EntityPlayer p_180647_2_, World p_180647_3_, BlockPos p_180647_4_)
|
||||
{
|
||||
- float f = this.func_176195_g(p_180647_2_, p_180647_3_);
|
||||
- return f < 0.0F ? 0.0F : (!p_180647_1_.func_146099_a(this) ? p_180647_1_.func_180471_a(this) / f / 100.0F : p_180647_1_.func_180471_a(this) / f / 30.0F);
|
||||
+ return net.minecraftforge.common.ForgeHooks.blockStrength(p_180647_2_.func_180495_p(p_180647_3_), p_180647_1_, p_180647_2_, p_180647_3_);
|
||||
- float f = p_180647_1_.func_185887_b(p_180647_3_, p_180647_4_);
|
||||
- return f < 0.0F ? 0.0F : (!p_180647_2_.func_184823_b(p_180647_1_) ? p_180647_2_.func_184813_a(p_180647_1_) / f / 100.0F : p_180647_2_.func_184813_a(p_180647_1_) / f / 30.0F);
|
||||
+ return net.minecraftforge.common.ForgeHooks.blockStrength(p_180647_1_, p_180647_2_, p_180647_3_, p_180647_4_);
|
||||
}
|
||||
|
||||
public final void func_176226_b(World p_176226_1_, BlockPos p_176226_2_, IBlockState p_176226_3_, int p_176226_4_)
|
||||
@@ -478,20 +487,16 @@
|
||||
@@ -497,20 +503,16 @@
|
||||
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
|
@ -125,7 +119,7 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
@@ -499,8 +504,13 @@
|
||||
@@ -518,8 +520,13 @@
|
||||
|
||||
public static void func_180635_a(World p_180635_0_, BlockPos p_180635_1_, ItemStack p_180635_2_)
|
||||
{
|
||||
|
@ -140,7 +134,7 @@
|
|||
float f = 0.5F;
|
||||
double d0 = (double)(p_180635_0_.field_73012_v.nextFloat() * f) + (double)(1.0F - f) * 0.5D;
|
||||
double d1 = (double)(p_180635_0_.field_73012_v.nextFloat() * f) + (double)(1.0F - f) * 0.5D;
|
||||
@@ -687,7 +697,7 @@
|
||||
@@ -588,7 +595,7 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
|
@ -148,15 +142,15 @@
|
|||
+ return p_176196_1_.func_180495_p(p_176196_2_).func_177230_c().func_176200_f(p_176196_1_, p_176196_2_);
|
||||
}
|
||||
|
||||
public boolean func_180639_a(World p_180639_1_, BlockPos p_180639_2_, IBlockState p_180639_3_, EntityPlayer p_180639_4_, EnumFacing p_180639_5_, float p_180639_6_, float p_180639_7_, float p_180639_8_)
|
||||
@@ -799,25 +809,35 @@
|
||||
p_180657_2_.func_71029_a(StatList.field_75934_C[func_149682_b(this)]);
|
||||
public boolean func_180639_a(World p_180639_1_, BlockPos p_180639_2_, IBlockState p_180639_3_, EntityPlayer p_180639_4_, EnumHand p_180639_5_, ItemStack p_180639_6_, EnumFacing p_180639_7_, float p_180639_8_, float p_180639_9_, float p_180639_10_)
|
||||
@@ -638,25 +645,35 @@
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
p_180657_2_.func_71020_j(0.025F);
|
||||
|
||||
- if (this.func_149700_E() && EnchantmentHelper.func_77502_d(p_180657_2_))
|
||||
+ if (this.canSilkHarvest(p_180657_1_, p_180657_3_, p_180657_1_.func_180495_p(p_180657_3_), p_180657_2_) && EnchantmentHelper.func_77502_d(p_180657_2_))
|
||||
- if (this.func_149700_E() && EnchantmentHelper.func_77506_a(Enchantments.field_185306_r, p_180657_6_) > 0)
|
||||
+ if (this.canSilkHarvest(p_180657_1_, p_180657_3_, p_180657_4_, p_180657_2_) && EnchantmentHelper.func_77506_a(Enchantments.field_185306_r, p_180657_6_) > 0)
|
||||
{
|
||||
+ java.util.ArrayList<ItemStack> items = new java.util.ArrayList<ItemStack>();
|
||||
+ java.util.List<ItemStack> items = new java.util.ArrayList<ItemStack>();
|
||||
ItemStack itemstack = this.func_180643_i(p_180657_4_);
|
||||
|
||||
if (itemstack != null)
|
||||
|
@ -165,16 +159,16 @@
|
|||
+ items.add(itemstack);
|
||||
}
|
||||
+
|
||||
+ net.minecraftforge.event.ForgeEventFactory.fireBlockHarvesting(items, p_180657_1_, p_180657_3_, p_180657_1_.func_180495_p(p_180657_3_), 0, 1.0f, true, p_180657_2_);
|
||||
+ for (ItemStack stack : items)
|
||||
+ net.minecraftforge.event.ForgeEventFactory.fireBlockHarvesting(items, p_180657_1_, p_180657_3_, p_180657_4_, 0, 1.0f, true, p_180657_2_);
|
||||
+ for (ItemStack item : items)
|
||||
+ {
|
||||
+ func_180635_a(p_180657_1_, p_180657_3_, stack);
|
||||
+ func_180635_a(p_180657_1_, p_180657_3_, item);
|
||||
+ }
|
||||
}
|
||||
else
|
||||
{
|
||||
+ harvesters.set(p_180657_2_);
|
||||
int i = EnchantmentHelper.func_77517_e(p_180657_2_);
|
||||
int i = EnchantmentHelper.func_77506_a(Enchantments.field_185308_t, p_180657_6_);
|
||||
this.func_176226_b(p_180657_1_, p_180657_3_, p_180657_4_, i);
|
||||
+ harvesters.set(null);
|
||||
}
|
||||
|
@ -183,12 +177,25 @@
|
|||
+ @Deprecated //Forge: State sensitive version
|
||||
protected boolean func_149700_E()
|
||||
{
|
||||
- return this.func_149686_d() && !this.field_149758_A;
|
||||
+ return this.func_149686_d() && !this.hasTileEntity(silk_check_state.get());
|
||||
- return this.func_176223_P().func_185917_h() && !this.field_149758_A;
|
||||
+ return this.func_176223_P().func_185917_h() && !this.hasTileEntity(silk_check_state.get());
|
||||
}
|
||||
|
||||
protected ItemStack func_180643_i(IBlockState p_180643_1_)
|
||||
@@ -1010,6 +1030,1147 @@
|
||||
@@ -747,9 +764,11 @@
|
||||
p_176216_2_.field_70181_x = 0.0D;
|
||||
}
|
||||
|
||||
+ @Deprecated // Forge: Use more sensitive version below: getPickBlock
|
||||
public ItemStack func_185473_a(World p_185473_1_, BlockPos p_185473_2_, IBlockState p_185473_3_)
|
||||
{
|
||||
- return new ItemStack(Item.func_150898_a(this), 1, this.func_180651_a(p_185473_3_));
|
||||
+ Item item = Item.func_150898_a(this);
|
||||
+ return item == null ? null : new ItemStack(item, 1, this.func_180651_a(p_185473_3_));
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
@@ -844,6 +863,1141 @@
|
||||
return "Block{" + field_149771_c.func_177774_c(this) + "}";
|
||||
}
|
||||
|
||||
|
@ -200,42 +207,45 @@
|
|||
+ /**
|
||||
+ * Get a light value for the block at the specified coordinates, normal ranges are between 0 and 15
|
||||
+ *
|
||||
+ * @param state Block state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return The light value
|
||||
+ */
|
||||
+ public int getLightValue(IBlockAccess world, BlockPos pos)
|
||||
+ public int getLightValue(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ Block block = world.func_180495_p(pos).func_177230_c();
|
||||
+ if (block != this)
|
||||
+ IBlockState other = world.func_180495_p(pos);
|
||||
+ if (other.func_177230_c() != this)
|
||||
+ {
|
||||
+ return block.getLightValue(world, pos);
|
||||
+ return other.getLightValue(world, pos);
|
||||
+ }
|
||||
+ return func_149750_m();
|
||||
+ return state.func_185906_d();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Checks if a player or entity can use this block to 'climb' like a ladder.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param entity The entity trying to use the ladder, CAN be null.
|
||||
+ * @return True if the block should act like a ladder
|
||||
+ */
|
||||
+ public boolean isLadder(IBlockAccess world, BlockPos pos, EntityLivingBase entity) { return false; }
|
||||
+ public boolean isLadder(IBlockState state, IBlockAccess world, BlockPos pos, EntityLivingBase entity) { return false; }
|
||||
+
|
||||
+ /**
|
||||
+ * Return true if the block is a normal, solid cube. This
|
||||
+ * determines indirect power state, entity ejection from blocks, and a few
|
||||
+ * others.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return True if the block is a full cube
|
||||
+ */
|
||||
+ public boolean isNormalCube(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean isNormalCube(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return func_149688_o().func_76218_k() && func_149686_d() && !func_149744_f();
|
||||
+ return state.func_185904_a().func_76218_k() && state.func_185917_h() && !state.func_185897_m();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -244,31 +254,35 @@
|
|||
+ * Faces which are fully opaque should return true, faces with transparency
|
||||
+ * or faces which do not span the full size of the block should return false.
|
||||
+ *
|
||||
+ * @param state The current block state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param side The side to check
|
||||
+ * @param face The side to check
|
||||
+ * @return True if the block is opaque on the specified side.
|
||||
+ */
|
||||
+ public boolean doesSideBlockRendering(IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ public boolean doesSideBlockRendering(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ {
|
||||
+ return func_149662_c();
|
||||
+ return state.func_185914_p();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Checks if the block is a solid face on the given side, used by placement logic.
|
||||
+ *
|
||||
+ * @param base_state The base state, getActualState should be called first
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param side The side to check
|
||||
+ * @return True if the block is solid on the specified side.
|
||||
+ */
|
||||
+ public boolean isSideSolid(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ public boolean isSideSolid(IBlockState base_state, IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ {
|
||||
+ IBlockState state = this.func_176221_a(world.func_180495_p(pos), world, pos);
|
||||
+ if (base_state.func_185896_q() && side == EnumFacing.UP) // Short circuit to vanilla function if its true
|
||||
+ return true;
|
||||
+
|
||||
+ if (this instanceof BlockSlab)
|
||||
+ {
|
||||
+ return func_149730_j()
|
||||
+ IBlockState state = this.func_176221_a(base_state, world, pos);
|
||||
+ return base_state.func_185913_b()
|
||||
+ || (state.func_177229_b(BlockSlab.field_176554_a) == BlockSlab.EnumBlockHalf.TOP && side == EnumFacing.UP )
|
||||
+ || (state.func_177229_b(BlockSlab.field_176554_a) == BlockSlab.EnumBlockHalf.BOTTOM && side == EnumFacing.DOWN);
|
||||
+ }
|
||||
|
@ -278,6 +292,7 @@
|
|||
+ }
|
||||
+ else if (this instanceof BlockStairs)
|
||||
+ {
|
||||
+ IBlockState state = this.func_176221_a(base_state, world, pos);
|
||||
+ boolean flipped = state.func_177229_b(BlockStairs.field_176308_b) == BlockStairs.EnumHalf.TOP;
|
||||
+ BlockStairs.EnumShape shape = (BlockStairs.EnumShape)state.func_177229_b(BlockStairs.field_176310_M);
|
||||
+ EnumFacing facing = (EnumFacing)state.func_177229_b(BlockStairs.field_176309_a);
|
||||
|
@ -298,6 +313,7 @@
|
|||
+ }
|
||||
+ else if (this instanceof BlockSnow)
|
||||
+ {
|
||||
+ IBlockState state = this.func_176221_a(base_state, world, pos);
|
||||
+ return ((Integer)state.func_177229_b(BlockSnow.field_176315_a)) >= 8;
|
||||
+ }
|
||||
+ else if (this instanceof BlockHopper && side == EnumFacing.UP)
|
||||
|
@ -308,7 +324,7 @@
|
|||
+ {
|
||||
+ return true;
|
||||
+ }
|
||||
+ return isNormalCube(world, pos);
|
||||
+ return isNormalCube(base_state, world, pos);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -330,13 +346,14 @@
|
|||
+ * useful for creating pure logic-blocks that will be invisible
|
||||
+ * to the player and otherwise interact as air would.
|
||||
+ *
|
||||
+ * @param sata The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return True if the block considered air
|
||||
+ */
|
||||
+ public boolean isAir(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean isAir(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return func_149688_o() == Material.field_151579_a;
|
||||
+ return state.func_185904_a() == Material.field_151579_a;
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -362,6 +379,7 @@
|
|||
+ * Note: When used in multiplayer, this is called on both client and
|
||||
+ * server sides!
|
||||
+ *
|
||||
+ * @param state The current state.
|
||||
+ * @param world The current world
|
||||
+ * @param player The player damaging the block, may be null
|
||||
+ * @param pos Block position in world
|
||||
|
@ -369,9 +387,10 @@
|
|||
+ * Can be useful to delay the destruction of tile entities till after harvestBlock
|
||||
+ * @return True if the block is actually destroyed.
|
||||
+ */
|
||||
+ public boolean removedByPlayer(World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ public boolean removedByPlayer(IBlockState state, World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ {
|
||||
+ return world.func_175698_g(pos);
|
||||
+ this.func_176208_a(world, pos, state, player);
|
||||
+ return world.func_180501_a(pos, net.minecraft.init.Blocks.field_150350_a.func_176223_P(), world.field_72995_K ? 11 : 3);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -535,23 +554,15 @@
|
|||
+ * Determines if a specified mob type can spawn on this block, returning false will
|
||||
+ * prevent any mob from spawning on the block.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param type The Mob Category Type
|
||||
+ * @return True to allow a mob of the specified category to spawn, false to prevent it.
|
||||
+ */
|
||||
+ public boolean canCreatureSpawn(IBlockAccess world, BlockPos pos, net.minecraft.entity.EntityLiving.SpawnPlacementType type)
|
||||
+ public boolean canCreatureSpawn(IBlockState state, IBlockAccess world, BlockPos pos, net.minecraft.entity.EntityLiving.SpawnPlacementType type)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ if (this instanceof BlockSlab)
|
||||
+ {
|
||||
+ return (func_149730_j() || state.func_177229_b(BlockSlab.field_176554_a) == BlockSlab.EnumBlockHalf.TOP);
|
||||
+ }
|
||||
+ else if (this instanceof BlockStairs)
|
||||
+ {
|
||||
+ return state.func_177229_b(BlockStairs.field_176308_b) == BlockStairs.EnumHalf.TOP;
|
||||
+ }
|
||||
+ return isSideSolid(world, pos, EnumFacing.UP);
|
||||
+ return isSideSolid(state, world, pos, EnumFacing.UP);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -559,12 +570,13 @@
|
|||
+ * players to sleep in it, though the block has to specifically
|
||||
+ * perform the sleeping functionality in it's activated event.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param player The player or camera entity, null in some cases.
|
||||
+ * @return True to treat this as a bed
|
||||
+ */
|
||||
+ public boolean isBed(IBlockAccess world, BlockPos pos, Entity player)
|
||||
+ public boolean isBed(IBlockState state, IBlockAccess world, BlockPos pos, Entity player)
|
||||
+ {
|
||||
+ return this == net.minecraft.init.Blocks.field_150324_C;
|
||||
+ }
|
||||
|
@ -573,12 +585,13 @@
|
|||
+ * Returns the position that the player is moved to upon
|
||||
+ * waking up, or respawning at the bed.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param player The player or camera entity, null in some cases.
|
||||
+ * @return The spawn position
|
||||
+ */
|
||||
+ public BlockPos getBedSpawnPosition(IBlockAccess world, BlockPos pos, EntityPlayer player)
|
||||
+ public BlockPos getBedSpawnPosition(IBlockState state, IBlockAccess world, BlockPos pos, EntityPlayer player)
|
||||
+ {
|
||||
+ if (world instanceof World)
|
||||
+ return BlockBed.func_176468_a((World)world, pos, 0);
|
||||
|
@ -608,13 +621,14 @@
|
|||
+ * Returns the direction of the block. Same values that
|
||||
+ * are returned by BlockDirectional
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return Bed direction
|
||||
+ */
|
||||
+ public EnumFacing getBedDirection(IBlockAccess world, BlockPos pos)
|
||||
+ public EnumFacing getBedDirection(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return (EnumFacing)func_176221_a(world.func_180495_p(pos), world, pos).func_177229_b(BlockDirectional.field_176387_N);
|
||||
+ return (EnumFacing)func_176221_a(state, world, pos).func_177229_b(BlockHorizontal.field_185512_D);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -632,19 +646,20 @@
|
|||
+ /**
|
||||
+ * Called when a leaf should start its decay process.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ */
|
||||
+ public void beginLeavesDecay(World world, BlockPos pos){}
|
||||
+ public void beginLeavesDecay(IBlockState state, World world, BlockPos pos){}
|
||||
+
|
||||
+ /**
|
||||
+ * Determines if this block can prevent leaves connected to it from decaying.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return true if the presence this block can prevent leaves from decaying.
|
||||
+ */
|
||||
+ public boolean canSustainLeaves(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean canSustainLeaves(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return false;
|
||||
+ }
|
||||
|
@ -652,25 +667,27 @@
|
|||
+ /**
|
||||
+ * Determines if this block is considered a leaf block, used to apply the leaf decay and generation system.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return true if this block is considered leaves.
|
||||
+ */
|
||||
+ public boolean isLeaves(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean isLeaves(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return func_149688_o() == Material.field_151584_j;
|
||||
+ return state.func_185904_a() == Material.field_151584_j;
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Used during tree growth to determine if newly generated leaves can replace this block.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return true if this block can be replaced by growing leaves.
|
||||
+ */
|
||||
+ public boolean canBeReplacedByLeaves(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean canBeReplacedByLeaves(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return !func_149730_j();
|
||||
+ return !state.func_185913_b();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -687,15 +704,16 @@
|
|||
+ /**
|
||||
+ * Determines if the current block is replaceable by Ore veins during world generation.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param target The generic target block the gen is looking for, Standards define stone
|
||||
+ * for overworld generation, and neatherack for the nether.
|
||||
+ * @return True to allow this block to be replaced by a ore
|
||||
+ */
|
||||
+ public boolean isReplaceableOreGen(World world, BlockPos pos, com.google.common.base.Predicate<IBlockState> target)
|
||||
+ public boolean isReplaceableOreGen(IBlockState state, IBlockAccess world, BlockPos pos, com.google.common.base.Predicate<IBlockState> target)
|
||||
+ {
|
||||
+ return target.apply(world.func_180495_p(pos));
|
||||
+ return target.apply(state);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -731,27 +749,29 @@
|
|||
+ * Determine if this block can make a redstone connection on the side provided,
|
||||
+ * Useful to control which sides are inputs and outputs for redstone wires.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param side The side that is trying to make the connection, CAN BE NULL
|
||||
+ * @return True to make the connection
|
||||
+ */
|
||||
+ public boolean canConnectRedstone(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ public boolean canConnectRedstone(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ {
|
||||
+ return func_149744_f() && side != null;
|
||||
+ return state.func_185897_m() && side != null;
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Determines if a torch can be placed on the top surface of this block.
|
||||
+ * Useful for creating your own block that torches can be on, such as fences.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return True to allow the torch to be placed
|
||||
+ */
|
||||
+ public boolean canPlaceTorchOnTop(IBlockAccess world, BlockPos pos)
|
||||
+ public boolean canPlaceTorchOnTop(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ if (isSideSolid(world, pos, EnumFacing.UP))
|
||||
+ if (state.isSideSolid(world, pos, EnumFacing.UP))
|
||||
+ {
|
||||
+ return true;
|
||||
+ }
|
||||
|
@ -780,22 +800,9 @@
|
|||
+ * @param target The full target the player is looking at
|
||||
+ * @return A ItemStack to add to the player's inventory, Null if nothing should be added.
|
||||
+ */
|
||||
+ public ItemStack getPickBlock(MovingObjectPosition target, World world, BlockPos pos, EntityPlayer player)
|
||||
+ public ItemStack getPickBlock(IBlockState state, RayTraceResult target, World world, BlockPos pos, EntityPlayer player)
|
||||
+ {
|
||||
+ return getPickBlock(target, world, pos);
|
||||
+ }
|
||||
+ @Deprecated
|
||||
+ public ItemStack getPickBlock(MovingObjectPosition target, World world, BlockPos pos)
|
||||
+ {
|
||||
+ Item item = func_180665_b(world, pos);
|
||||
+
|
||||
+ if (item == null)
|
||||
+ {
|
||||
+ return null;
|
||||
+ }
|
||||
+
|
||||
+ Block block = item instanceof ItemBlock && !func_149648_K() ? Block.func_149634_a(item) : this;
|
||||
+ return new ItemStack(item, 1, block.func_176222_j(world, pos));
|
||||
+ return func_185473_a(world, pos, state);
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -821,7 +828,7 @@
|
|||
+ * @param numberOfParticles that vanilla would have spawned.
|
||||
+ * @return True to prevent vanilla landing particles form spawning.
|
||||
+ */
|
||||
+ public boolean addLandingEffects(net.minecraft.world.WorldServer worldObj, BlockPos blockPosition, IBlockState iblockstate, EntityLivingBase entity, int numberOfParticles )
|
||||
+ public boolean addLandingEffects(IBlockState state, net.minecraft.world.WorldServer worldObj, BlockPos blockPosition, IBlockState iblockstate, EntityLivingBase entity, int numberOfParticles )
|
||||
+ {
|
||||
+ return false;
|
||||
+ }
|
||||
|
@ -832,13 +839,14 @@
|
|||
+ * control over the particles. Useful when you have entirely different
|
||||
+ * texture sheets for different sides/locations in the world.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param target The target the player is looking at {x/y/z/side/sub}
|
||||
+ * @param effectRenderer A reference to the current effect renderer.
|
||||
+ * @return True to prevent vanilla digging particles form spawning.
|
||||
+ */
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
+ public boolean addHitEffects(World worldObj, MovingObjectPosition target, net.minecraft.client.particle.EffectRenderer effectRenderer)
|
||||
+ public boolean addHitEffects(IBlockState state, World worldObj, RayTraceResult target, net.minecraft.client.particle.EffectRenderer effectRenderer)
|
||||
+ {
|
||||
+ return false;
|
||||
+ }
|
||||
|
@ -871,15 +879,15 @@
|
|||
+ * Plains check if its grass or dirt
|
||||
+ * Water check if its still water
|
||||
+ *
|
||||
+ * @param state The Current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param direction The direction relative to the given position the plant wants to be, typically its UP
|
||||
+ * @param plantable The plant that wants to check
|
||||
+ * @return True to allow the plant to be planted/stay.
|
||||
+ */
|
||||
+ public boolean canSustainPlant(IBlockAccess world, BlockPos pos, EnumFacing direction, net.minecraftforge.common.IPlantable plantable)
|
||||
+ public boolean canSustainPlant(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing direction, net.minecraftforge.common.IPlantable plantable)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ IBlockState plant = plantable.getPlant(world, pos.func_177972_a(direction));
|
||||
+ net.minecraftforge.common.EnumPlantType plantType = plantable.getPlantType(world, pos.func_177972_a(direction));
|
||||
+
|
||||
|
@ -893,7 +901,7 @@
|
|||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ if (plantable instanceof BlockBush && ((BlockBush)plantable).func_149854_a(this))
|
||||
+ if (plantable instanceof BlockBush && ((BlockBush)plantable).func_185514_i(state))
|
||||
+ {
|
||||
+ return true;
|
||||
+ }
|
||||
|
@ -903,15 +911,15 @@
|
|||
+ case Desert: return this == net.minecraft.init.Blocks.field_150354_m || this == net.minecraft.init.Blocks.field_150405_ch || this == net.minecraft.init.Blocks.field_150406_ce || this == net.minecraft.init.Blocks.field_150346_d;
|
||||
+ case Nether: return this == net.minecraft.init.Blocks.field_150425_aM;
|
||||
+ case Crop: return this == net.minecraft.init.Blocks.field_150458_ak;
|
||||
+ case Cave: return isSideSolid(world, pos, EnumFacing.UP);
|
||||
+ case Cave: return state.isSideSolid(world, pos, EnumFacing.UP);
|
||||
+ case Plains: return this == net.minecraft.init.Blocks.field_150349_c || this == net.minecraft.init.Blocks.field_150346_d || this == net.minecraft.init.Blocks.field_150458_ak;
|
||||
+ case Water: return func_149688_o() == Material.field_151586_h && ((Integer)state.func_177229_b(BlockLiquid.field_176367_b)) == 0;
|
||||
+ case Water: return state.func_185904_a() == Material.field_151586_h && state.func_177229_b(BlockLiquid.field_176367_b) == 0;
|
||||
+ case Beach:
|
||||
+ boolean isBeach = this == net.minecraft.init.Blocks.field_150349_c || this == net.minecraft.init.Blocks.field_150346_d || this == net.minecraft.init.Blocks.field_150354_m;
|
||||
+ boolean hasWater = (world.func_180495_p(pos.func_177974_f()).func_177230_c().func_149688_o() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177976_e()).func_177230_c().func_149688_o() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177978_c()).func_177230_c().func_149688_o() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177968_d()).func_177230_c().func_149688_o() == Material.field_151586_h);
|
||||
+ boolean hasWater = (world.func_180495_p(pos.func_177974_f()).func_185904_a() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177976_e()).func_185904_a() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177978_c()).func_185904_a() == Material.field_151586_h ||
|
||||
+ world.func_180495_p(pos.func_177968_d()).func_185904_a() == Material.field_151586_h);
|
||||
+ return isBeach && hasWater;
|
||||
+ }
|
||||
+
|
||||
|
@ -927,11 +935,12 @@
|
|||
+ *
|
||||
+ * Note: This happens DURING the generation, the generation may not be complete when this is called.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world Current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @param source Source plant's position in world
|
||||
+ */
|
||||
+ public void onPlantGrow(World world, BlockPos pos, BlockPos source)
|
||||
+ public void onPlantGrow(IBlockState state, World world, BlockPos pos, BlockPos source)
|
||||
+ {
|
||||
+ if (this == net.minecraft.init.Blocks.field_150349_c || this == net.minecraft.init.Blocks.field_150458_ak)
|
||||
+ {
|
||||
|
@ -966,27 +975,43 @@
|
|||
+ * Recommended that you have your tile entity call relight after being placed if you
|
||||
+ * rely on it for light info.
|
||||
+ *
|
||||
+ * @param state The Block state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return The amount of light to block, 0 for air, 255 for fully opaque.
|
||||
+ */
|
||||
+ public int getLightOpacity(IBlockAccess world, BlockPos pos)
|
||||
+ public int getLightOpacity(IBlockState state, IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return func_149717_k();
|
||||
+ return state.func_185891_c();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Determines if this block is can be destroyed by the specified entities normal behavior.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The current world
|
||||
+ * @param pos Block position in world
|
||||
+ * @return True to allow the ender dragon to destroy this block
|
||||
+ */
|
||||
+ public boolean canEntityDestroy(IBlockAccess world, BlockPos pos, Entity entity)
|
||||
+ public boolean canEntityDestroy(IBlockState state, IBlockAccess world, BlockPos pos, Entity entity)
|
||||
+ {
|
||||
+ if (entity instanceof net.minecraft.entity.boss.EntityDragon)
|
||||
+ {
|
||||
+ return this != net.minecraft.init.Blocks.field_180401_cv && this != net.minecraft.init.Blocks.field_150343_Z && this != net.minecraft.init.Blocks.field_150377_bs && this != net.minecraft.init.Blocks.field_150357_h && this != net.minecraft.init.Blocks.field_150483_bI;
|
||||
+ return this != net.minecraft.init.Blocks.field_180401_cv &&
|
||||
+ this != net.minecraft.init.Blocks.field_150343_Z &&
|
||||
+ this != net.minecraft.init.Blocks.field_150377_bs &&
|
||||
+ this != net.minecraft.init.Blocks.field_150357_h &&
|
||||
+ this != net.minecraft.init.Blocks.field_150384_bq &&
|
||||
+ this != net.minecraft.init.Blocks.field_150378_br &&
|
||||
+ this != net.minecraft.init.Blocks.field_150483_bI &&
|
||||
+ this != net.minecraft.init.Blocks.field_185776_dc &&
|
||||
+ this != net.minecraft.init.Blocks.field_185777_dd &&
|
||||
+ this != net.minecraft.init.Blocks.field_150411_aY &&
|
||||
+ this != net.minecraft.init.Blocks.field_185775_db;
|
||||
+ }
|
||||
+ else if (entity instanceof net.minecraft.entity.boss.EntityWither)
|
||||
+ {
|
||||
+ return net.minecraft.entity.boss.EntityWither.func_181033_a(this);
|
||||
+ }
|
||||
+
|
||||
+ return true;
|
||||
|
@ -1019,7 +1044,7 @@
|
|||
+ public boolean rotateBlock(World world, BlockPos pos, EnumFacing axis)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty<?> prop : state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("facing") || prop.func_177701_a().equals("rotation"))
|
||||
+ {
|
||||
|
@ -1040,10 +1065,11 @@
|
|||
+ public EnumFacing[] getValidRotations(World world, BlockPos pos)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty<?> prop : state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("facing") && prop.func_177699_b() == EnumFacing.class)
|
||||
+ {
|
||||
+ @SuppressWarnings("unchecked")
|
||||
+ java.util.Collection<EnumFacing> values = ((java.util.Collection<EnumFacing>)prop.func_177700_c());
|
||||
+ return values.toArray(new EnumFacing[values.size()]);
|
||||
+ }
|
||||
|
@ -1070,10 +1096,11 @@
|
|||
+ * @param color The color to change to
|
||||
+ * @return If the recoloring was successful
|
||||
+ */
|
||||
+ @SuppressWarnings({ "unchecked", "rawtypes" })
|
||||
+ public boolean recolorBlock(World world, BlockPos pos, EnumFacing side, net.minecraft.item.EnumDyeColor color)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty prop : state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("color") && prop.func_177699_b() == net.minecraft.item.EnumDyeColor.class)
|
||||
+ {
|
||||
|
@ -1091,12 +1118,13 @@
|
|||
+ /**
|
||||
+ * Gathers how much experience this block drops when broken.
|
||||
+ *
|
||||
+ * @param state The current state
|
||||
+ * @param world The world
|
||||
+ * @param pos Block position
|
||||
+ * @param fortune
|
||||
+ * @return Amount of XP from breaking this block.
|
||||
+ */
|
||||
+ public int getExpDrop(IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ public int getExpDrop(IBlockState state, IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ return 0;
|
||||
+ }
|
||||
|
@ -1116,9 +1144,9 @@
|
|||
+ * @param side The INPUT side of the block to be powered - ie the opposite of this block's output side
|
||||
+ * @return Whether Block#isProvidingWeakPower should be called when determining indirect power
|
||||
+ */
|
||||
+ public boolean shouldCheckWeakPower(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ public boolean shouldCheckWeakPower(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ {
|
||||
+ return func_149721_r();
|
||||
+ return state.func_185915_l();
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
|
@ -1220,7 +1248,7 @@
|
|||
+ /**
|
||||
+ * Called when the entity is inside this block, may be used to determined if the entity can breathing,
|
||||
+ * display material overlays, or if the entity can swim inside a block.
|
||||
+ *
|
||||
+ *
|
||||
+ * @param world that is being tested.
|
||||
+ * @param blockpos position thats being tested.
|
||||
+ * @param iblockstate state at world/blockpos
|
||||
|
@ -1230,15 +1258,15 @@
|
|||
+ * @param testingHead when true, its testing the entities head for vision, breathing ect... otherwise its testing the body, for swimming and movement adjustment.
|
||||
+ * @return null for default behavior, true if the entity is within the material, false if it was not.
|
||||
+ */
|
||||
+ public Boolean isEntityInsideMaterial(World world, BlockPos blockpos, IBlockState iblockstate, Entity entity, double yToTest, Material materialIn, boolean testingHead)
|
||||
+ public Boolean isEntityInsideMaterial(IBlockAccess world, BlockPos blockpos, IBlockState iblockstate, Entity entity, double yToTest, Material materialIn, boolean testingHead)
|
||||
+ {
|
||||
+ return null;
|
||||
+ }
|
||||
+
|
||||
+
|
||||
+ /**
|
||||
+ * Called when boats or fishing hooks are inside the block to check if they are inside
|
||||
+ * the material requested.
|
||||
+ *
|
||||
+ *
|
||||
+ * @param world world that is being tested.
|
||||
+ * @param pos block thats being tested.
|
||||
+ * @param boundingBox box to test, generally the bounds of an entity that are besting tested.
|
||||
|
@ -1252,13 +1280,24 @@
|
|||
+
|
||||
+ /**
|
||||
+ * Queries if this block should render in a given layer.
|
||||
+ * ISmartBlockModel can use MinecraftForgeClient.getRenderLayer to alter their model based on layer
|
||||
+ * ISmartBlockModel can use {@link MinecraftForgeClient#getRenderLayer()} to alter their model based on layer.
|
||||
+ *
|
||||
+ * @deprecated New method with state sensitivity: {@link #canRenderInLayer(IBlockState, BlockRenderLayer)}
|
||||
+ */
|
||||
+ public boolean canRenderInLayer(EnumWorldBlockLayer layer)
|
||||
+ @Deprecated
|
||||
+ public boolean canRenderInLayer(BlockRenderLayer layer)
|
||||
+ {
|
||||
+ return func_180664_k() == layer;
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Queries if this block should render in a given layer.
|
||||
+ * ISmartBlockModel can use {@link MinecraftForgeClient#getRenderLayer()} to alter their model based on layer.
|
||||
+ */
|
||||
+ public boolean canRenderInLayer(IBlockState state, BlockRenderLayer layer)
|
||||
+ {
|
||||
+ return canRenderInLayer(layer);
|
||||
+ }
|
||||
+ // For Internal use only to capture droped items inside getDrops
|
||||
+ protected static ThreadLocal<Boolean> captureDrops = new ThreadLocal<Boolean>()
|
||||
+ {
|
||||
|
@ -1283,53 +1322,15 @@
|
|||
+ }
|
||||
+ }
|
||||
+
|
||||
+ private ResourceLocation registryName = null;
|
||||
+ /**
|
||||
+ * Sets a unique name for this Block. This should be used for uniquely identify the instance of the Block.
|
||||
+ * This is the valid replacement for the atrocious 'getUnlocalizedName().substring(6)' stuff that everyone does.
|
||||
+ * Unlocalized names have NOTHING to do with unique identifiers. As demonstrated by vanilla blocks and items.
|
||||
+ *
|
||||
+ * The supplied name will be prefixed with the currently active mod's modId.
|
||||
+ * If the supplied name already has a prefix that is different, it will be used and a warning will be logged.
|
||||
+ *
|
||||
+ * If a name already exists, or this Block is already registered in a registry, then an IllegalStateException is thrown.
|
||||
+ *
|
||||
+ * Returns 'this' to allow for chaining.
|
||||
+ *
|
||||
+ * @param name Unique registry name
|
||||
+ * @return This instance
|
||||
+ * Add information to the blocks tooltip, called from the default implementation of {@link ItemBlock#addInformation(ItemStack, EntityPlayer, List, boolean)}
|
||||
+ * @param stack The stack the tooltip is being retrieved for
|
||||
+ * @param player The player retrieving the tooltip
|
||||
+ * @param tooltip The lines to be displayed on the tooltip
|
||||
+ * @param advanced If the client has advanced debug tooltips enabled
|
||||
+ */
|
||||
+ public final Block setRegistryName(String name)
|
||||
+ public void addInformation(ItemStack stack, EntityPlayer player, List<String> tooltip, boolean advanced)
|
||||
+ {
|
||||
+ if (getRegistryName() != null)
|
||||
+ throw new IllegalStateException("Attempted to set registry name on block with exisiting registry name! New: " + name + " Old: " + getRegistryName());
|
||||
+ int index = name.lastIndexOf(':');
|
||||
+ String oldPrefix = index == -1 ? "" : name.substring(0, index);
|
||||
+ name = index == -1 ? name : name.substring(index + 1);
|
||||
+ net.minecraftforge.fml.common.ModContainer mc = net.minecraftforge.fml.common.Loader.instance().activeModContainer();
|
||||
+ String prefix = mc == null ? "minecraft" : mc.getModId();
|
||||
+ if (!oldPrefix.equals(prefix) && oldPrefix.length() > 0)
|
||||
+ {
|
||||
+ net.minecraftforge.fml.common.FMLLog.bigWarning("Dangerous alternative prefix %s for name %s, invalid registry invocation/invalid name?", oldPrefix, name);
|
||||
+ prefix = oldPrefix;
|
||||
+ }
|
||||
+ this.registryName = new ResourceLocation(prefix, name);
|
||||
+ return this;
|
||||
+ }
|
||||
+ public final Block setRegistryName(ResourceLocation name){ return setRegistryName(name.toString()); }
|
||||
+ public final Block setRegistryName(String modID, String name){ return setRegistryName(modID + ":" + name); }
|
||||
+
|
||||
+ /**
|
||||
+ * A unique identifier for this block, if this block is registered in the game registry it will return that name.
|
||||
+ * Otherwise it will return the name set in setRegistryName().
|
||||
+ * If neither are valid null is returned.
|
||||
+ *
|
||||
+ * @return Unique identifier or null.
|
||||
+ */
|
||||
+ public final String getRegistryName()
|
||||
+ {
|
||||
+ if (delegate.getResourceName() != null) return delegate.getResourceName().toString();
|
||||
+ return registryName != null ? registryName.toString() : null;
|
||||
+ }
|
||||
+ /* ========================================= FORGE END ======================================*/
|
||||
+
|
||||
|
|
|
@ -1,21 +1,13 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockBanner.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockBanner.java
|
||||
@@ -85,22 +85,7 @@
|
||||
@@ -104,14 +104,7 @@
|
||||
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
- TileEntity tileentity = p_180653_1_.func_175625_s(p_180653_2_);
|
||||
- ItemStack itemstack = this.func_185549_e(p_180653_1_, p_180653_2_, p_180653_3_);
|
||||
-
|
||||
- if (tileentity instanceof TileEntityBanner)
|
||||
- if (itemstack != null)
|
||||
{
|
||||
- ItemStack itemstack = new ItemStack(Items.field_179564_cE, 1, ((TileEntityBanner)tileentity).func_175115_b());
|
||||
- NBTTagCompound nbttagcompound = new NBTTagCompound();
|
||||
- tileentity.func_145841_b(nbttagcompound);
|
||||
- nbttagcompound.func_82580_o("x");
|
||||
- nbttagcompound.func_82580_o("y");
|
||||
- nbttagcompound.func_82580_o("z");
|
||||
- nbttagcompound.func_82580_o("id");
|
||||
- itemstack.func_77983_a("BlockEntityTag", nbttagcompound);
|
||||
- func_180635_a(p_180653_1_, p_180653_2_, itemstack);
|
||||
- }
|
||||
- else
|
||||
|
@ -23,7 +15,7 @@
|
|||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
}
|
||||
}
|
||||
@@ -133,6 +118,28 @@
|
||||
@@ -138,6 +131,28 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -51,4 +43,4 @@
|
|||
+
|
||||
public static class BlockBannerHanging extends BlockBanner
|
||||
{
|
||||
public BlockBannerHanging()
|
||||
protected static final AxisAlignedBB field_185551_d = new AxisAlignedBB(0.0D, 0.0D, 0.875D, 1.0D, 0.78125D, 1.0D);
|
||||
|
|
|
@ -1,40 +1,40 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockBush.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockBush.java
|
||||
@@ -13,7 +13,7 @@
|
||||
@@ -14,7 +14,7 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
-public class BlockBush extends Block
|
||||
+public class BlockBush extends Block implements net.minecraftforge.common.IPlantable
|
||||
{
|
||||
protected BlockBush()
|
||||
{
|
||||
@@ -36,7 +36,7 @@
|
||||
protected static final AxisAlignedBB field_185515_b = new AxisAlignedBB(0.30000001192092896D, 0.0D, 0.30000001192092896D, 0.699999988079071D, 0.6000000238418579D, 0.699999988079071D);
|
||||
|
||||
@@ -37,7 +37,8 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
- return super.func_176196_c(p_176196_1_, p_176196_2_) && this.func_149854_a(p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_177230_c());
|
||||
+ return super.func_176196_c(p_176196_1_, p_176196_2_) && p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_177230_c().canSustainPlant(p_176196_1_, p_176196_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this);
|
||||
- return super.func_176196_c(p_176196_1_, p_176196_2_) && this.func_185514_i(p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()));
|
||||
+ IBlockState soil = p_176196_1_.func_180495_p(p_176196_2_.func_177977_b());
|
||||
+ return super.func_176196_c(p_176196_1_, p_176196_2_) && soil.func_177230_c().canSustainPlant(soil, p_176196_1_, p_176196_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this);
|
||||
}
|
||||
|
||||
protected boolean func_149854_a(Block p_149854_1_)
|
||||
@@ -66,7 +66,10 @@
|
||||
protected boolean func_185514_i(IBlockState p_185514_1_)
|
||||
@@ -67,6 +68,11 @@
|
||||
|
||||
public boolean func_180671_f(World p_180671_1_, BlockPos p_180671_2_, IBlockState p_180671_3_)
|
||||
{
|
||||
- return this.func_149854_a(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c());
|
||||
+ BlockPos down = p_180671_2_.func_177977_b();
|
||||
+ Block soil = p_180671_1_.func_180495_p(down).func_177230_c();
|
||||
+ if (p_180671_3_.func_177230_c() != this) return this.func_149854_a(soil); //Forge: This function is called during world gen and placement, before this block is set, so if we are not 'here' then assume it's the pre-check.
|
||||
+ return soil.canSustainPlant(p_180671_1_, down, net.minecraft.util.EnumFacing.UP, this);
|
||||
+ if (p_180671_3_.func_177230_c() == this) //Forge: This function is called during world gen and placement, before this block is set, so if we are not 'here' then assume it's the pre-check.
|
||||
+ {
|
||||
+ IBlockState soil = p_180671_1_.func_180495_p(p_180671_2_.func_177977_b());
|
||||
+ return soil.func_177230_c().canSustainPlant(soil, p_180671_1_, p_180671_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this);
|
||||
+ }
|
||||
return this.func_185514_i(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()));
|
||||
}
|
||||
|
||||
public AxisAlignedBB func_180640_a(World p_180640_1_, BlockPos p_180640_2_, IBlockState p_180640_3_)
|
||||
@@ -89,4 +92,33 @@
|
||||
{
|
||||
return EnumWorldBlockLayer.CUTOUT;
|
||||
@@ -90,6 +96,35 @@
|
||||
return false;
|
||||
}
|
||||
+
|
||||
|
||||
+ @Override
|
||||
+ public net.minecraftforge.common.EnumPlantType getPlantType(net.minecraft.world.IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
|
@ -63,4 +63,7 @@
|
|||
+ if (state.func_177230_c() != this) return func_176223_P();
|
||||
+ return state;
|
||||
+ }
|
||||
}
|
||||
+
|
||||
@SideOnly(Side.CLIENT)
|
||||
public BlockRenderLayer func_180664_k()
|
||||
{
|
||||
|
|
|
@ -1,12 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockButton.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockButton.java
|
||||
@@ -74,8 +74,7 @@
|
||||
|
||||
@@ -89,7 +89,7 @@
|
||||
protected static boolean func_181088_a(World p_181088_0_, BlockPos p_181088_1_, EnumFacing p_181088_2_)
|
||||
{
|
||||
- BlockPos blockpos = p_181088_1_.func_177972_a(p_181088_2_);
|
||||
- return p_181088_2_ == EnumFacing.DOWN ? World.func_175683_a(p_181088_0_, blockpos) : p_181088_0_.func_180495_p(blockpos).func_177230_c().func_149721_r();
|
||||
+ return p_181088_2_ == EnumFacing.DOWN && World.func_175683_a(p_181088_0_, p_181088_1_.func_177977_b()) ? true : p_181088_0_.isSideSolid(p_181088_1_.func_177972_a(p_181088_2_), p_181088_2_.func_176734_d());
|
||||
BlockPos blockpos = p_181088_1_.func_177972_a(p_181088_2_);
|
||||
- return p_181088_2_ == EnumFacing.DOWN ? p_181088_0_.func_180495_p(blockpos).func_185896_q() : p_181088_0_.func_180495_p(blockpos).func_185915_l();
|
||||
+ return p_181088_0_.func_180495_p(blockpos).isSideSolid(p_181088_0_, blockpos, p_181088_2_.func_176734_d());
|
||||
}
|
||||
|
||||
public IBlockState func_180642_a(World p_180642_1_, BlockPos p_180642_2_, EnumFacing p_180642_3_, float p_180642_4_, float p_180642_5_, float p_180642_6_, int p_180642_7_, EntityLivingBase p_180642_8_)
|
||||
|
|
|
@ -8,21 +8,22 @@
|
|||
+public class BlockCactus extends Block implements net.minecraftforge.common.IPlantable
|
||||
{
|
||||
public static final PropertyInteger field_176587_a = PropertyInteger.func_177719_a("age", 0, 15);
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
protected static final AxisAlignedBB field_185593_b = new AxisAlignedBB(0.0625D, 0.0D, 0.0625D, 0.9375D, 0.9375D, 0.9375D);
|
||||
@@ -110,8 +110,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
Block block = p_176586_1_.func_180495_p(p_176586_2_.func_177977_b()).func_177230_c();
|
||||
- return block == Blocks.field_150434_aF || block == Blocks.field_150354_m;
|
||||
+ return block.canSustainPlant(p_176586_1_, p_176586_2_.func_177977_b(), EnumFacing.UP, this);
|
||||
- Block block = p_176586_1_.func_180495_p(p_176586_2_.func_177977_b()).func_177230_c();
|
||||
- return block == Blocks.field_150434_aF || block == Blocks.field_150354_m && !p_176586_1_.func_180495_p(p_176586_2_.func_177984_a()).func_185904_a().func_76224_d();
|
||||
+ IBlockState state = p_176586_1_.func_180495_p(p_176586_2_.func_177977_b());
|
||||
+ return state.func_177230_c().canSustainPlant(state, p_176586_1_, p_176586_2_, EnumFacing.UP, this) && !p_176586_1_.func_180495_p(p_176586_2_.func_177984_a()).func_185904_a().func_76224_d();
|
||||
}
|
||||
|
||||
public void func_180634_a(World p_180634_1_, BlockPos p_180634_2_, IBlockState p_180634_3_, Entity p_180634_4_)
|
||||
@@ -137,4 +137,16 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176587_a});
|
||||
@@ -135,6 +135,18 @@
|
||||
return ((Integer)p_176201_1_.func_177229_b(field_176587_a)).intValue();
|
||||
}
|
||||
+
|
||||
|
||||
+ @Override
|
||||
+ public net.minecraftforge.common.EnumPlantType getPlantType(net.minecraft.world.IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
|
@ -34,4 +35,7 @@
|
|||
+ {
|
||||
+ return func_176223_P();
|
||||
+ }
|
||||
}
|
||||
+
|
||||
protected BlockStateContainer func_180661_e()
|
||||
{
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176587_a});
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockChest.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockChest.java
|
||||
@@ -527,7 +527,7 @@
|
||||
@@ -506,7 +506,7 @@
|
||||
|
||||
private boolean func_176456_n(World p_176456_1_, BlockPos p_176456_2_)
|
||||
{
|
||||
- return p_176456_1_.func_180495_p(p_176456_2_.func_177984_a()).func_177230_c().func_149721_r();
|
||||
+ return p_176456_1_.isSideSolid(p_176456_2_.func_177984_a(), EnumFacing.DOWN, false);
|
||||
- return p_176456_1_.func_180495_p(p_176456_2_.func_177984_a()).func_185915_l();
|
||||
+ return p_176456_1_.func_180495_p(p_176456_2_.func_177984_a()).isSideSolid(p_176456_1_, p_176456_2_.func_177984_a(), EnumFacing.DOWN);
|
||||
}
|
||||
|
||||
private boolean func_176453_o(World p_176453_1_, BlockPos p_176453_2_)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockCocoa.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockCocoa.java
|
||||
@@ -137,7 +137,14 @@
|
||||
@@ -131,7 +131,14 @@
|
||||
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
|
@ -16,7 +16,7 @@
|
|||
int j = 1;
|
||||
|
||||
if (i >= 2)
|
||||
@@ -147,8 +154,9 @@
|
||||
@@ -141,8 +148,9 @@
|
||||
|
||||
for (int k = 0; k < j; ++k)
|
||||
{
|
||||
|
@ -26,4 +26,4 @@
|
|||
+ return dropped;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public ItemStack func_185473_a(World p_185473_1_, BlockPos p_185473_2_, IBlockState p_185473_3_)
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockCrops.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockCrops.java
|
||||
@@ -81,11 +81,11 @@
|
||||
@@ -116,11 +116,11 @@
|
||||
float f1 = 0.0F;
|
||||
IBlockState iblockstate = p_180672_1_.func_180495_p(blockpos.func_177982_a(i, 0, j));
|
||||
|
||||
- if (iblockstate.func_177230_c() == Blocks.field_150458_ak)
|
||||
+ if (iblockstate.func_177230_c().canSustainPlant(p_180672_1_, blockpos.func_177982_a(i, 0, j), net.minecraft.util.EnumFacing.UP, (net.minecraftforge.common.IPlantable)p_180672_0_))
|
||||
+ if (iblockstate.func_177230_c().canSustainPlant(iblockstate, p_180672_1_, blockpos.func_177982_a(i, 0, j), net.minecraft.util.EnumFacing.UP, (net.minecraftforge.common.IPlantable)p_180672_0_))
|
||||
{
|
||||
f1 = 1.0F;
|
||||
|
||||
|
@ -14,59 +14,34 @@
|
|||
{
|
||||
f1 = 3.0F;
|
||||
}
|
||||
@@ -126,7 +126,7 @@
|
||||
@@ -161,7 +161,8 @@
|
||||
|
||||
public boolean func_180671_f(World p_180671_1_, BlockPos p_180671_2_, IBlockState p_180671_3_)
|
||||
{
|
||||
- return (p_180671_1_.func_175699_k(p_180671_2_) >= 8 || p_180671_1_.func_175678_i(p_180671_2_)) && this.func_149854_a(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c());
|
||||
+ return (p_180671_1_.func_175699_k(p_180671_2_) >= 8 || p_180671_1_.func_175678_i(p_180671_2_)) && p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c().canSustainPlant(p_180671_1_, p_180671_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this);
|
||||
- return (p_180671_1_.func_175699_k(p_180671_2_) >= 8 || p_180671_1_.func_175678_i(p_180671_2_)) && this.func_185514_i(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()));
|
||||
+ IBlockState soil = p_180671_1_.func_180495_p(p_180671_2_.func_177977_b());
|
||||
+ return (p_180671_1_.func_175699_k(p_180671_2_) >= 8 || p_180671_1_.func_175678_i(p_180671_2_)) && soil.func_177230_c().canSustainPlant(soil, p_180671_1_, p_180671_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this);
|
||||
}
|
||||
|
||||
protected Item func_149866_i()
|
||||
@@ -142,24 +142,6 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, 0);
|
||||
-
|
||||
- if (!p_180653_1_.field_72995_K)
|
||||
- {
|
||||
- int i = ((Integer)p_180653_3_.func_177229_b(field_176488_a)).intValue();
|
||||
-
|
||||
- if (i >= 7)
|
||||
- {
|
||||
- int j = 3 + p_180653_5_;
|
||||
-
|
||||
- for (int k = 0; k < j; ++k)
|
||||
- {
|
||||
- if (p_180653_1_.field_73012_v.nextInt(15) <= i)
|
||||
- {
|
||||
- func_180635_a(p_180653_1_, p_180653_2_, new ItemStack(this.func_149866_i(), 1, 0));
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
@@ -174,11 +175,33 @@
|
||||
return Items.field_151015_O;
|
||||
}
|
||||
|
||||
public Item func_180660_a(IBlockState p_180660_1_, Random p_180660_2_, int p_180660_3_)
|
||||
@@ -202,4 +184,26 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176488_a});
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public java.util.List<ItemStack> getDrops(net.minecraft.world.IBlockAccess world, BlockPos pos, IBlockState state, int fortune)
|
||||
+ {
|
||||
+ java.util.List<ItemStack> ret = super.getDrops(world, pos, state, fortune);
|
||||
+ int age = ((Integer)state.func_177229_b(field_176488_a)).intValue();
|
||||
+ int age = func_185527_x(state);
|
||||
+ Random rand = world instanceof World ? ((World)world).field_73012_v : new Random();
|
||||
+
|
||||
+ if (age >= 7)
|
||||
+ if (age >= func_185526_g())
|
||||
+ {
|
||||
+ int k = 3 + fortune;
|
||||
+
|
||||
+ for (int i = 0; i < 3 + fortune; ++i)
|
||||
+ {
|
||||
+ if (rand.nextInt(15) <= age)
|
||||
+ if (rand.nextInt(2 * func_185526_g()) <= age)
|
||||
+ {
|
||||
+ ret.add(new ItemStack(this.func_149866_i(), 1, 0));
|
||||
+ }
|
||||
|
@ -74,4 +49,13 @@
|
|||
+ }
|
||||
+ return ret;
|
||||
+ }
|
||||
}
|
||||
+
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, 0);
|
||||
|
||||
- if (!p_180653_1_.field_72995_K)
|
||||
+ if (false && !p_180653_1_.field_72995_K) // Forge: NOP all this.
|
||||
{
|
||||
int i = this.func_185527_x(p_180653_3_);
|
||||
|
||||
|
|
|
@ -1,26 +1,25 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockDeadBush.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockDeadBush.java
|
||||
@@ -14,7 +14,7 @@
|
||||
import net.minecraft.util.BlockPos;
|
||||
@@ -16,7 +16,7 @@
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
-public class BlockDeadBush extends BlockBush
|
||||
+public class BlockDeadBush extends BlockBush implements net.minecraftforge.common.IShearable
|
||||
{
|
||||
protected BlockDeadBush()
|
||||
{
|
||||
@@ -45,14 +45,15 @@
|
||||
protected static final AxisAlignedBB field_185516_a = new AxisAlignedBB(0.09999999403953552D, 0.0D, 0.09999999403953552D, 0.8999999761581421D, 0.800000011920929D, 0.8999999761581421D);
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
@@ -57,7 +57,7 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_2_.func_71045_bC() != null && p_180657_2_.func_71045_bC().func_77973_b() == Items.field_151097_aZ)
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ)
|
||||
+ if (false && !p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ) // Forge: Noop
|
||||
{
|
||||
- p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150330_I, 1, 0));
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150330_I, 1, 0));
|
||||
@@ -67,4 +67,11 @@
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_, p_180657_6_);
|
||||
}
|
||||
}
|
||||
+
|
||||
|
@ -28,6 +27,6 @@
|
|||
+ @Override
|
||||
+ public java.util.List<ItemStack> onSheared(ItemStack item, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ return new java.util.ArrayList<ItemStack>(java.util.Arrays.asList(new ItemStack(Blocks.field_150330_I)));
|
||||
+ return java.util.Arrays.asList(new ItemStack(Blocks.field_150330_I));
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockDoor.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockDoor.java
|
||||
@@ -154,7 +154,7 @@
|
||||
@@ -107,7 +107,7 @@
|
||||
{
|
||||
if (this.field_149764_J == Material.field_151573_f)
|
||||
{
|
||||
|
@ -9,12 +9,12 @@
|
|||
}
|
||||
else
|
||||
{
|
||||
@@ -272,7 +272,7 @@
|
||||
@@ -219,7 +219,7 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
- return p_176196_2_.func_177956_o() >= 255 ? false : World.func_175683_a(p_176196_1_, p_176196_2_.func_177977_b()) && super.func_176196_c(p_176196_1_, p_176196_2_) && super.func_176196_c(p_176196_1_, p_176196_2_.func_177984_a());
|
||||
+ return p_176196_2_.func_177956_o() >= p_176196_1_.func_72800_K() - 1 ? false : World.func_175683_a(p_176196_1_, p_176196_2_.func_177977_b()) && super.func_176196_c(p_176196_1_, p_176196_2_) && super.func_176196_c(p_176196_1_, p_176196_2_.func_177984_a());
|
||||
- return p_176196_2_.func_177956_o() >= 255 ? false : p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_185896_q() && super.func_176196_c(p_176196_1_, p_176196_2_) && super.func_176196_c(p_176196_1_, p_176196_2_.func_177984_a());
|
||||
+ return p_176196_2_.func_177956_o() >= p_176196_1_.func_72800_K() - 1 ? false : p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).isSideSolid(p_176196_1_, p_176196_2_.func_177977_b(), EnumFacing.UP) && super.func_176196_c(p_176196_1_, p_176196_2_) && super.func_176196_c(p_176196_1_, p_176196_2_.func_177984_a());
|
||||
}
|
||||
|
||||
public int func_149656_h()
|
||||
public EnumPushReaction func_149656_h(IBlockState p_149656_1_)
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
{
|
||||
public static final PropertyEnum<BlockDoublePlant.EnumPlantType> field_176493_a = PropertyEnum.<BlockDoublePlant.EnumPlantType>func_177709_a("variant", BlockDoublePlant.EnumPlantType.class);
|
||||
public static final PropertyEnum<BlockDoublePlant.EnumBlockHalf> field_176492_b = PropertyEnum.<BlockDoublePlant.EnumBlockHalf>func_177709_a("half", BlockDoublePlant.EnumBlockHalf.class);
|
||||
@@ -90,6 +90,8 @@
|
||||
@@ -88,6 +88,8 @@
|
||||
Block block = (Block)(flag ? this : p_176475_1_.func_180495_p(blockpos).func_177230_c());
|
||||
Block block1 = (Block)(flag ? p_176475_1_.func_180495_p(blockpos1).func_177230_c() : this);
|
||||
|
||||
|
@ -18,7 +18,7 @@
|
|||
if (block == this)
|
||||
{
|
||||
p_176475_1_.func_180501_a(blockpos, Blocks.field_150350_a.func_176223_P(), 2);
|
||||
@@ -98,17 +100,13 @@
|
||||
@@ -96,17 +98,13 @@
|
||||
if (block1 == this)
|
||||
{
|
||||
p_176475_1_.func_180501_a(blockpos1, Blocks.field_150350_a.func_176223_P(), 3);
|
||||
|
@ -37,24 +37,24 @@
|
|||
if (p_180671_3_.func_177229_b(field_176492_b) == BlockDoublePlant.EnumBlockHalf.UPPER)
|
||||
{
|
||||
return p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c() == this;
|
||||
@@ -158,7 +156,6 @@
|
||||
@@ -149,7 +147,6 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- if (p_180657_1_.field_72995_K || p_180657_2_.func_71045_bC() == null || p_180657_2_.func_71045_bC().func_77973_b() != Items.field_151097_aZ || p_180657_4_.func_177229_b(field_176492_b) != BlockDoublePlant.EnumBlockHalf.LOWER || !this.func_176489_b(p_180657_1_, p_180657_3_, p_180657_4_, p_180657_2_))
|
||||
- if (p_180657_1_.field_72995_K || p_180657_6_ == null || p_180657_6_.func_77973_b() != Items.field_151097_aZ || p_180657_4_.func_177229_b(field_176492_b) != BlockDoublePlant.EnumBlockHalf.LOWER || !this.func_176489_b(p_180657_1_, p_180657_3_, p_180657_4_, p_180657_2_))
|
||||
{
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_, p_180657_6_);
|
||||
}
|
||||
@@ -221,8 +218,6 @@
|
||||
@@ -212,8 +209,6 @@
|
||||
else
|
||||
{
|
||||
p_176489_4_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
p_176489_4_.func_71029_a(StatList.func_188055_a(this));
|
||||
- int i = (blockdoubleplant$enumplanttype == BlockDoublePlant.EnumPlantType.GRASS ? BlockTallGrass.EnumType.GRASS : BlockTallGrass.EnumType.FERN).func_177044_a();
|
||||
- func_180635_a(p_176489_1_, p_176489_2_, new ItemStack(Blocks.field_150329_H, 2, i));
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -293,6 +288,32 @@
|
||||
@@ -284,6 +279,33 @@
|
||||
return Block.EnumOffsetType.XZ;
|
||||
}
|
||||
|
||||
|
@ -65,6 +65,7 @@
|
|||
+ EnumPlantType type = (EnumPlantType)state.func_177229_b(field_176493_a);
|
||||
+ return state.func_177229_b(field_176492_b) == EnumBlockHalf.LOWER && (type == EnumPlantType.FERN || type == EnumPlantType.GRASS);
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public java.util.List<ItemStack> onSheared(ItemStack item, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
|
@ -74,11 +75,11 @@
|
|||
+ if (type == EnumPlantType.GRASS) ret.add(new ItemStack(Blocks.field_150329_H, 2, BlockTallGrass.EnumType.GRASS.func_177044_a()));
|
||||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public boolean removedByPlayer(World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ public boolean removedByPlayer(IBlockState state, World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ {
|
||||
+ //Forge: Break both parts on the client to prevent the top part flickering as default type for a few frames.
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ if (state.func_177230_c() == this && state.func_177229_b(field_176492_b) == EnumBlockHalf.LOWER && world.func_180495_p(pos.func_177984_a()).func_177230_c() == this)
|
||||
+ world.func_175698_g(pos.func_177984_a());
|
||||
+ return world.func_175698_g(pos);
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockDragonEgg.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockDragonEgg.java
|
||||
@@ -48,7 +48,7 @@
|
||||
|
||||
private void func_180683_d(World p_180683_1_, BlockPos p_180683_2_)
|
||||
{
|
||||
- if (BlockFalling.func_185759_i(p_180683_1_.func_180495_p(p_180683_2_.func_177977_b())) && p_180683_2_.func_177956_o() >= 0)
|
||||
+ if (p_180683_1_.func_175623_d(p_180683_2_.func_177977_b()) && BlockFalling.func_185759_i(p_180683_1_.func_180495_p(p_180683_2_.func_177977_b())) && p_180683_2_.func_177956_o() >= 0)
|
||||
{
|
||||
int i = 32;
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
p_180683_1_.func_175698_g(p_180683_2_);
|
||||
BlockPos blockpos;
|
||||
|
||||
- for (blockpos = p_180683_2_; BlockFalling.func_185759_i(p_180683_1_.func_180495_p(blockpos)) && blockpos.func_177956_o() > 0; blockpos = blockpos.func_177977_b())
|
||||
+ for (blockpos = p_180683_2_; p_180683_1_.func_175623_d(blockpos) && BlockFalling.func_185759_i(p_180683_1_.func_180495_p(blockpos)) && blockpos.func_177956_o() > 0; blockpos = blockpos.func_177977_b())
|
||||
{
|
||||
;
|
||||
}
|
|
@ -1,10 +1,20 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockFalling.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockFalling.java
|
||||
@@ -86,6 +86,7 @@
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
public static boolean func_180685_d(World p_180685_0_, BlockPos p_180685_1_)
|
||||
private void func_176503_e(World p_176503_1_, BlockPos p_176503_2_)
|
||||
{
|
||||
+ if (p_180685_0_.func_175623_d(p_180685_1_)) return true;
|
||||
Block block = p_180685_0_.func_180495_p(p_180685_1_).func_177230_c();
|
||||
Material material = block.field_149764_J;
|
||||
return block == Blocks.field_150480_ab || material == Material.field_151579_a || material == Material.field_151586_h || material == Material.field_151587_i;
|
||||
- if (func_185759_i(p_176503_1_.func_180495_p(p_176503_2_.func_177977_b())) && p_176503_2_.func_177956_o() >= 0)
|
||||
+ if ((p_176503_1_.func_175623_d(p_176503_2_.func_177977_b()) || func_185759_i(p_176503_1_.func_180495_p(p_176503_2_.func_177977_b()))) && p_176503_2_.func_177956_o() >= 0)
|
||||
{
|
||||
int i = 32;
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
p_176503_1_.func_175698_g(p_176503_2_);
|
||||
BlockPos blockpos;
|
||||
|
||||
- for (blockpos = p_176503_2_.func_177977_b(); func_185759_i(p_176503_1_.func_180495_p(blockpos)) && blockpos.func_177956_o() > 0; blockpos = blockpos.func_177977_b())
|
||||
+ for (blockpos = p_176503_2_.func_177977_b(); (p_176503_1_.func_175623_d(blockpos) || func_185759_i(p_176503_1_.func_180495_p(blockpos))) && blockpos.func_177956_o() > 0; blockpos = blockpos.func_177977_b())
|
||||
{
|
||||
;
|
||||
}
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockFarmland.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockFarmland.java
|
||||
@@ -89,7 +89,7 @@
|
||||
@@ -87,7 +87,7 @@
|
||||
private boolean func_176529_d(World p_176529_1_, BlockPos p_176529_2_)
|
||||
{
|
||||
Block block = p_176529_1_.func_180495_p(p_176529_2_.func_177984_a()).func_177230_c();
|
||||
- return block instanceof BlockCrops || block instanceof BlockStem;
|
||||
+ return block instanceof net.minecraftforge.common.IPlantable && canSustainPlant(p_176529_1_, p_176529_2_, net.minecraft.util.EnumFacing.UP, (net.minecraftforge.common.IPlantable)block);
|
||||
+ return block instanceof net.minecraftforge.common.IPlantable && canSustainPlant(p_176529_1_.func_180495_p(p_176529_2_), p_176529_1_, p_176529_2_, net.minecraft.util.EnumFacing.UP, (net.minecraftforge.common.IPlantable)block);
|
||||
}
|
||||
|
||||
private boolean func_176530_e(World p_176530_1_, BlockPos p_176530_2_)
|
||||
|
|
|
@ -1,34 +1,23 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockFire.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockFire.java
|
||||
@@ -41,18 +41,24 @@
|
||||
int j = p_176221_3_.func_177956_o();
|
||||
int k = p_176221_3_.func_177952_p();
|
||||
@@ -37,7 +37,15 @@
|
||||
|
||||
- if (!World.func_175683_a(p_176221_2_, p_176221_3_.func_177977_b()) && !Blocks.field_150480_ab.func_176535_e(p_176221_2_, p_176221_3_.func_177977_b()))
|
||||
+ if (!World.func_175683_a(p_176221_2_, p_176221_3_.func_177977_b()) && !Blocks.field_150480_ab.canCatchFire(p_176221_2_, p_176221_3_.func_177977_b(), EnumFacing.UP))
|
||||
{
|
||||
boolean flag = (i + j + k & 1) == 1;
|
||||
boolean flag1 = (i / 2 + j / 2 + k / 2 & 1) == 1;
|
||||
int l = 0;
|
||||
public IBlockState func_176221_a(IBlockState p_176221_1_, IBlockAccess p_176221_2_, BlockPos p_176221_3_)
|
||||
{
|
||||
- return !p_176221_2_.func_180495_p(p_176221_3_.func_177977_b()).func_185896_q() && !Blocks.field_150480_ab.func_176535_e(p_176221_2_, p_176221_3_.func_177977_b()) ? p_176221_1_.func_177226_a(field_176545_N, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177978_c()))).func_177226_a(field_176546_O, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177974_f()))).func_177226_a(field_176541_P, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177968_d()))).func_177226_a(field_176539_Q, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177976_e()))).func_177226_a(field_176542_R, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177984_a()))) : this.func_176223_P();
|
||||
+ if (!p_176221_2_.func_180495_p(p_176221_3_.func_177977_b()).isSideSolid(p_176221_2_, p_176221_3_.func_177977_b(), EnumFacing.UP) && !Blocks.field_150480_ab.canCatchFire(p_176221_2_, p_176221_3_.func_177977_b(), EnumFacing.UP))
|
||||
+ {
|
||||
+ return p_176221_1_.func_177226_a(field_176545_N, this.canCatchFire(p_176221_2_, p_176221_3_.func_177978_c(), EnumFacing.SOUTH))
|
||||
+ .func_177226_a(field_176546_O, this.canCatchFire(p_176221_2_, p_176221_3_.func_177974_f(), EnumFacing.WEST))
|
||||
+ .func_177226_a(field_176541_P, this.canCatchFire(p_176221_2_, p_176221_3_.func_177968_d(), EnumFacing.NORTH))
|
||||
+ .func_177226_a(field_176539_Q, this.canCatchFire(p_176221_2_, p_176221_3_.func_177976_e(), EnumFacing.EAST))
|
||||
+ .func_177226_a(field_176542_R, this.canCatchFire(p_176221_2_, p_176221_3_.func_177984_a(), EnumFacing.DOWN));
|
||||
+ }
|
||||
+ return this.func_176223_P();
|
||||
}
|
||||
|
||||
- if (this.func_176535_e(p_176221_2_, p_176221_3_.func_177984_a()))
|
||||
+ if (this.canCatchFire(p_176221_2_, p_176221_3_.func_177984_a(), EnumFacing.DOWN))
|
||||
{
|
||||
l = flag ? 1 : 2;
|
||||
}
|
||||
|
||||
- return p_176221_1_.func_177226_a(field_176545_N, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177978_c()))).func_177226_a(field_176546_O, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177974_f()))).func_177226_a(field_176541_P, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177968_d()))).func_177226_a(field_176539_Q, Boolean.valueOf(this.func_176535_e(p_176221_2_, p_176221_3_.func_177976_e()))).func_177226_a(field_176542_R, Integer.valueOf(l)).func_177226_a(field_176540_b, Boolean.valueOf(flag1)).func_177226_a(field_176544_M, Boolean.valueOf(flag));
|
||||
+ return p_176221_1_.func_177226_a(field_176545_N, Boolean.valueOf(this.canCatchFire(p_176221_2_, p_176221_3_.func_177978_c(), EnumFacing.SOUTH)))
|
||||
+ .func_177226_a(field_176546_O, Boolean.valueOf(this.canCatchFire(p_176221_2_, p_176221_3_.func_177974_f(), EnumFacing.EAST )))
|
||||
+ .func_177226_a(field_176541_P, Boolean.valueOf(this.canCatchFire(p_176221_2_, p_176221_3_.func_177968_d(), EnumFacing.NORTH)))
|
||||
+ .func_177226_a(field_176539_Q, Boolean.valueOf(this.canCatchFire(p_176221_2_, p_176221_3_.func_177976_e(), EnumFacing.EAST )))
|
||||
+ .func_177226_a(field_176542_R, Integer.valueOf(l))
|
||||
+ .func_177226_a(field_176540_b, Boolean.valueOf(flag1))
|
||||
+ .func_177226_a(field_176544_M, Boolean.valueOf(flag));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -108,6 +114,7 @@
|
||||
protected BlockFire()
|
||||
@@ -90,6 +98,7 @@
|
||||
|
||||
public void func_180686_a(Block p_180686_1_, int p_180686_2_, int p_180686_3_)
|
||||
{
|
||||
|
@ -36,7 +25,7 @@
|
|||
this.field_149849_a.put(p_180686_1_, Integer.valueOf(p_180686_2_));
|
||||
this.field_149848_b.put(p_180686_1_, Integer.valueOf(p_180686_3_));
|
||||
}
|
||||
@@ -147,13 +154,8 @@
|
||||
@@ -129,13 +138,8 @@
|
||||
}
|
||||
|
||||
Block block = p_180650_1_.func_180495_p(p_180650_2_.func_177977_b()).func_177230_c();
|
||||
|
@ -48,10 +37,19 @@
|
|||
- flag = true;
|
||||
- }
|
||||
-
|
||||
if (!flag && p_180650_1_.func_72896_J() && this.func_176537_d(p_180650_1_, p_180650_2_))
|
||||
{
|
||||
p_180650_1_.func_175698_g(p_180650_2_);
|
||||
@@ -182,7 +184,7 @@
|
||||
int i = ((Integer)p_180650_3_.func_177229_b(field_176543_a)).intValue();
|
||||
|
||||
if (!flag && p_180650_1_.func_72896_J() && this.func_176537_d(p_180650_1_, p_180650_2_) && p_180650_4_.nextFloat() < 0.2F + (float)i * 0.03F)
|
||||
@@ -156,7 +160,7 @@
|
||||
{
|
||||
if (!this.func_176533_e(p_180650_1_, p_180650_2_))
|
||||
{
|
||||
- if (!p_180650_1_.func_180495_p(p_180650_2_.func_177977_b()).func_185896_q() || i > 3)
|
||||
+ if (!p_180650_1_.func_180495_p(p_180650_2_.func_177977_b()).isSideSolid(p_180650_1_, p_180650_2_.func_177977_b(), EnumFacing.UP) || i > 3)
|
||||
{
|
||||
p_180650_1_.func_175698_g(p_180650_2_);
|
||||
}
|
||||
@@ -164,7 +168,7 @@
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -60,7 +58,7 @@
|
|||
{
|
||||
p_180650_1_.func_175698_g(p_180650_2_);
|
||||
return;
|
||||
@@ -197,12 +199,12 @@
|
||||
@@ -179,12 +183,12 @@
|
||||
j = -50;
|
||||
}
|
||||
|
||||
|
@ -79,7 +77,7 @@
|
|||
|
||||
for (int k = -1; k <= 1; ++k)
|
||||
{
|
||||
@@ -261,22 +263,30 @@
|
||||
@@ -243,45 +247,53 @@
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -104,14 +102,44 @@
|
|||
+ this.tryCatchFire(p_176536_1_, p_176536_2_, p_176536_3_, p_176536_4_, p_176536_5_, EnumFacing.UP);
|
||||
+ }
|
||||
|
||||
+ private void tryCatchFire(World p_176536_1_, BlockPos p_176536_2_, int p_176536_3_, Random p_176536_4_, int p_176536_5_, EnumFacing face)
|
||||
- if (p_176536_4_.nextInt(p_176536_3_) < i)
|
||||
+ private void tryCatchFire(World worldIn, BlockPos pos, int chance, Random random, int age, EnumFacing face)
|
||||
+ {
|
||||
+ int i = p_176536_1_.func_180495_p(p_176536_2_).func_177230_c().getFlammability(p_176536_1_, p_176536_2_, face);
|
||||
+ int i = worldIn.func_180495_p(pos).func_177230_c().getFlammability(worldIn, pos, face);
|
||||
+
|
||||
if (p_176536_4_.nextInt(p_176536_3_) < i)
|
||||
+ if (random.nextInt(chance) < i)
|
||||
{
|
||||
IBlockState iblockstate = p_176536_1_.func_180495_p(p_176536_2_);
|
||||
@@ -308,7 +318,7 @@
|
||||
- IBlockState iblockstate = p_176536_1_.func_180495_p(p_176536_2_);
|
||||
+ IBlockState iblockstate = worldIn.func_180495_p(pos);
|
||||
|
||||
- if (p_176536_4_.nextInt(p_176536_5_ + 10) < 5 && !p_176536_1_.func_175727_C(p_176536_2_))
|
||||
+ if (random.nextInt(age + 10) < 5 && !worldIn.func_175727_C(pos))
|
||||
{
|
||||
- int j = p_176536_5_ + p_176536_4_.nextInt(5) / 4;
|
||||
+ int j = age + random.nextInt(5) / 4;
|
||||
|
||||
if (j > 15)
|
||||
{
|
||||
j = 15;
|
||||
}
|
||||
|
||||
- p_176536_1_.func_180501_a(p_176536_2_, this.func_176223_P().func_177226_a(field_176543_a, Integer.valueOf(j)), 3);
|
||||
+ worldIn.func_180501_a(pos, this.func_176223_P().func_177226_a(field_176543_a, Integer.valueOf(j)), 3);
|
||||
}
|
||||
else
|
||||
{
|
||||
- p_176536_1_.func_175698_g(p_176536_2_);
|
||||
+ worldIn.func_175698_g(pos);
|
||||
}
|
||||
|
||||
if (iblockstate.func_177230_c() == Blocks.field_150335_W)
|
||||
{
|
||||
- Blocks.field_150335_W.func_176206_d(p_176536_1_, p_176536_2_, iblockstate.func_177226_a(BlockTNT.field_176246_a, Boolean.valueOf(true)));
|
||||
+ Blocks.field_150335_W.func_176206_d(worldIn, pos, iblockstate.func_177226_a(BlockTNT.field_176246_a, Boolean.valueOf(true)));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -290,7 +302,7 @@
|
||||
{
|
||||
for (EnumFacing enumfacing : EnumFacing.values())
|
||||
{
|
||||
|
@ -120,7 +148,7 @@
|
|||
{
|
||||
return true;
|
||||
}
|
||||
@@ -329,7 +339,7 @@
|
||||
@@ -311,7 +323,7 @@
|
||||
|
||||
for (EnumFacing enumfacing : EnumFacing.values())
|
||||
{
|
||||
|
@ -129,7 +157,7 @@
|
|||
}
|
||||
|
||||
return i;
|
||||
@@ -341,9 +351,10 @@
|
||||
@@ -323,9 +335,10 @@
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -141,57 +169,57 @@
|
|||
}
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
@@ -382,9 +393,9 @@
|
||||
p_180655_1_.func_72980_b((double)((float)p_180655_2_.func_177958_n() + 0.5F), (double)((float)p_180655_2_.func_177956_o() + 0.5F), (double)((float)p_180655_2_.func_177952_p() + 0.5F), "fire.fire", 1.0F + p_180655_4_.nextFloat(), p_180655_4_.nextFloat() * 0.7F + 0.3F, false);
|
||||
@@ -364,9 +377,9 @@
|
||||
p_180655_2_.func_184134_a((double)((float)p_180655_3_.func_177958_n() + 0.5F), (double)((float)p_180655_3_.func_177956_o() + 0.5F), (double)((float)p_180655_3_.func_177952_p() + 0.5F), SoundEvents.field_187643_bs, SoundCategory.BLOCKS, 1.0F + p_180655_4_.nextFloat(), p_180655_4_.nextFloat() * 0.7F + 0.3F, false);
|
||||
}
|
||||
|
||||
- if (!World.func_175683_a(p_180655_1_, p_180655_2_.func_177977_b()) && !Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177977_b()))
|
||||
+ if (!World.func_175683_a(p_180655_1_, p_180655_2_.func_177977_b()) && !Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177977_b(), EnumFacing.UP))
|
||||
- if (!p_180655_2_.func_180495_p(p_180655_3_.func_177977_b()).func_185896_q() && !Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177977_b()))
|
||||
+ if (!p_180655_2_.func_180495_p(p_180655_3_.func_177977_b()).isSideSolid(p_180655_2_, p_180655_3_.func_177977_b(), EnumFacing.UP) && !Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177977_b(), EnumFacing.UP))
|
||||
{
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177976_e()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177976_e(), EnumFacing.EAST))
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177976_e()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177976_e(), EnumFacing.EAST))
|
||||
{
|
||||
for (int j = 0; j < 2; ++j)
|
||||
{
|
||||
@@ -395,7 +406,7 @@
|
||||
@@ -377,7 +390,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177974_f()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177974_f(), EnumFacing.WEST))
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177974_f()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177974_f(), EnumFacing.WEST))
|
||||
{
|
||||
for (int k = 0; k < 2; ++k)
|
||||
{
|
||||
@@ -406,7 +417,7 @@
|
||||
@@ -388,7 +401,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177978_c()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177978_c(), EnumFacing.SOUTH))
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177978_c()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177978_c(), EnumFacing.SOUTH))
|
||||
{
|
||||
for (int l = 0; l < 2; ++l)
|
||||
{
|
||||
@@ -417,7 +428,7 @@
|
||||
@@ -399,7 +412,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177968_d()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177968_d(), EnumFacing.NORTH))
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177968_d()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177968_d(), EnumFacing.NORTH))
|
||||
{
|
||||
for (int i1 = 0; i1 < 2; ++i1)
|
||||
{
|
||||
@@ -428,7 +439,7 @@
|
||||
@@ -410,7 +423,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_1_, p_180655_2_.func_177984_a()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_1_, p_180655_2_.func_177984_a(), EnumFacing.DOWN))
|
||||
- if (Blocks.field_150480_ab.func_176535_e(p_180655_2_, p_180655_3_.func_177984_a()))
|
||||
+ if (Blocks.field_150480_ab.canCatchFire(p_180655_2_, p_180655_3_.func_177984_a(), EnumFacing.DOWN))
|
||||
{
|
||||
for (int j1 = 0; j1 < 2; ++j1)
|
||||
{
|
||||
@@ -476,4 +487,19 @@
|
||||
@@ -458,4 +471,19 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176543_a, field_176545_N, field_176546_O, field_176541_P, field_176539_Q, field_176542_R, field_176540_b, field_176544_M});
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176543_a, field_176545_N, field_176546_O, field_176541_P, field_176539_Q, field_176542_R});
|
||||
}
|
||||
+
|
||||
+ /*================================= Forge Start ======================================*/
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockFlowerPot.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockFlowerPot.java
|
||||
@@ -169,13 +169,6 @@
|
||||
@@ -148,13 +148,6 @@
|
||||
|
||||
public void func_180663_b(World p_180663_1_, BlockPos p_180663_2_, IBlockState p_180663_3_)
|
||||
{
|
||||
|
@ -14,8 +14,8 @@
|
|||
super.func_180663_b(p_180663_1_, p_180663_2_, p_180663_3_);
|
||||
}
|
||||
|
||||
@@ -395,6 +388,31 @@
|
||||
return EnumWorldBlockLayer.CUTOUT;
|
||||
@@ -374,6 +367,31 @@
|
||||
return BlockRenderLayer.CUTOUT;
|
||||
}
|
||||
|
||||
+
|
||||
|
@ -30,15 +30,15 @@
|
|||
+ return ret;
|
||||
+ }
|
||||
+ @Override
|
||||
+ public boolean removedByPlayer(World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ public boolean removedByPlayer(IBlockState state, World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
+ {
|
||||
+ if (willHarvest) return true; //If it will harvest, delay deletion of the block until after getDrops
|
||||
+ return super.removedByPlayer(world, pos, player, willHarvest);
|
||||
+ return super.removedByPlayer(state, world, pos, player, willHarvest);
|
||||
+ }
|
||||
+ @Override
|
||||
+ public void func_180657_a(World world, EntityPlayer player, BlockPos pos, IBlockState state, TileEntity te)
|
||||
+ public void func_180657_a(World world, EntityPlayer player, BlockPos pos, IBlockState state, TileEntity te, ItemStack tool)
|
||||
+ {
|
||||
+ super.func_180657_a(world, player, pos, state, te);
|
||||
+ super.func_180657_a(world, player, pos, state, te, tool);
|
||||
+ world.func_175698_g(pos);
|
||||
+ }
|
||||
+ /*===========================FORGE END==========================================*/
|
||||
|
|
|
@ -1,24 +1,24 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockGrass.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockGrass.java
|
||||
@@ -58,7 +58,7 @@
|
||||
@@ -38,7 +38,7 @@
|
||||
{
|
||||
if (!p_180650_1_.field_72995_K)
|
||||
{
|
||||
- if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_177230_c().func_149717_k() > 2)
|
||||
+ if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_177230_c().getLightOpacity(p_180650_1_, p_180650_2_.func_177984_a()) > 2)
|
||||
- if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_185891_c() > 2)
|
||||
+ if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).getLightOpacity(p_180650_1_, p_180650_2_.func_177984_a()) > 2)
|
||||
{
|
||||
p_180650_1_.func_175656_a(p_180650_2_, Blocks.field_150346_d.func_176223_P());
|
||||
}
|
||||
@@ -72,7 +72,7 @@
|
||||
Block block = p_180650_1_.func_180495_p(blockpos.func_177984_a()).func_177230_c();
|
||||
IBlockState iblockstate = p_180650_1_.func_180495_p(blockpos);
|
||||
@@ -58,7 +58,7 @@
|
||||
IBlockState iblockstate = p_180650_1_.func_180495_p(blockpos.func_177984_a());
|
||||
IBlockState iblockstate1 = p_180650_1_.func_180495_p(blockpos);
|
||||
|
||||
- if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && block.func_149717_k() <= 2)
|
||||
+ if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && block.getLightOpacity(p_180650_1_, blockpos.func_177984_a()) <= 2)
|
||||
- if (iblockstate1.func_177230_c() == Blocks.field_150346_d && iblockstate1.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && iblockstate.func_185891_c() <= 2)
|
||||
+ if (iblockstate1.func_177230_c() == Blocks.field_150346_d && iblockstate1.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && iblockstate.getLightOpacity(p_180650_1_, p_180650_2_.func_177984_a()) <= 2)
|
||||
{
|
||||
p_180650_1_.func_175656_a(blockpos, Blocks.field_150349_c.func_176223_P());
|
||||
}
|
||||
@@ -110,7 +110,7 @@
|
||||
@@ -96,7 +96,7 @@
|
||||
{
|
||||
if (j >= i / 16)
|
||||
{
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockHugeMushroom.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockHugeMushroom.java
|
||||
@@ -79,6 +79,20 @@
|
||||
return new BlockState(this, new IProperty[] {field_176380_a});
|
||||
@@ -221,6 +221,20 @@
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176380_a});
|
||||
}
|
||||
|
||||
+ public boolean rotateBlock(World world, BlockPos pos, EnumFacing axis)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty prop : (java.util.Set<IProperty<?>>)state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("variant"))
|
||||
+ {
|
||||
|
|
|
@ -1,35 +1,34 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockIce.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockIce.java
|
||||
@@ -38,14 +38,17 @@
|
||||
p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
@@ -40,14 +40,19 @@
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
p_180657_2_.func_71020_j(0.025F);
|
||||
|
||||
- if (this.func_149700_E() && EnchantmentHelper.func_77502_d(p_180657_2_))
|
||||
+ if (this.canSilkHarvest(p_180657_1_, p_180657_3_, p_180657_1_.func_180495_p(p_180657_3_), p_180657_2_) && EnchantmentHelper.func_77502_d(p_180657_2_))
|
||||
- if (this.func_149700_E() && EnchantmentHelper.func_77506_a(Enchantments.field_185306_r, p_180657_6_) > 0)
|
||||
+ if (this.canSilkHarvest(p_180657_1_, p_180657_3_, p_180657_4_, p_180657_2_) && EnchantmentHelper.func_77506_a(Enchantments.field_185306_r, p_180657_6_) > 0)
|
||||
{
|
||||
+ java.util.List<ItemStack> items = new java.util.ArrayList<ItemStack>();
|
||||
ItemStack itemstack = this.func_180643_i(p_180657_4_);
|
||||
|
||||
- if (itemstack != null)
|
||||
- {
|
||||
if (itemstack != null)
|
||||
{
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, itemstack);
|
||||
- }
|
||||
+ if (itemstack != null) items.add(itemstack);
|
||||
+
|
||||
+ net.minecraftforge.event.ForgeEventFactory.fireBlockHarvesting(items, p_180657_1_, p_180657_3_, p_180657_1_.func_180495_p(p_180657_3_), 0, 1.0f, true, p_180657_2_);
|
||||
+ items.add(itemstack);
|
||||
}
|
||||
+
|
||||
+ net.minecraftforge.event.ForgeEventFactory.fireBlockHarvesting(items, p_180657_1_, p_180657_3_, p_180657_4_, 0, 1.0f, true, p_180657_2_);
|
||||
+ for (ItemStack is : items)
|
||||
+ func_180635_a(p_180657_1_, p_180657_3_, is);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -56,7 +59,9 @@
|
||||
@@ -58,7 +63,9 @@
|
||||
}
|
||||
|
||||
int i = EnchantmentHelper.func_77517_e(p_180657_2_);
|
||||
int i = EnchantmentHelper.func_77506_a(Enchantments.field_185308_t, p_180657_6_);
|
||||
+ harvesters.set(p_180657_2_);
|
||||
this.func_176226_b(p_180657_1_, p_180657_3_, p_180657_4_, i);
|
||||
+ harvesters.set(null);
|
||||
Material material = p_180657_1_.func_180495_p(p_180657_3_.func_177977_b()).func_177230_c().func_149688_o();
|
||||
Material material = p_180657_1_.func_180495_p(p_180657_3_.func_177977_b()).func_185904_a();
|
||||
|
||||
if (material.func_76230_c() || material.func_76224_d())
|
||||
|
|
|
@ -1,30 +1,30 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockLadder.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockLadder.java
|
||||
@@ -78,7 +78,10 @@
|
||||
@@ -61,7 +61,10 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
- return p_176196_1_.func_180495_p(p_176196_2_.func_177976_e()).func_177230_c().func_149721_r() ? true : (p_176196_1_.func_180495_p(p_176196_2_.func_177974_f()).func_177230_c().func_149721_r() ? true : (p_176196_1_.func_180495_p(p_176196_2_.func_177978_c()).func_177230_c().func_149721_r() ? true : p_176196_1_.func_180495_p(p_176196_2_.func_177968_d()).func_177230_c().func_149721_r()));
|
||||
+ return p_176196_1_.isSideSolid(p_176196_2_.func_177976_e(), EnumFacing.EAST, true) ||
|
||||
+ p_176196_1_.isSideSolid(p_176196_2_.func_177974_f(), EnumFacing.WEST, true) ||
|
||||
+ p_176196_1_.isSideSolid(p_176196_2_.func_177978_c(), EnumFacing.SOUTH, true) ||
|
||||
+ p_176196_1_.isSideSolid(p_176196_2_.func_177968_d(), EnumFacing.NORTH, true);
|
||||
- return p_176196_1_.func_180495_p(p_176196_2_.func_177976_e()).func_185915_l() ? true : (p_176196_1_.func_180495_p(p_176196_2_.func_177974_f()).func_185915_l() ? true : (p_176196_1_.func_180495_p(p_176196_2_.func_177978_c()).func_185915_l() ? true : p_176196_1_.func_180495_p(p_176196_2_.func_177968_d()).func_185915_l()));
|
||||
+ return p_176196_1_.func_180495_p(p_176196_2_.func_177976_e()).isSideSolid(p_176196_1_, p_176196_2_.func_177976_e(), EnumFacing.EAST) ||
|
||||
+ p_176196_1_.func_180495_p(p_176196_2_.func_177974_f()).isSideSolid(p_176196_1_, p_176196_2_.func_177974_f(), EnumFacing.WEST) ||
|
||||
+ p_176196_1_.func_180495_p(p_176196_2_.func_177978_c()).isSideSolid(p_176196_1_, p_176196_2_.func_177978_c(), EnumFacing.SOUTH) ||
|
||||
+ p_176196_1_.func_180495_p(p_176196_2_.func_177968_d()).isSideSolid(p_176196_1_, p_176196_2_.func_177968_d(), EnumFacing.NORTH);
|
||||
}
|
||||
|
||||
public IBlockState func_180642_a(World p_180642_1_, BlockPos p_180642_2_, EnumFacing p_180642_3_, float p_180642_4_, float p_180642_5_, float p_180642_6_, int p_180642_7_, EntityLivingBase p_180642_8_)
|
||||
@@ -116,7 +119,7 @@
|
||||
@@ -99,7 +102,7 @@
|
||||
|
||||
protected boolean func_176381_b(World p_176381_1_, BlockPos p_176381_2_, EnumFacing p_176381_3_)
|
||||
{
|
||||
- return p_176381_1_.func_180495_p(p_176381_2_.func_177972_a(p_176381_3_.func_176734_d())).func_177230_c().func_149721_r();
|
||||
+ return p_176381_1_.isSideSolid(p_176381_2_.func_177972_a(p_176381_3_.func_176734_d()), p_176381_3_, true);
|
||||
- return p_176381_1_.func_180495_p(p_176381_2_.func_177972_a(p_176381_3_.func_176734_d())).func_185915_l();
|
||||
+ return p_176381_1_.func_180495_p(p_176381_2_.func_177972_a(p_176381_3_.func_176734_d())).isSideSolid(p_176381_1_, p_176381_2_.func_177972_a(p_176381_3_.func_176734_d()), p_176381_3_);
|
||||
}
|
||||
|
||||
public IBlockState func_176203_a(int p_176203_1_)
|
||||
@@ -146,4 +149,6 @@
|
||||
@@ -139,4 +142,6 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176382_a});
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176382_a});
|
||||
}
|
||||
+
|
||||
+ @Override public boolean isLadder(IBlockAccess world, BlockPos pos, EntityLivingBase entity) { return true; }
|
||||
+ @Override public boolean isLadder(IBlockState state, IBlockAccess world, BlockPos pos, EntityLivingBase entity) { return true; }
|
||||
}
|
||||
|
|
|
@ -1,39 +1,39 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockLeaves.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockLeaves.java
|
||||
@@ -18,7 +18,7 @@
|
||||
@@ -17,7 +17,7 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
-public abstract class BlockLeaves extends BlockLeavesBase
|
||||
+public abstract class BlockLeaves extends BlockLeavesBase implements net.minecraftforge.common.IShearable
|
||||
-public abstract class BlockLeaves extends Block
|
||||
+public abstract class BlockLeaves extends Block implements net.minecraftforge.common.IShearable
|
||||
{
|
||||
public static final PropertyBool field_176237_a = PropertyBool.func_177716_a("decayable");
|
||||
public static final PropertyBool field_176236_b = PropertyBool.func_177716_a("check_decay");
|
||||
@@ -75,9 +75,9 @@
|
||||
@@ -53,9 +53,9 @@
|
||||
BlockPos blockpos = p_180663_2_.func_177982_a(j1, k1, l1);
|
||||
IBlockState iblockstate = p_180663_1_.func_180495_p(blockpos);
|
||||
|
||||
- if (iblockstate.func_177230_c().func_149688_o() == Material.field_151584_j && !((Boolean)iblockstate.func_177229_b(field_176236_b)).booleanValue())
|
||||
+ if (iblockstate.func_177230_c().isLeaves(p_180663_1_, blockpos))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151584_j && !((Boolean)iblockstate.func_177229_b(field_176236_b)).booleanValue())
|
||||
+ if (iblockstate.func_177230_c().isLeaves(iblockstate, p_180663_1_, blockpos))
|
||||
{
|
||||
- p_180663_1_.func_180501_a(blockpos, iblockstate.func_177226_a(field_176236_b, Boolean.valueOf(true)), 4);
|
||||
+ iblockstate.func_177230_c().beginLeavesDecay(p_180663_1_, blockpos);
|
||||
+ iblockstate.func_177230_c().beginLeavesDecay(iblockstate, p_180663_1_, blockpos);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -117,9 +117,9 @@
|
||||
{
|
||||
Block block = p_180650_1_.func_180495_p(blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2)).func_177230_c();
|
||||
@@ -96,9 +96,9 @@
|
||||
IBlockState iblockstate = p_180650_1_.func_180495_p(blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2));
|
||||
Block block = iblockstate.func_177230_c();
|
||||
|
||||
- if (block != Blocks.field_150364_r && block != Blocks.field_150363_s)
|
||||
+ if (!block.canSustainLeaves(p_180650_1_, blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2)))
|
||||
+ if (!block.canSustainLeaves(iblockstate, p_180650_1_, blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2)))
|
||||
{
|
||||
- if (block.func_149688_o() == Material.field_151584_j)
|
||||
+ if (block.isLeaves(p_180650_1_, blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2)))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151584_j)
|
||||
+ if (block.isLeaves(iblockstate, p_180650_1_, blockpos$mutableblockpos.func_181079_c(k + i2, l + j2, i1 + k2)))
|
||||
{
|
||||
this.field_150128_a[(i2 + l1) * k1 + (j2 + l1) * j1 + k2 + l1] = -2;
|
||||
}
|
||||
@@ -226,40 +226,7 @@
|
||||
@@ -205,40 +205,7 @@
|
||||
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
|
@ -75,18 +75,16 @@
|
|||
}
|
||||
|
||||
protected void func_176234_a(World p_176234_1_, BlockPos p_176234_2_, IBlockState p_176234_3_, int p_176234_4_)
|
||||
@@ -296,4 +263,48 @@
|
||||
}
|
||||
@@ -274,6 +241,49 @@
|
||||
|
||||
public abstract BlockPlanks.EnumType func_176233_b(int p_176233_1_);
|
||||
+
|
||||
|
||||
+ @Override public boolean isShearable(ItemStack item, IBlockAccess world, BlockPos pos){ return true; }
|
||||
+ @Override public boolean isLeaves(IBlockAccess world, BlockPos pos){ return true; }
|
||||
+ @Override public boolean isLeaves(IBlockState state, IBlockAccess world, BlockPos pos){ return true; }
|
||||
+
|
||||
+ @Override
|
||||
+ public void beginLeavesDecay(World world, BlockPos pos)
|
||||
+ public void beginLeavesDecay(IBlockState state, World world, BlockPos pos)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ if (!(Boolean)state.func_177229_b(field_176236_b))
|
||||
+ {
|
||||
+ world.func_180501_a(pos, state.func_177226_a(field_176236_b, true), 4);
|
||||
|
@ -123,4 +121,7 @@
|
|||
+ return ret;
|
||||
+ }
|
||||
+
|
||||
}
|
||||
+
|
||||
@SideOnly(Side.CLIENT)
|
||||
public boolean func_176225_a(IBlockState p_176225_1_, IBlockAccess p_176225_2_, BlockPos p_176225_3_, EnumFacing p_176225_4_)
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockLever.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockLever.java
|
||||
@@ -237,6 +237,12 @@
|
||||
return new BlockState(this, new IProperty[] {field_176360_a, field_176359_b});
|
||||
@@ -295,6 +295,12 @@
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176360_a, field_176359_b});
|
||||
}
|
||||
|
||||
+
|
||||
|
|
|
@ -1,22 +1,22 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockLog.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockLog.java
|
||||
@@ -33,9 +33,9 @@
|
||||
@@ -34,9 +34,9 @@
|
||||
{
|
||||
IBlockState iblockstate = p_180663_1_.func_180495_p(blockpos);
|
||||
|
||||
- if (iblockstate.func_177230_c().func_149688_o() == Material.field_151584_j && !((Boolean)iblockstate.func_177229_b(BlockLeaves.field_176236_b)).booleanValue())
|
||||
+ if (iblockstate.func_177230_c().isLeaves(p_180663_1_, blockpos))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151584_j && !((Boolean)iblockstate.func_177229_b(BlockLeaves.field_176236_b)).booleanValue())
|
||||
+ if (iblockstate.func_177230_c().isLeaves(iblockstate, p_180663_1_, blockpos))
|
||||
{
|
||||
- p_180663_1_.func_180501_a(blockpos, iblockstate.func_177226_a(BlockLeaves.field_176236_b, Boolean.valueOf(true)), 4);
|
||||
+ iblockstate.func_177230_c().beginLeavesDecay(p_180663_1_, blockpos);
|
||||
+ iblockstate.func_177230_c().beginLeavesDecay(iblockstate, p_180663_1_, blockpos);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -46,6 +46,9 @@
|
||||
return super.func_180642_a(p_180642_1_, p_180642_2_, p_180642_3_, p_180642_4_, p_180642_5_, p_180642_6_, p_180642_7_, p_180642_8_).func_177226_a(field_176299_a, BlockLog.EnumAxis.func_176870_a(p_180642_3_.func_176740_k()));
|
||||
@@ -69,6 +69,9 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ @Override public boolean canSustainLeaves(net.minecraft.world.IBlockAccess world, BlockPos pos){ return true; }
|
||||
+ @Override public boolean canSustainLeaves(IBlockState state, net.minecraft.world.IBlockAccess world, BlockPos pos){ return true; }
|
||||
+ @Override public boolean isWood(net.minecraft.world.IBlockAccess world, BlockPos pos){ return true; }
|
||||
+
|
||||
public static enum EnumAxis implements IStringSerializable
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockMobSpawner.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockMobSpawner.java
|
||||
@@ -37,10 +37,14 @@
|
||||
@@ -39,10 +39,14 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
|
@ -9,11 +9,11 @@
|
|||
}
|
||||
|
||||
+ @Override
|
||||
+ public int getExpDrop(net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ public int getExpDrop(IBlockState state, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ return 15 + RANDOM.nextInt(15) + RANDOM.nextInt(15);
|
||||
+ }
|
||||
+
|
||||
public boolean func_149662_c()
|
||||
public boolean func_149662_c(IBlockState p_149662_1_)
|
||||
{
|
||||
return false;
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockMushroom.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockMushroom.java
|
||||
@@ -71,7 +71,7 @@
|
||||
@@ -78,7 +78,7 @@
|
||||
if (p_180671_2_.func_177956_o() >= 0 && p_180671_2_.func_177956_o() < 256)
|
||||
{
|
||||
IBlockState iblockstate = p_180671_1_.func_180495_p(p_180671_2_.func_177977_b());
|
||||
- return iblockstate.func_177230_c() == Blocks.field_150391_bh ? true : (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.PODZOL ? true : p_180671_1_.func_175699_k(p_180671_2_) < 13 && this.func_149854_a(iblockstate.func_177230_c()));
|
||||
+ return iblockstate.func_177230_c() == Blocks.field_150391_bh ? true : (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.PODZOL ? true : p_180671_1_.func_175699_k(p_180671_2_) < 13 && iblockstate.func_177230_c().canSustainPlant(p_180671_1_, p_180671_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this));
|
||||
- return iblockstate.func_177230_c() == Blocks.field_150391_bh ? true : (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.PODZOL ? true : p_180671_1_.func_175699_k(p_180671_2_) < 13 && this.func_185514_i(iblockstate));
|
||||
+ return iblockstate.func_177230_c() == Blocks.field_150391_bh ? true : (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.PODZOL ? true : p_180671_1_.func_175699_k(p_180671_2_) < 13 && iblockstate.func_177230_c().canSustainPlant(iblockstate, p_180671_1_, p_180671_2_.func_177977_b(), net.minecraft.util.EnumFacing.UP, this));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -4,17 +4,17 @@
|
|||
{
|
||||
if (!p_180650_1_.field_72995_K)
|
||||
{
|
||||
- if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_177230_c().func_149717_k() > 2)
|
||||
+ if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_177230_c().getLightOpacity(p_180650_1_, p_180650_2_.func_177984_a()) > 2)
|
||||
- if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).func_185891_c() > 2)
|
||||
+ if (p_180650_1_.func_175671_l(p_180650_2_.func_177984_a()) < 4 && p_180650_1_.func_180495_p(p_180650_2_.func_177984_a()).getLightOpacity(p_180650_1_, p_180650_2_.func_177984_a()) > 2)
|
||||
{
|
||||
p_180650_1_.func_175656_a(p_180650_2_, Blocks.field_150346_d.func_176223_P().func_177226_a(BlockDirt.field_176386_a, BlockDirt.DirtType.DIRT));
|
||||
}
|
||||
@@ -53,7 +53,7 @@
|
||||
IBlockState iblockstate = p_180650_1_.func_180495_p(blockpos);
|
||||
Block block = p_180650_1_.func_180495_p(blockpos.func_177984_a()).func_177230_c();
|
||||
IBlockState iblockstate1 = p_180650_1_.func_180495_p(blockpos.func_177984_a());
|
||||
|
||||
- if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && block.func_149717_k() <= 2)
|
||||
+ if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && block.getLightOpacity(p_180650_1_, blockpos.func_177984_a()) <= 2)
|
||||
- if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && iblockstate1.func_185891_c() <= 2)
|
||||
+ if (iblockstate.func_177230_c() == Blocks.field_150346_d && iblockstate.func_177229_b(BlockDirt.field_176386_a) == BlockDirt.DirtType.DIRT && p_180650_1_.func_175671_l(blockpos.func_177984_a()) >= 4 && iblockstate1.getLightOpacity(p_180650_1_, blockpos.func_177984_a()) <= 2)
|
||||
{
|
||||
p_180650_1_.func_175656_a(blockpos, this.func_176223_P());
|
||||
}
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockNetherWart.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockNetherWart.java
|
||||
@@ -38,7 +38,7 @@
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
public boolean func_180671_f(World p_180671_1_, BlockPos p_180671_2_, IBlockState p_180671_3_)
|
||||
{
|
||||
- return this.func_149854_a(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c());
|
||||
- return this.func_185514_i(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()));
|
||||
+ return super.func_180671_f(p_180671_1_, p_180671_2_, p_180671_3_);
|
||||
}
|
||||
|
||||
public void func_180650_b(World p_180650_1_, BlockPos p_180650_2_, IBlockState p_180650_3_, Random p_180650_4_)
|
||||
@@ -54,9 +54,11 @@
|
||||
@@ -58,9 +58,11 @@
|
||||
super.func_180650_b(p_180650_1_, p_180650_2_, p_180650_3_, p_180650_4_);
|
||||
}
|
||||
|
||||
|
@ -22,11 +22,10 @@
|
|||
{
|
||||
int i = 1;
|
||||
|
||||
@@ -107,4 +109,24 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176486_a});
|
||||
@@ -106,6 +108,26 @@
|
||||
return ((Integer)p_176201_1_.func_177229_b(field_176486_a)).intValue();
|
||||
}
|
||||
+
|
||||
|
||||
+ @Override
|
||||
+ public java.util.List<ItemStack> getDrops(net.minecraft.world.IBlockAccess world, BlockPos pos, IBlockState state, int fortune)
|
||||
+ {
|
||||
|
@ -46,4 +45,7 @@
|
|||
+
|
||||
+ return ret;
|
||||
+ }
|
||||
}
|
||||
+
|
||||
protected BlockStateContainer func_180661_e()
|
||||
{
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176486_a});
|
||||
|
|
|
@ -1,24 +1,22 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockNewLeaf.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockNewLeaf.java
|
||||
@@ -99,14 +99,15 @@
|
||||
@@ -98,7 +98,7 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_2_.func_71045_bC() != null && p_180657_2_.func_71045_bC().func_77973_b() == Items.field_151097_aZ)
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ)
|
||||
+ if (false && !p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ) //Forge: Noop this
|
||||
{
|
||||
- p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Item.func_150898_a(this), 1, ((BlockPlanks.EnumType)p_180657_4_.func_177229_b(field_176240_P)).func_176839_a() - 4));
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Item.func_150898_a(this), 1, ((BlockPlanks.EnumType)p_180657_4_.func_177229_b(field_176240_P)).func_176839_a() - 4));
|
||||
@@ -108,4 +108,10 @@
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_, p_180657_6_);
|
||||
}
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public List<ItemStack> onSheared(ItemStack item, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ return new java.util.ArrayList(java.util.Arrays.asList(new ItemStack(this, 1, ((BlockPlanks.EnumType)state.func_177229_b(field_176240_P)).func_176839_a() - 4)));
|
||||
+ return java.util.Arrays.asList(new ItemStack(this, 1, world.func_180495_p(pos).func_177229_b(field_176240_P).func_176839_a() - 4));
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockNote.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockNote.java
|
||||
@@ -58,7 +58,9 @@
|
||||
@@ -64,7 +64,9 @@
|
||||
if (tileentity instanceof TileEntityNote)
|
||||
{
|
||||
TileEntityNote tileentitynote = (TileEntityNote)tileentity;
|
||||
|
@ -8,16 +8,16 @@
|
|||
tileentitynote.func_145877_a();
|
||||
+ if (old == tileentitynote.field_145879_a) return false;
|
||||
tileentitynote.func_175108_a(p_180639_1_, p_180639_2_);
|
||||
p_180639_4_.func_71029_a(StatList.field_181735_S);
|
||||
p_180639_4_.func_71029_a(StatList.field_188087_U);
|
||||
}
|
||||
@@ -98,6 +100,10 @@
|
||||
@@ -104,6 +106,10 @@
|
||||
|
||||
public boolean func_180648_a(World p_180648_1_, BlockPos p_180648_2_, IBlockState p_180648_3_, int p_180648_4_, int p_180648_5_)
|
||||
{
|
||||
+ net.minecraftforge.event.world.NoteBlockEvent.Play e = new net.minecraftforge.event.world.NoteBlockEvent.Play(p_180648_1_, p_180648_2_, p_180648_3_, p_180648_5_, p_180648_4_);
|
||||
+ if (net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(e)) return false;
|
||||
+ p_180648_4_ = e.instrument.ordinal();
|
||||
+ p_180648_4_ = e.getInstrument().ordinal();
|
||||
+ p_180648_5_ = e.getVanillaNoteId();
|
||||
float f = (float)Math.pow(2.0D, (double)(p_180648_5_ - 12) / 12.0D);
|
||||
p_180648_1_.func_72908_a((double)p_180648_2_.func_177958_n() + 0.5D, (double)p_180648_2_.func_177956_o() + 0.5D, (double)p_180648_2_.func_177952_p() + 0.5D, "note." + this.func_176433_b(p_180648_4_), 3.0F, f);
|
||||
p_180648_1_.func_184133_a((EntityPlayer)null, p_180648_2_, this.func_185576_e(p_180648_4_), SoundCategory.BLOCKS, 3.0F, f);
|
||||
p_180648_1_.func_175688_a(EnumParticleTypes.NOTE, (double)p_180648_2_.func_177958_n() + 0.5D, (double)p_180648_2_.func_177956_o() + 1.2D, (double)p_180648_2_.func_177952_p() + 0.5D, (double)p_180648_5_ / 24.0D, 0.0D, 0.0D, new int[0]);
|
||||
|
|
|
@ -1,21 +1,20 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockOldLeaf.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockOldLeaf.java
|
||||
@@ -142,11 +142,17 @@
|
||||
if (!p_180657_1_.field_72995_K && p_180657_2_.func_71045_bC() != null && p_180657_2_.func_71045_bC().func_77973_b() == Items.field_151097_aZ)
|
||||
@@ -103,11 +103,16 @@
|
||||
if (!p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ)
|
||||
{
|
||||
p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Item.func_150898_a(this), 1, ((BlockPlanks.EnumType)p_180657_4_.func_177229_b(field_176239_P)).func_176839_a()));
|
||||
}
|
||||
else
|
||||
{
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_, p_180657_6_);
|
||||
}
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public List<ItemStack> onSheared(ItemStack item, IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ public List<ItemStack> onSheared(ItemStack item, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ return new java.util.ArrayList(java.util.Arrays.asList(new ItemStack(this, 1, ((BlockPlanks.EnumType)state.func_177229_b(field_176239_P)).func_176839_a())));
|
||||
+ return java.util.Arrays.asList(new ItemStack(this, 1, world.func_180495_p(pos).func_177229_b(field_176239_P).func_176839_a()));
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockOre.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockOre.java
|
||||
@@ -58,34 +58,40 @@
|
||||
@@ -59,34 +59,39 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
|
@ -8,9 +8,8 @@
|
|||
- if (this.func_180660_a(p_180653_3_, p_180653_1_.field_73012_v, p_180653_5_) != Item.func_150898_a(this))
|
||||
+ }
|
||||
+ @Override
|
||||
+ public int getExpDrop(net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ public int getExpDrop(IBlockState state, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ Random rand = world instanceof World ? ((World)world).field_73012_v : new Random();
|
||||
+ if (this.func_180660_a(state, rand, fortune) != Item.func_150898_a(this))
|
||||
{
|
||||
|
@ -48,4 +47,4 @@
|
|||
+ return 0;
|
||||
}
|
||||
|
||||
public int func_176222_j(World p_176222_1_, BlockPos p_176222_2_)
|
||||
public ItemStack func_185473_a(World p_185473_1_, BlockPos p_185473_2_, IBlockState p_185473_3_)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockPane.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockPane.java
|
||||
@@ -38,7 +38,10 @@
|
||||
@@ -105,7 +105,10 @@
|
||||
|
||||
public IBlockState func_176221_a(IBlockState p_176221_1_, IBlockAccess p_176221_2_, BlockPos p_176221_3_)
|
||||
{
|
||||
|
@ -12,30 +12,15 @@
|
|||
}
|
||||
|
||||
public Item func_180660_a(IBlockState p_180660_1_, Random p_180660_2_, int p_180660_3_)
|
||||
@@ -64,10 +67,10 @@
|
||||
|
||||
public void func_180638_a(World p_180638_1_, BlockPos p_180638_2_, IBlockState p_180638_3_, AxisAlignedBB p_180638_4_, List<AxisAlignedBB> p_180638_5_, Entity p_180638_6_)
|
||||
@@ -182,4 +185,11 @@
|
||||
{
|
||||
- boolean flag = this.func_150098_a(p_180638_1_.func_180495_p(p_180638_2_.func_177978_c()).func_177230_c());
|
||||
- boolean flag1 = this.func_150098_a(p_180638_1_.func_180495_p(p_180638_2_.func_177968_d()).func_177230_c());
|
||||
- boolean flag2 = this.func_150098_a(p_180638_1_.func_180495_p(p_180638_2_.func_177976_e()).func_177230_c());
|
||||
- boolean flag3 = this.func_150098_a(p_180638_1_.func_180495_p(p_180638_2_.func_177974_f()).func_177230_c());
|
||||
+ boolean flag = this.canPaneConnectTo(p_180638_1_, p_180638_2_, EnumFacing.NORTH);
|
||||
+ boolean flag1 = this.canPaneConnectTo(p_180638_1_, p_180638_2_, EnumFacing.SOUTH);
|
||||
+ boolean flag2 = this.canPaneConnectTo(p_180638_1_, p_180638_2_, EnumFacing.WEST);
|
||||
+ boolean flag3 = this.canPaneConnectTo(p_180638_1_, p_180638_2_, EnumFacing.EAST);
|
||||
|
||||
if ((!flag2 || !flag3) && (flag2 || flag3 || flag || flag1))
|
||||
{
|
||||
@@ -186,4 +189,11 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176241_b, field_176242_M, field_176244_O, field_176243_N});
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176241_b, field_176242_M, field_176244_O, field_176243_N});
|
||||
}
|
||||
+
|
||||
+ public boolean canPaneConnectTo(IBlockAccess world, BlockPos pos, EnumFacing dir)
|
||||
+ {
|
||||
+ BlockPos off = pos.func_177972_a(dir);
|
||||
+ Block block = world.func_180495_p(off).func_177230_c();
|
||||
+ return func_150098_a(block) || block.isSideSolid(world, off, dir.func_176734_d());
|
||||
+ IBlockState state = world.func_180495_p(off);
|
||||
+ return func_150098_a(state.func_177230_c()) || state.isSideSolid(world, off, dir.func_176734_d());
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -1,31 +1,31 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockPistonBase.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockPistonBase.java
|
||||
@@ -189,7 +189,7 @@
|
||||
@@ -235,7 +235,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
- if (!flag1 && block.func_149688_o() != Material.field_151579_a && func_180696_a(block, p_180648_1_, blockpos, enumfacing.func_176734_d(), false) && (block.func_149656_h() == 0 || block == Blocks.field_150331_J || block == Blocks.field_150320_F))
|
||||
+ if (!flag1 && !block.isAir(p_180648_1_, blockpos) && func_180696_a(block, p_180648_1_, blockpos, enumfacing.func_176734_d(), false) && (block.func_149656_h() == 0 || block == Blocks.field_150331_J || block == Blocks.field_150320_F))
|
||||
- if (!flag1 && iblockstate.func_185904_a() != Material.field_151579_a && func_185646_a(iblockstate, p_180648_1_, blockpos, enumfacing.func_176734_d(), false) && (iblockstate.func_185905_o() == EnumPushReaction.NORMAL || block == Blocks.field_150331_J || block == Blocks.field_150320_F))
|
||||
+ if (!flag1 && !iblockstate.func_177230_c().isAir(iblockstate, p_180648_1_, blockpos) && func_185646_a(iblockstate, p_180648_1_, blockpos, enumfacing.func_176734_d(), false) && (iblockstate.func_185905_o() == EnumPushReaction.NORMAL || block == Blocks.field_150331_J || block == Blocks.field_150320_F))
|
||||
{
|
||||
this.func_176319_a(p_180648_1_, p_180648_2_, enumfacing, false);
|
||||
}
|
||||
@@ -333,7 +333,7 @@
|
||||
@@ -320,7 +320,7 @@
|
||||
return false;
|
||||
}
|
||||
|
||||
- return !(p_180696_0_ instanceof ITileEntityProvider);
|
||||
+ return !(p_180696_0_.hasTileEntity(p_180696_1_.func_180495_p(p_180696_2_)));
|
||||
- return !block.func_149716_u();
|
||||
+ return !block.hasTileEntity(p_185646_0_);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -371,7 +371,9 @@
|
||||
@@ -366,7 +366,9 @@
|
||||
{
|
||||
BlockPos blockpos = (BlockPos)list1.get(j);
|
||||
Block block = p_176319_1_.func_180495_p(blockpos).func_177230_c();
|
||||
- block.func_176226_b(p_176319_1_, blockpos, p_176319_1_.func_180495_p(blockpos), 0);
|
||||
+ //With our change to how snowballs are dropped this needs to disallow to mimic vanilla behavior.
|
||||
+ float chance = block instanceof BlockSnow ? -1.0f : 1.0f;
|
||||
+ block.func_180653_a(p_176319_1_, blockpos, p_176319_1_.func_180495_p(blockpos), chance, 0);
|
||||
p_176319_1_.func_175698_g(blockpos);
|
||||
--i;
|
||||
ablock[i] = block;
|
||||
BlockPos blockpos1 = (BlockPos)list2.get(j);
|
||||
IBlockState iblockstate = p_176319_1_.func_180495_p(blockpos1);
|
||||
- iblockstate.func_177230_c().func_176226_b(p_176319_1_, blockpos1, iblockstate, 0);
|
||||
+ // Forge: With our change to how snowballs are dropped this needs to disallow to mimic vanilla behavior.
|
||||
+ float chance = iblockstate.func_177230_c() instanceof BlockSnow ? -1.0f : 1.0f;
|
||||
+ iblockstate.func_177230_c().func_180653_a(p_176319_1_, blockpos1, iblockstate, chance, 0);
|
||||
p_176319_1_.func_175698_g(blockpos1);
|
||||
--k;
|
||||
aiblockstate[k] = iblockstate;
|
||||
|
|
|
@ -1,32 +1,31 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockPistonMoving.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockPistonMoving.java
|
||||
@@ -109,16 +109,7 @@
|
||||
@@ -110,7 +110,7 @@
|
||||
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
- if (!p_180653_1_.field_72995_K)
|
||||
- {
|
||||
- TileEntityPiston tileentitypiston = this.func_176422_e(p_180653_1_, p_180653_2_);
|
||||
-
|
||||
- if (tileentitypiston != null)
|
||||
- {
|
||||
- IBlockState iblockstate = tileentitypiston.func_174927_b();
|
||||
- iblockstate.func_177230_c().func_176226_b(p_180653_1_, p_180653_2_, iblockstate, 0);
|
||||
- }
|
||||
- }
|
||||
+ if (false && !p_180653_1_.field_72995_K) // Forge: Noop this out
|
||||
{
|
||||
TileEntityPiston tileentitypiston = this.func_185589_c(p_180653_1_, p_180653_2_);
|
||||
|
||||
@@ -120,6 +120,7 @@
|
||||
iblockstate.func_177230_c().func_176226_b(p_180653_1_, p_180653_2_, iblockstate, 0);
|
||||
}
|
||||
}
|
||||
+ super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
}
|
||||
|
||||
public MovingObjectPosition func_180636_a(World p_180636_1_, BlockPos p_180636_2_, Vec3 p_180636_3_, Vec3 p_180636_4_)
|
||||
@@ -282,4 +273,16 @@
|
||||
public RayTraceResult func_180636_a(IBlockState p_180636_1_, World p_180636_2_, BlockPos p_180636_3_, Vec3d p_180636_4_, Vec3d p_180636_5_)
|
||||
@@ -190,4 +191,16 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176426_a, field_176425_b});
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176426_a, field_176425_b});
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public java.util.List<net.minecraft.item.ItemStack> getDrops(IBlockAccess world, BlockPos pos, IBlockState state, int fortune)
|
||||
+ {
|
||||
+ TileEntityPiston tileentitypiston = this.func_176422_e(world, pos);
|
||||
+ TileEntityPiston tileentitypiston = this.func_185589_c(world, pos);
|
||||
+ if (tileentitypiston != null)
|
||||
+ {
|
||||
+ IBlockState pushed = tileentitypiston.func_174927_b();
|
||||
|
|
|
@ -1,24 +1,24 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockPotato.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockPotato.java
|
||||
@@ -22,13 +22,14 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
@@ -27,7 +27,7 @@
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
-
|
||||
|
||||
- if (!p_180653_1_.field_72995_K)
|
||||
- {
|
||||
- if (((Integer)p_180653_3_.func_177229_b(field_176488_a)).intValue() >= 7 && p_180653_1_.field_73012_v.nextInt(50) == 0)
|
||||
- {
|
||||
- func_180635_a(p_180653_1_, p_180653_2_, new ItemStack(Items.field_151170_bI));
|
||||
- }
|
||||
- }
|
||||
+ if (false && !p_180653_1_.field_72995_K) //Forge: Moved to getDrops
|
||||
{
|
||||
if (this.func_185525_y(p_180653_3_) && p_180653_1_.field_73012_v.nextInt(50) == 0)
|
||||
{
|
||||
@@ -40,4 +40,13 @@
|
||||
{
|
||||
return field_185534_a[((Integer)p_185496_1_.func_177229_b(this.func_185524_e())).intValue()];
|
||||
}
|
||||
+
|
||||
+ @Override
|
||||
+ public java.util.List<net.minecraft.item.ItemStack> getDrops(net.minecraft.world.IBlockAccess world, BlockPos pos, IBlockState state, int fortune)
|
||||
+ public java.util.List<ItemStack> getDrops(net.minecraft.world.IBlockAccess world, BlockPos pos, IBlockState state, int fortune)
|
||||
+ {
|
||||
+ java.util.List<ItemStack> ret = super.getDrops(world, pos, state, fortune);
|
||||
+ java.util.Random rand = world instanceof World ? ((World)world).field_73012_v : new java.util.Random();
|
||||
+ if (((Integer)state.func_177229_b(field_176488_a)) >= 7 && rand.nextInt(50) == 0)
|
||||
+ if (this.func_185525_y(state) && RANDOM.nextInt(50) == 0)
|
||||
+ ret.add(new ItemStack(Items.field_151170_bI));
|
||||
+ return ret;
|
||||
+ }
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockPumpkin.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockPumpkin.java
|
||||
@@ -115,7 +115,7 @@
|
||||
@@ -117,7 +117,7 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
- return p_176196_1_.func_180495_p(p_176196_2_).func_177230_c().field_149764_J.func_76222_j() && World.func_175683_a(p_176196_1_, p_176196_2_.func_177977_b());
|
||||
+ return p_176196_1_.func_180495_p(p_176196_2_).func_177230_c().func_176200_f(p_176196_1_, p_176196_2_) && World.func_175683_a(p_176196_1_, p_176196_2_.func_177977_b());
|
||||
- return p_176196_1_.func_180495_p(p_176196_2_).func_177230_c().field_149764_J.func_76222_j() && p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_185896_q();
|
||||
+ return p_176196_1_.func_180495_p(p_176196_2_).func_177230_c().func_176200_f(p_176196_1_, p_176196_2_) && p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).isSideSolid(p_176196_1_, p_176196_2_, EnumFacing.UP);
|
||||
}
|
||||
|
||||
public IBlockState func_180642_a(World p_180642_1_, BlockPos p_180642_2_, EnumFacing p_180642_3_, float p_180642_4_, float p_180642_5_, float p_180642_6_, int p_180642_7_, EntityLivingBase p_180642_8_)
|
||||
public IBlockState func_185499_a(IBlockState p_185499_1_, Rotation p_185499_2_)
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockQuartz.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockQuartz.java
|
||||
@@ -90,6 +90,26 @@
|
||||
return new BlockState(this, new IProperty[] {field_176335_a});
|
||||
@@ -113,6 +113,26 @@
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176335_a});
|
||||
}
|
||||
|
||||
+ public boolean rotateBlock(World world, BlockPos pos, EnumFacing axis)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty prop : state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("variant") && prop.func_177699_b() == EnumType.class)
|
||||
+ {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRailBase.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRailBase.java
|
||||
@@ -31,7 +31,7 @@
|
||||
@@ -32,7 +32,7 @@
|
||||
public static boolean func_176563_d(IBlockState p_176563_0_)
|
||||
{
|
||||
Block block = p_176563_0_.func_177230_c();
|
||||
|
@ -9,7 +9,46 @@
|
|||
}
|
||||
|
||||
protected BlockRailBase(boolean p_i45389_1_)
|
||||
@@ -175,6 +175,98 @@
|
||||
@@ -65,7 +65,7 @@
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
- return p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_185896_q();
|
||||
+ return p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).isSideSolid(p_176196_1_, p_176196_2_, EnumFacing.UP);
|
||||
}
|
||||
|
||||
public void func_176213_c(World p_176213_1_, BlockPos p_176213_2_, IBlockState p_176213_3_)
|
||||
@@ -88,24 +88,24 @@
|
||||
BlockRailBase.EnumRailDirection blockrailbase$enumraildirection = (BlockRailBase.EnumRailDirection)p_176204_3_.func_177229_b(this.func_176560_l());
|
||||
boolean flag = false;
|
||||
|
||||
- if (!p_176204_1_.func_180495_p(p_176204_2_.func_177977_b()).func_185896_q())
|
||||
+ if (!p_176204_1_.func_180495_p(p_176204_2_.func_177977_b()).isSideSolid(p_176204_1_, p_176204_2_.func_177977_b(), EnumFacing.UP))
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
|
||||
- if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_EAST && !p_176204_1_.func_180495_p(p_176204_2_.func_177974_f()).func_185896_q())
|
||||
+ if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_EAST && !p_176204_1_.func_180495_p(p_176204_2_.func_177974_f()).isSideSolid(p_176204_1_, p_176204_2_.func_177974_f(), EnumFacing.UP))
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
- else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_WEST && !p_176204_1_.func_180495_p(p_176204_2_.func_177976_e()).func_185896_q())
|
||||
+ else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_WEST && !p_176204_1_.func_180495_p(p_176204_2_.func_177976_e()).isSideSolid(p_176204_1_, p_176204_2_.func_177976_e(), EnumFacing.UP))
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
- else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_NORTH && !p_176204_1_.func_180495_p(p_176204_2_.func_177978_c()).func_185896_q())
|
||||
+ else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_NORTH && !p_176204_1_.func_180495_p(p_176204_2_.func_177978_c()).isSideSolid(p_176204_1_, p_176204_2_.func_177978_c(), EnumFacing.UP))
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
- else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_SOUTH && !p_176204_1_.func_180495_p(p_176204_2_.func_177968_d()).func_185896_q())
|
||||
+ else if (blockrailbase$enumraildirection == BlockRailBase.EnumRailDirection.ASCENDING_SOUTH && !p_176204_1_.func_180495_p(p_176204_2_.func_177968_d()).isSideSolid(p_176204_1_, p_176204_2_.func_177968_d(), EnumFacing.UP))
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
@@ -160,6 +160,81 @@
|
||||
|
||||
public abstract IProperty<BlockRailBase.EnumRailDirection> func_176560_l();
|
||||
|
||||
|
@ -92,7 +131,7 @@
|
|||
+ public boolean rotateBlock(World world, BlockPos pos, EnumFacing axis)
|
||||
+ {
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ for (IProperty prop : (java.util.Set<IProperty>)state.func_177228_b().keySet())
|
||||
+ for (IProperty prop : state.func_177228_b().keySet())
|
||||
+ {
|
||||
+ if (prop.func_177701_a().equals("shape"))
|
||||
+ {
|
||||
|
@ -108,7 +147,7 @@
|
|||
public static enum EnumRailDirection implements IStringSerializable
|
||||
{
|
||||
NORTH_SOUTH(0, "north_south"),
|
||||
@@ -245,6 +337,7 @@
|
||||
@@ -230,6 +305,7 @@
|
||||
private IBlockState field_180366_e;
|
||||
private final boolean field_150656_f;
|
||||
private final List<BlockPos> field_150657_g = Lists.<BlockPos>newArrayList();
|
||||
|
@ -116,19 +155,18 @@
|
|||
|
||||
public Rail(World p_i45739_2_, BlockPos p_i45739_3_, IBlockState p_i45739_4_)
|
||||
{
|
||||
@@ -252,8 +345,9 @@
|
||||
this.field_180367_c = p_i45739_3_;
|
||||
@@ -238,7 +314,8 @@
|
||||
this.field_180366_e = p_i45739_4_;
|
||||
this.field_180365_d = (BlockRailBase)p_i45739_4_.func_177230_c();
|
||||
- BlockRailBase.EnumRailDirection blockrailbase$enumraildirection = (BlockRailBase.EnumRailDirection)p_i45739_4_.func_177229_b(BlockRailBase.this.func_176560_l());
|
||||
BlockRailBase.EnumRailDirection blockrailbase$enumraildirection = (BlockRailBase.EnumRailDirection)p_i45739_4_.func_177229_b(this.field_180365_d.func_176560_l());
|
||||
- this.field_150656_f = this.field_180365_d.field_150053_a;
|
||||
+ BlockRailBase.EnumRailDirection blockrailbase$enumraildirection = field_180365_d.getRailDirection(p_i45739_2_, p_i45739_3_, p_i45739_4_, null);
|
||||
+ this.field_150656_f = !this.field_180365_d.isFlexibleRail(p_i45739_2_, p_i45739_3_);
|
||||
+ canMakeSlopes = this.field_180365_d.canMakeSlopes(p_i45739_2_, p_i45739_3_);
|
||||
+ this.canMakeSlopes = this.field_180365_d.canMakeSlopes(p_i45739_2_, p_i45739_3_);
|
||||
this.func_180360_a(blockrailbase$enumraildirection);
|
||||
}
|
||||
|
||||
@@ -439,7 +533,7 @@
|
||||
@@ -429,7 +506,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -137,7 +175,7 @@
|
|||
{
|
||||
if (BlockRailBase.func_176562_d(this.field_150660_b, blockpos.func_177984_a()))
|
||||
{
|
||||
@@ -452,7 +546,7 @@
|
||||
@@ -442,7 +519,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -146,7 +184,7 @@
|
|||
{
|
||||
if (BlockRailBase.func_176562_d(this.field_150660_b, blockpos3.func_177984_a()))
|
||||
{
|
||||
@@ -595,7 +689,7 @@
|
||||
@@ -585,7 +662,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -155,7 +193,7 @@
|
|||
{
|
||||
if (BlockRailBase.func_176562_d(this.field_150660_b, blockpos.func_177984_a()))
|
||||
{
|
||||
@@ -608,7 +702,7 @@
|
||||
@@ -598,7 +675,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRedstoneComparator.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRedstoneComparator.java
|
||||
@@ -295,6 +295,21 @@
|
||||
return this.func_176223_P().func_177226_a(field_176387_N, p_180642_8_.func_174811_aO().func_176734_d()).func_177226_a(field_176464_a, Boolean.valueOf(false)).func_177226_a(field_176463_b, BlockRedstoneComparator.Mode.COMPARE);
|
||||
@@ -310,6 +310,21 @@
|
||||
return this.func_176223_P().func_177226_a(field_185512_D, p_180642_8_.func_174811_aO().func_176734_d()).func_177226_a(field_176464_a, Boolean.valueOf(false)).func_177226_a(field_176463_b, BlockRedstoneComparator.Mode.COMPARE);
|
||||
}
|
||||
|
||||
+ @Override
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRedstoneDiode.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRedstoneDiode.java
|
||||
@@ -198,6 +198,8 @@
|
||||
@@ -204,6 +204,8 @@
|
||||
{
|
||||
EnumFacing enumfacing = (EnumFacing)p_176400_3_.func_177229_b(field_176387_N);
|
||||
EnumFacing enumfacing = (EnumFacing)p_176400_3_.func_177229_b(field_185512_D);
|
||||
BlockPos blockpos = p_176400_2_.func_177972_a(enumfacing.func_176734_d());
|
||||
+ if(net.minecraftforge.event.ForgeEventFactory.onNeighborNotify(p_176400_1_, p_176400_2_, p_176400_1_.func_180495_p(p_176400_2_), java.util.EnumSet.of(enumfacing.func_176734_d())).isCanceled())
|
||||
+ return;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRedstoneOre.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRedstoneOre.java
|
||||
@@ -91,12 +91,16 @@
|
||||
@@ -92,12 +92,16 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
|
@ -8,9 +8,9 @@
|
|||
|
||||
- if (this.func_180660_a(p_180653_3_, p_180653_1_.field_73012_v, p_180653_5_) != Item.func_150898_a(this))
|
||||
+ @Override
|
||||
+ public int getExpDrop(net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ public int getExpDrop(IBlockState state, net.minecraft.world.IBlockAccess world, BlockPos pos, int fortune)
|
||||
+ {
|
||||
+ if (this.func_180660_a(world.func_180495_p(pos), RANDOM, fortune) != Item.func_150898_a(this))
|
||||
+ if (this.func_180660_a(state, RANDOM, fortune) != Item.func_150898_a(this))
|
||||
{
|
||||
- int i = 1 + p_180653_1_.field_73012_v.nextInt(5);
|
||||
- this.func_180637_b(p_180653_1_, p_180653_2_, i);
|
||||
|
|
|
@ -1,59 +1,65 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRedstoneWire.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRedstoneWire.java
|
||||
@@ -58,10 +58,10 @@
|
||||
@@ -97,15 +97,15 @@
|
||||
BlockPos blockpos = p_176341_2_.func_177972_a(p_176341_3_);
|
||||
Block block = p_176341_1_.func_180495_p(p_176341_2_.func_177972_a(p_176341_3_)).func_177230_c();
|
||||
IBlockState iblockstate = p_176341_1_.func_180495_p(p_176341_2_.func_177972_a(p_176341_3_));
|
||||
|
||||
- if (!func_176343_a(p_176341_1_.func_180495_p(blockpos), p_176341_3_) && (block.func_149637_q() || !func_176346_d(p_176341_1_.func_180495_p(blockpos.func_177977_b()))))
|
||||
+ if (!canRestoneConnect(p_176341_1_, blockpos, p_176341_3_) && (block.func_149637_q() || !canRestoneConnect(p_176341_1_, blockpos.func_177977_b(), null)))
|
||||
- if (!func_176343_a(p_176341_1_.func_180495_p(blockpos), p_176341_3_) && (iblockstate.func_185915_l() || !func_176346_d(p_176341_1_.func_180495_p(blockpos.func_177977_b()))))
|
||||
+ if (!canConnectTo(p_176341_1_.func_180495_p(blockpos), p_176341_3_, p_176341_1_, blockpos) && (iblockstate.func_185915_l() || !func_176340_e(p_176341_1_, blockpos.func_177977_b())))
|
||||
{
|
||||
Block block1 = p_176341_1_.func_180495_p(p_176341_2_.func_177984_a()).func_177230_c();
|
||||
- return !block1.func_149637_q() && block.func_149637_q() && func_176346_d(p_176341_1_.func_180495_p(blockpos.func_177984_a())) ? BlockRedstoneWire.EnumAttachPosition.UP : BlockRedstoneWire.EnumAttachPosition.NONE;
|
||||
+ return !block1.func_149637_q() && block.func_149637_q() && canRestoneConnect(p_176341_1_, blockpos.func_177984_a(), null) ? BlockRedstoneWire.EnumAttachPosition.UP : BlockRedstoneWire.EnumAttachPosition.NONE;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -359,35 +359,24 @@
|
||||
Block block = iblockstate.func_177230_c();
|
||||
boolean flag = block.func_149721_r();
|
||||
boolean flag1 = p_176339_1_.func_180495_p(p_176339_2_.func_177984_a()).func_177230_c().func_149721_r();
|
||||
- return !flag1 && flag && func_176340_e(p_176339_1_, blockpos.func_177984_a()) ? true : (func_176343_a(iblockstate, p_176339_3_) ? true : (block == Blocks.field_150416_aS && iblockstate.func_177229_b(BlockRedstoneDiode.field_176387_N) == p_176339_3_ ? true : !flag && func_176340_e(p_176339_1_, blockpos.func_177977_b())));
|
||||
+ return !flag1 && flag && canRestoneConnect(p_176339_1_, blockpos.func_177984_a(), null) ? true : (canRestoneConnect(p_176339_1_, blockpos, p_176339_3_) ? true : (block == Blocks.field_150416_aS && iblockstate.func_177229_b(BlockRedstoneDiode.field_176387_N) == p_176339_3_ ? true : !flag && canRestoneConnect(p_176339_1_, blockpos.func_177977_b(), null)));
|
||||
IBlockState iblockstate1 = p_176341_1_.func_180495_p(p_176341_2_.func_177984_a());
|
||||
|
||||
if (!iblockstate1.func_185915_l())
|
||||
{
|
||||
- boolean flag = p_176341_1_.func_180495_p(blockpos).func_185896_q() || p_176341_1_.func_180495_p(blockpos).func_177230_c() == Blocks.field_150426_aN;
|
||||
+ boolean flag = p_176341_1_.func_180495_p(blockpos).isSideSolid(p_176341_1_, blockpos, EnumFacing.UP) || p_176341_1_.func_180495_p(blockpos).func_177230_c() == Blocks.field_150426_aN;
|
||||
|
||||
- if (flag && func_176346_d(p_176341_1_.func_180495_p(blockpos.func_177984_a())))
|
||||
+ if (flag && func_176340_e(p_176341_1_, blockpos.func_177984_a()))
|
||||
{
|
||||
if (iblockstate.func_185898_k())
|
||||
{
|
||||
@@ -406,35 +406,30 @@
|
||||
IBlockState iblockstate = p_176339_1_.func_180495_p(blockpos);
|
||||
boolean flag = iblockstate.func_185915_l();
|
||||
boolean flag1 = p_176339_1_.func_180495_p(p_176339_2_.func_177984_a()).func_185915_l();
|
||||
- return !flag1 && flag && func_176340_e(p_176339_1_, blockpos.func_177984_a()) ? true : (func_176343_a(iblockstate, p_176339_3_) ? true : (iblockstate.func_177230_c() == Blocks.field_150416_aS && iblockstate.func_177229_b(BlockRedstoneDiode.field_185512_D) == p_176339_3_ ? true : !flag && func_176340_e(p_176339_1_, blockpos.func_177977_b())));
|
||||
+ return !flag1 && flag && func_176340_e(p_176339_1_, blockpos.func_177984_a()) ? true : (canConnectTo(iblockstate, p_176339_3_, p_176339_1_, p_176339_2_) ? true : (iblockstate.func_177230_c() == Blocks.field_150416_aS && iblockstate.func_177229_b(BlockRedstoneDiode.field_185512_D) == p_176339_3_ ? true : !flag && func_176340_e(p_176339_1_, blockpos.func_177977_b())));
|
||||
}
|
||||
|
||||
- protected static boolean func_176340_e(IBlockAccess p_176340_0_, BlockPos p_176340_1_)
|
||||
+ protected static boolean canRestoneConnect(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
protected static boolean func_176340_e(IBlockAccess p_176340_0_, BlockPos p_176340_1_)
|
||||
{
|
||||
- return func_176346_d(p_176340_0_.func_180495_p(p_176340_1_));
|
||||
- }
|
||||
-
|
||||
+ return canConnectTo(p_176340_0_.func_180495_p(p_176340_1_), null, p_176340_0_, p_176340_1_);
|
||||
}
|
||||
|
||||
- protected static boolean func_176346_d(IBlockState p_176346_0_)
|
||||
- {
|
||||
+ protected static boolean canConnectTo(IBlockState blockState, EnumFacing side, IBlockAccess world, BlockPos pos)
|
||||
{
|
||||
- return func_176343_a(p_176346_0_, (EnumFacing)null);
|
||||
- }
|
||||
-
|
||||
+ Block block = blockState.func_177230_c();
|
||||
|
||||
- protected static boolean func_176343_a(IBlockState p_176343_0_, EnumFacing p_176343_1_)
|
||||
- {
|
||||
- Block block = p_176343_0_.func_177230_c();
|
||||
-
|
||||
- if (block == Blocks.field_150488_af)
|
||||
+ IBlockState state = world.func_180495_p(pos);
|
||||
+ if (state.func_177230_c() == Blocks.field_150488_af)
|
||||
if (block == Blocks.field_150488_af)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
- else if (Blocks.field_150413_aR.func_149907_e(block))
|
||||
+ else if (Blocks.field_150413_aR.func_149907_e(state.func_177230_c()))
|
||||
- else if (Blocks.field_150413_aR.func_185547_C(p_176343_0_))
|
||||
+ else if (Blocks.field_150413_aR.func_185547_C(blockState))
|
||||
{
|
||||
- EnumFacing enumfacing = (EnumFacing)p_176343_0_.func_177229_b(BlockRedstoneRepeater.field_176387_N);
|
||||
- EnumFacing enumfacing = (EnumFacing)p_176343_0_.func_177229_b(BlockRedstoneRepeater.field_185512_D);
|
||||
- return enumfacing == p_176343_1_ || enumfacing.func_176734_d() == p_176343_1_;
|
||||
+ EnumFacing direction = (EnumFacing)state.func_177229_b(BlockRedstoneRepeater.field_176387_N);
|
||||
+ return direction == side || direction.func_176734_d() == side;
|
||||
+ EnumFacing enumfacing = (EnumFacing)blockState.func_177229_b(BlockRedstoneRepeater.field_185512_D);
|
||||
+ return enumfacing == side || enumfacing.func_176734_d() == side;
|
||||
}
|
||||
else
|
||||
{
|
||||
- return block.func_149744_f() && p_176343_1_ != null;
|
||||
+ return state.func_177230_c().canConnectRedstone(world, pos, side);
|
||||
- return p_176343_0_.func_185897_m() && p_176343_1_ != null;
|
||||
+ return blockState.func_177230_c().canConnectRedstone(blockState, world, pos, side);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockReed.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockReed.java
|
||||
@@ -18,7 +18,7 @@
|
||||
@@ -19,7 +19,7 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
|
@ -8,20 +8,22 @@
|
|||
+public class BlockReed extends Block implements net.minecraftforge.common.IPlantable
|
||||
{
|
||||
public static final PropertyInteger field_176355_a = PropertyInteger.func_177719_a("age", 0, 15);
|
||||
protected static final AxisAlignedBB field_185701_b = new AxisAlignedBB(0.125D, 0.0D, 0.125D, 0.875D, 1.0D, 0.875D);
|
||||
@@ -69,7 +69,9 @@
|
||||
|
||||
@@ -65,6 +65,7 @@
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
Block block = p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_177230_c();
|
||||
+ if (block.canSustainPlant(p_176196_1_, p_176196_2_.func_177977_b(), EnumFacing.UP, this)) return true;
|
||||
- Block block = p_176196_1_.func_180495_p(p_176196_2_.func_177977_b()).func_177230_c();
|
||||
+ IBlockState state = p_176196_1_.func_180495_p(p_176196_2_.func_177977_b());
|
||||
+ Block block = state.func_177230_c();
|
||||
+ if (block.canSustainPlant(state, p_176196_1_, p_176196_2_.func_177977_b(), EnumFacing.UP, this)) return true;
|
||||
|
||||
if (block == this)
|
||||
{
|
||||
@@ -164,4 +165,15 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176355_a});
|
||||
@@ -162,6 +164,17 @@
|
||||
return ((Integer)p_176201_1_.func_177229_b(field_176355_a)).intValue();
|
||||
}
|
||||
+
|
||||
|
||||
+ @Override
|
||||
+ public net.minecraftforge.common.EnumPlantType getPlantType(IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
|
@ -32,4 +34,7 @@
|
|||
+ {
|
||||
+ return this.func_176223_P();
|
||||
+ }
|
||||
}
|
||||
+
|
||||
protected BlockStateContainer func_180661_e()
|
||||
{
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176355_a});
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockRotatedPillar.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockRotatedPillar.java
|
||||
@@ -18,4 +18,18 @@
|
||||
{
|
||||
@@ -28,6 +28,21 @@
|
||||
super(p_i46385_1_, p_i46385_2_);
|
||||
}
|
||||
+
|
||||
+ public boolean rotateBlock(net.minecraft.world.World world, net.minecraft.util.BlockPos pos, EnumFacing axis)
|
||||
|
||||
+ @Override
|
||||
+ public boolean rotateBlock(net.minecraft.world.World world, BlockPos pos, EnumFacing axis)
|
||||
+ {
|
||||
+ net.minecraft.block.state.IBlockState state = world.func_180495_p(pos);
|
||||
+ for (net.minecraft.block.properties.IProperty<?> prop : state.func_177228_b().keySet())
|
||||
|
@ -18,4 +18,7 @@
|
|||
+ }
|
||||
+ return false;
|
||||
+ }
|
||||
}
|
||||
+
|
||||
public IBlockState func_185499_a(IBlockState p_185499_1_, Rotation p_185499_2_)
|
||||
{
|
||||
switch (p_185499_2_)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockSapling.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockSapling.java
|
||||
@@ -71,6 +71,7 @@
|
||||
@@ -77,6 +77,7 @@
|
||||
|
||||
public void func_176476_e(World p_176476_1_, BlockPos p_176476_2_, IBlockState p_176476_3_, Random p_176476_4_)
|
||||
{
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockSkull.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockSkull.java
|
||||
@@ -121,10 +121,6 @@
|
||||
return tileentity instanceof TileEntitySkull ? ((TileEntitySkull)tileentity).func_145904_a() : super.func_176222_j(p_176222_1_, p_176222_2_);
|
||||
@@ -116,10 +116,6 @@
|
||||
return new ItemStack(Items.field_151144_bL, 1, i);
|
||||
}
|
||||
|
||||
- public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
|
@ -11,7 +11,7 @@
|
|||
public void func_176208_a(World p_176208_1_, BlockPos p_176208_2_, IBlockState p_176208_3_, EntityPlayer p_176208_4_)
|
||||
{
|
||||
if (p_176208_4_.field_71075_bZ.field_75098_d)
|
||||
@@ -132,13 +128,18 @@
|
||||
@@ -127,22 +123,27 @@
|
||||
p_176208_3_ = p_176208_3_.func_177226_a(field_176417_b, Boolean.valueOf(true));
|
||||
p_176208_1_.func_180501_a(p_176208_2_, p_176208_3_, 4);
|
||||
}
|
||||
|
@ -25,22 +25,25 @@
|
|||
- if (!p_180663_1_.field_72995_K)
|
||||
+ super.func_180663_b(p_180663_1_, p_180663_2_, p_180663_3_);
|
||||
+ }
|
||||
+ public java.util.List<ItemStack> getDrops(IBlockAccess p_180663_1_, BlockPos p_180663_2_, IBlockState p_180663_3_, int fortune)
|
||||
+ public java.util.List<ItemStack> getDrops(IBlockAccess worldIn, BlockPos pos, IBlockState state, int fortune)
|
||||
+ {
|
||||
+ java.util.List<ItemStack> ret = new java.util.ArrayList<ItemStack>();
|
||||
{
|
||||
if (!((Boolean)p_180663_3_.func_177229_b(field_176417_b)).booleanValue())
|
||||
- if (!((Boolean)p_180663_3_.func_177229_b(field_176417_b)).booleanValue())
|
||||
+ if (!((Boolean)state.func_177229_b(field_176417_b)).booleanValue())
|
||||
{
|
||||
@@ -147,7 +148,7 @@
|
||||
- TileEntity tileentity = p_180663_1_.func_175625_s(p_180663_2_);
|
||||
+ TileEntity tileentity = worldIn.func_175625_s(pos);
|
||||
|
||||
if (tileentity instanceof TileEntitySkull)
|
||||
{
|
||||
TileEntitySkull tileentityskull = (TileEntitySkull)tileentity;
|
||||
- ItemStack itemstack = new ItemStack(Items.field_151144_bL, 1, this.func_176222_j(p_180663_1_, p_180663_2_));
|
||||
- ItemStack itemstack = this.func_185473_a(p_180663_1_, p_180663_2_, p_180663_3_);
|
||||
+ ItemStack itemstack = new ItemStack(Items.field_151144_bL, 1, tileentityskull.func_145904_a());
|
||||
|
||||
if (tileentityskull.func_145904_a() == 3 && tileentityskull.func_152108_a() != null)
|
||||
{
|
||||
@@ -157,12 +158,11 @@
|
||||
@@ -152,12 +153,11 @@
|
||||
itemstack.func_77978_p().func_74782_a("SkullOwner", nbttagcompound);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,38 +1,35 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockSlab.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockSlab.java
|
||||
@@ -91,6 +91,17 @@
|
||||
@@ -50,6 +50,16 @@
|
||||
return this.func_176552_j();
|
||||
}
|
||||
|
||||
+ @Override
|
||||
+ public boolean doesSideBlockRendering(IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ {
|
||||
+ if ( func_149662_c() )
|
||||
+ public boolean doesSideBlockRendering(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ {
|
||||
+ if ( state.func_185914_p() )
|
||||
+ return true;
|
||||
+
|
||||
+ // face is on the block being rendered, not this block.
|
||||
+ EnumBlockHalf side = world.func_180495_p(pos).func_177229_b(field_176554_a);
|
||||
+ return (side == EnumBlockHalf.TOP && face == EnumFacing.DOWN) || (side == EnumBlockHalf.BOTTOM && face == EnumFacing.UP);
|
||||
+
|
||||
+ EnumBlockHalf side = state.func_177229_b(field_176554_a);
|
||||
+ return (side == EnumBlockHalf.TOP && face == EnumFacing.UP) || (side == EnumBlockHalf.BOTTOM && face == EnumFacing.DOWN);
|
||||
+ }
|
||||
+
|
||||
public IBlockState func_180642_a(World p_180642_1_, BlockPos p_180642_2_, EnumFacing p_180642_3_, float p_180642_4_, float p_180642_5_, float p_180642_6_, int p_180642_7_, EntityLivingBase p_180642_8_)
|
||||
{
|
||||
IBlockState iblockstate = super.func_180642_a(p_180642_1_, p_180642_2_, p_180642_3_, p_180642_4_, p_180642_5_, p_180642_6_, p_180642_7_, p_180642_8_).func_177226_a(field_176554_a, BlockSlab.EnumBlockHalf.BOTTOM);
|
||||
@@ -118,15 +129,8 @@
|
||||
@@ -77,13 +87,14 @@
|
||||
{
|
||||
return false;
|
||||
}
|
||||
- else
|
||||
- {
|
||||
- BlockPos blockpos = p_176225_2_.func_177972_a(p_176225_3_.func_176734_d());
|
||||
- IBlockState iblockstate = p_176225_1_.func_180495_p(p_176225_2_);
|
||||
- IBlockState iblockstate1 = p_176225_1_.func_180495_p(blockpos);
|
||||
- boolean flag = func_150003_a(iblockstate.func_177230_c()) && iblockstate.func_177229_b(field_176554_a) == BlockSlab.EnumBlockHalf.TOP;
|
||||
- boolean flag1 = func_150003_a(iblockstate1.func_177230_c()) && iblockstate1.func_177229_b(field_176554_a) == BlockSlab.EnumBlockHalf.TOP;
|
||||
- return flag1 ? (p_176225_3_ == EnumFacing.DOWN ? true : (p_176225_3_ == EnumFacing.UP && super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_) ? true : !func_150003_a(iblockstate.func_177230_c()) || !flag)) : (p_176225_3_ == EnumFacing.UP ? true : (p_176225_3_ == EnumFacing.DOWN && super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_) ? true : !func_150003_a(iblockstate.func_177230_c()) || flag));
|
||||
- }
|
||||
+ // additional logic breaks doesSideBlockRendering and is no longer useful.
|
||||
+ return super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_);
|
||||
+ else if (false) // Forge: Additional logic breaks doesSideBlockRendering and is no longer useful.
|
||||
{
|
||||
IBlockState iblockstate = p_176225_2_.func_180495_p(p_176225_3_.func_177972_a(p_176225_4_));
|
||||
boolean flag = func_185675_i(iblockstate) && iblockstate.func_177229_b(field_176554_a) == BlockSlab.EnumBlockHalf.TOP;
|
||||
boolean flag1 = func_185675_i(p_176225_1_) && p_176225_1_.func_177229_b(field_176554_a) == BlockSlab.EnumBlockHalf.TOP;
|
||||
return flag1 ? (p_176225_4_ == EnumFacing.DOWN ? true : (p_176225_4_ == EnumFacing.UP && super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_, p_176225_4_) ? true : !func_185675_i(iblockstate) || !flag)) : (p_176225_4_ == EnumFacing.UP ? true : (p_176225_4_ == EnumFacing.DOWN && super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_, p_176225_4_) ? true : !func_185675_i(iblockstate) || flag));
|
||||
}
|
||||
+ return super.func_176225_a(p_176225_1_, p_176225_2_, p_176225_3_, p_176225_4_);
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockSnow.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockSnow.java
|
||||
@@ -79,7 +79,7 @@
|
||||
@@ -73,7 +73,7 @@
|
||||
{
|
||||
IBlockState iblockstate = p_176196_1_.func_180495_p(p_176196_2_.func_177977_b());
|
||||
Block block = iblockstate.func_177230_c();
|
||||
- return block != Blocks.field_150432_aD && block != Blocks.field_150403_cj ? (block.func_149688_o() == Material.field_151584_j ? true : (block == this && ((Integer)iblockstate.func_177229_b(field_176315_a)).intValue() >= 7 ? true : block.func_149662_c() && block.field_149764_J.func_76230_c())) : false;
|
||||
+ return block != Blocks.field_150432_aD && block != Blocks.field_150403_cj ? (block.isLeaves(p_176196_1_, p_176196_2_.func_177977_b()) ? true : (block == this && ((Integer)iblockstate.func_177229_b(field_176315_a)).intValue() >= 7 ? true : block.func_149662_c() && block.field_149764_J.func_76230_c())) : false;
|
||||
- return block != Blocks.field_150432_aD && block != Blocks.field_150403_cj ? (iblockstate.func_185904_a() == Material.field_151584_j ? true : (block == this && ((Integer)iblockstate.func_177229_b(field_176315_a)).intValue() >= 7 ? true : iblockstate.func_185914_p() && iblockstate.func_185904_a().func_76230_c())) : false;
|
||||
+ return block != Blocks.field_150432_aD && block != Blocks.field_150403_cj ? (iblockstate.func_177230_c().isLeaves(iblockstate, p_176196_1_, p_176196_2_.func_177977_b()) ? true : (block == this && ((Integer)iblockstate.func_177229_b(field_176315_a)).intValue() >= 7 ? true : iblockstate.func_185914_p() && iblockstate.func_185904_a().func_76230_c())) : false;
|
||||
}
|
||||
|
||||
public void func_176204_a(World p_176204_1_, BlockPos p_176204_2_, IBlockState p_176204_3_, Block p_176204_4_)
|
||||
@@ -91,7 +91,6 @@
|
||||
@@ -85,7 +85,6 @@
|
||||
{
|
||||
if (!this.func_176196_c(p_176314_1_, p_176314_2_))
|
||||
{
|
||||
|
@ -17,18 +17,18 @@
|
|||
p_176314_1_.func_175698_g(p_176314_2_);
|
||||
return false;
|
||||
}
|
||||
@@ -103,9 +102,8 @@
|
||||
@@ -97,9 +96,8 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Items.field_151126_ay, ((Integer)p_180657_4_.func_177229_b(field_176315_a)).intValue() + 1, 0));
|
||||
+ super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
+ super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_, p_180657_6_);
|
||||
p_180657_1_.func_175698_g(p_180657_3_);
|
||||
- p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
- p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
}
|
||||
|
||||
public Item func_180660_a(IBlockState p_180660_1_, Random p_180660_2_, int p_180660_3_)
|
||||
@@ -115,14 +113,13 @@
|
||||
@@ -109,14 +107,13 @@
|
||||
|
||||
public int func_149745_a(Random p_149745_1_)
|
||||
{
|
||||
|
@ -44,10 +44,12 @@
|
|||
p_180650_1_.func_175698_g(p_180650_2_);
|
||||
}
|
||||
}
|
||||
@@ -152,4 +149,6 @@
|
||||
{
|
||||
return new BlockState(this, new IProperty[] {field_176315_a});
|
||||
@@ -150,6 +147,8 @@
|
||||
return ((Integer)p_176201_1_.func_177229_b(field_176315_a)).intValue() - 1;
|
||||
}
|
||||
+
|
||||
|
||||
+ @Override public int quantityDropped(IBlockState state, int fortune, Random random){ return ((Integer)state.func_177229_b(field_176315_a)) + 1; }
|
||||
}
|
||||
+
|
||||
protected BlockStateContainer func_180661_e()
|
||||
{
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176315_a});
|
||||
|
|
|
@ -1,22 +1,20 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockStairs.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockStairs.java
|
||||
@@ -68,6 +68,19 @@
|
||||
return false;
|
||||
@@ -443,6 +443,17 @@
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176309_a, field_176308_b, field_176310_M});
|
||||
}
|
||||
|
||||
+ @Override
|
||||
+ public boolean doesSideBlockRendering(IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ {
|
||||
+ if ( func_149662_c() )
|
||||
+ public boolean doesSideBlockRendering(IBlockState state, IBlockAccess world, BlockPos pos, EnumFacing face)
|
||||
+ {
|
||||
+ if ( state.func_185914_p() )
|
||||
+ return true;
|
||||
+
|
||||
+ // face is on the block being rendered, not this block.
|
||||
+ IBlockState iblockstate = world.func_180495_p(pos);
|
||||
+ EnumHalf half = iblockstate.func_177229_b(field_176308_b);
|
||||
+ EnumFacing side = iblockstate.func_177229_b(field_176309_a);
|
||||
+ return side == face.func_176734_d() || (half == EnumHalf.TOP && face == EnumFacing.DOWN) || (half == EnumHalf.BOTTOM && face == EnumFacing.UP);
|
||||
+
|
||||
+ EnumHalf half = state.func_177229_b(field_176308_b);
|
||||
+ EnumFacing side = state.func_177229_b(field_176309_a);
|
||||
+ return side == face || (half == EnumHalf.TOP && face == EnumFacing.UP) || (half == EnumHalf.BOTTOM && face == EnumFacing.DOWN);
|
||||
+ }
|
||||
+
|
||||
public boolean func_149686_d()
|
||||
public static enum EnumHalf implements IStringSerializable
|
||||
{
|
||||
return false;
|
||||
TOP("top"),
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockStaticLiquid.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockStaticLiquid.java
|
||||
@@ -52,7 +52,7 @@
|
||||
{
|
||||
blockpos = blockpos.func_177982_a(p_180650_4_.nextInt(3) - 1, 1, p_180650_4_.nextInt(3) - 1);
|
||||
|
||||
- if (blockpos.func_177956_o() >= 0 && blockpos.func_177956_o() < 256 && !p_180650_1_.func_175667_e(blockpos))
|
||||
+ if (blockpos.func_177956_o() >= 0 && blockpos.func_177956_o() < p_180650_1_.func_72800_K() && !p_180650_1_.func_175667_e(blockpos))
|
||||
{
|
||||
return;
|
||||
}
|
|
@ -1,15 +1,19 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockStem.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockStem.java
|
||||
@@ -94,7 +94,7 @@
|
||||
@@ -89,9 +89,10 @@
|
||||
}
|
||||
|
||||
p_180650_2_ = p_180650_2_.func_177972_a(EnumFacing.Plane.HORIZONTAL.func_179518_a(p_180650_4_));
|
||||
Block block = p_180650_1_.func_180495_p(p_180650_2_.func_177977_b()).func_177230_c();
|
||||
- Block block = p_180650_1_.func_180495_p(p_180650_2_.func_177977_b()).func_177230_c();
|
||||
+ IBlockState soil = p_180650_1_.func_180495_p(p_180650_2_.func_177977_b());
|
||||
+ Block block = soil.func_177230_c();
|
||||
|
||||
- if (p_180650_1_.func_180495_p(p_180650_2_).func_177230_c().field_149764_J == Material.field_151579_a && (block == Blocks.field_150458_ak || block == Blocks.field_150346_d || block == Blocks.field_150349_c))
|
||||
+ if (p_180650_1_.func_175623_d(p_180650_2_) && (block.canSustainPlant(p_180650_1_, p_180650_2_.func_177977_b(), EnumFacing.UP, this) || block == Blocks.field_150346_d || block == Blocks.field_150349_c))
|
||||
+ if (p_180650_1_.func_175623_d(p_180650_2_) && (block.canSustainPlant(soil, p_180650_1_, p_180650_2_.func_177977_b(), EnumFacing.UP, this) || block == Blocks.field_150346_d || block == Blocks.field_150349_c))
|
||||
{
|
||||
p_180650_1_.func_175656_a(p_180650_2_, this.field_149877_a.func_176223_P());
|
||||
}
|
||||
@@ -148,24 +148,29 @@
|
||||
@@ -109,24 +110,29 @@
|
||||
public void func_180653_a(World p_180653_1_, BlockPos p_180653_2_, IBlockState p_180653_3_, float p_180653_4_, int p_180653_5_)
|
||||
{
|
||||
super.func_180653_a(p_180653_1_, p_180653_2_, p_180653_3_, p_180653_4_, p_180653_5_);
|
||||
|
|
|
@ -8,17 +8,17 @@
|
|||
+public class BlockTallGrass extends BlockBush implements IGrowable, net.minecraftforge.common.IShearable
|
||||
{
|
||||
public static final PropertyEnum<BlockTallGrass.EnumType> field_176497_a = PropertyEnum.<BlockTallGrass.EnumType>func_177709_a("type", BlockTallGrass.EnumType.class);
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
protected static final AxisAlignedBB field_185522_c = new AxisAlignedBB(0.09999999403953552D, 0.0D, 0.09999999403953552D, 0.8999999761581421D, 0.800000011920929D, 0.8999999761581421D);
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
public boolean func_180671_f(World p_180671_1_, BlockPos p_180671_2_, IBlockState p_180671_3_)
|
||||
{
|
||||
- return this.func_149854_a(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()).func_177230_c());
|
||||
- return this.func_185514_i(p_180671_1_.func_180495_p(p_180671_2_.func_177977_b()));
|
||||
+ return super.func_180671_f(p_180671_1_, p_180671_2_, p_180671_3_);
|
||||
}
|
||||
|
||||
public boolean func_176200_f(World p_176200_1_, BlockPos p_176200_2_)
|
||||
@@ -53,7 +53,7 @@
|
||||
public boolean func_176200_f(IBlockAccess p_176200_1_, BlockPos p_176200_2_)
|
||||
@@ -51,7 +51,7 @@
|
||||
|
||||
public Item func_180660_a(IBlockState p_180660_1_, Random p_180660_2_, int p_180660_3_)
|
||||
{
|
||||
|
@ -27,21 +27,16 @@
|
|||
}
|
||||
|
||||
public int func_149679_a(int p_149679_1_, Random p_149679_2_)
|
||||
@@ -63,13 +63,7 @@
|
||||
@@ -61,7 +61,7 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_2_.func_71045_bC() != null && p_180657_2_.func_71045_bC().func_77973_b() == Items.field_151097_aZ)
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ)
|
||||
+ if (false && !p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ) // Forge: Noop Taken care of by IShearable
|
||||
{
|
||||
- p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150329_H, 1, ((BlockTallGrass.EnumType)p_180657_4_.func_177229_b(field_176497_a)).func_177044_a()));
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
}
|
||||
}
|
||||
@@ -204,4 +198,22 @@
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150329_H, 1, ((BlockTallGrass.EnumType)p_180657_4_.func_177229_b(field_176497_a)).func_177044_a()));
|
||||
@@ -181,4 +181,22 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -59,7 +54,7 @@
|
|||
+ {
|
||||
+ List<ItemStack> ret = new java.util.ArrayList<ItemStack>();
|
||||
+ if (RANDOM.nextInt(8) != 0) return ret;
|
||||
+ ItemStack seed = net.minecraftforge.common.ForgeHooks.getGrassSeed(RANDOM);
|
||||
+ ItemStack seed = net.minecraftforge.common.ForgeHooks.getGrassSeed(RANDOM, fortune);
|
||||
+ if (seed != null) ret.add(seed);
|
||||
+ return ret;
|
||||
+ }
|
||||
|
|
|
@ -1,15 +1,24 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockTorch.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockTorch.java
|
||||
@@ -63,7 +63,7 @@
|
||||
@@ -79,14 +79,14 @@
|
||||
|
||||
private boolean func_176594_d(World p_176594_1_, BlockPos p_176594_2_)
|
||||
{
|
||||
- if (p_176594_1_.func_180495_p(p_176594_2_).func_185896_q())
|
||||
+ IBlockState state = p_176594_1_.func_180495_p(p_176594_2_);
|
||||
+ if (state.isSideSolid(p_176594_1_, p_176594_2_, EnumFacing.UP))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
Block block = p_176594_1_.func_180495_p(p_176594_2_).func_177230_c();
|
||||
- Block block = p_176594_1_.func_180495_p(p_176594_2_).func_177230_c();
|
||||
- return block instanceof BlockFence || block == Blocks.field_150359_w || block == Blocks.field_150463_bK || block == Blocks.field_150399_cn;
|
||||
+ return block.canPlaceTorchOnTop(p_176594_1_, p_176594_2_);
|
||||
+ return state.func_177230_c().canPlaceTorchOnTop(state, p_176594_1_, p_176594_2_);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
@@ -107,7 +107,7 @@
|
||||
{
|
||||
BlockPos blockpos = p_176595_2_.func_177972_a(p_176595_3_.func_176734_d());
|
||||
boolean flag = p_176595_3_.func_176740_k().func_176722_c();
|
||||
|
@ -18,7 +27,7 @@
|
|||
}
|
||||
|
||||
public IBlockState func_180642_a(World p_180642_1_, BlockPos p_180642_2_, EnumFacing p_180642_3_, float p_180642_4_, float p_180642_5_, float p_180642_6_, int p_180642_7_, EntityLivingBase p_180642_8_)
|
||||
@@ -97,7 +97,7 @@
|
||||
@@ -120,7 +120,7 @@
|
||||
{
|
||||
for (EnumFacing enumfacing : EnumFacing.Plane.HORIZONTAL)
|
||||
{
|
||||
|
@ -27,7 +36,7 @@
|
|||
{
|
||||
return this.func_176223_P().func_177226_a(field_176596_a, enumfacing);
|
||||
}
|
||||
@@ -130,7 +130,7 @@
|
||||
@@ -153,7 +153,7 @@
|
||||
EnumFacing enumfacing1 = enumfacing.func_176734_d();
|
||||
boolean flag = false;
|
||||
|
||||
|
|
|
@ -1,43 +1,21 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockTrapDoor.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockTrapDoor.java
|
||||
@@ -25,6 +25,8 @@
|
||||
|
||||
public class BlockTrapDoor extends Block
|
||||
{
|
||||
+ /** Set this to allow trapdoors to remain free-floating */
|
||||
+ public static boolean disableValidation = false;
|
||||
public static final PropertyDirection field_176284_a = PropertyDirection.func_177712_a("facing", EnumFacing.Plane.HORIZONTAL);
|
||||
public static final PropertyBool field_176283_b = PropertyBool.func_177716_a("open");
|
||||
public static final PropertyEnum<BlockTrapDoor.DoorHalf> field_176285_M = PropertyEnum.<BlockTrapDoor.DoorHalf>func_177709_a("half", BlockTrapDoor.DoorHalf.class);
|
||||
@@ -140,9 +142,10 @@
|
||||
{
|
||||
if (!p_176204_1_.field_72995_K)
|
||||
{
|
||||
+ EnumFacing direction = (EnumFacing)p_176204_3_.func_177229_b(field_176284_a);
|
||||
BlockPos blockpos = p_176204_2_.func_177972_a(((EnumFacing)p_176204_3_.func_177229_b(field_176284_a)).func_176734_d());
|
||||
|
||||
- if (!func_150119_a(p_176204_1_.func_180495_p(blockpos).func_177230_c()))
|
||||
+ if (!(func_150119_a(p_176204_1_.func_180495_p(blockpos).func_177230_c()) || p_176204_1_.isSideSolid(blockpos, direction, true)))
|
||||
{
|
||||
p_176204_1_.func_175698_g(p_176204_2_);
|
||||
this.func_176226_b(p_176204_1_, p_176204_2_, p_176204_3_, 0);
|
||||
@@ -186,7 +189,10 @@
|
||||
|
||||
public boolean func_176198_a(World p_176198_1_, BlockPos p_176198_2_, EnumFacing p_176198_3_)
|
||||
{
|
||||
- return !p_176198_3_.func_176740_k().func_176720_b() && func_150119_a(p_176198_1_.func_180495_p(p_176198_2_.func_177972_a(p_176198_3_.func_176734_d())).func_177230_c());
|
||||
+ if (disableValidation) return true;
|
||||
+ EnumFacing dir = p_176198_3_.func_176734_d();
|
||||
+ p_176198_2_ = p_176198_2_.func_177972_a(dir);
|
||||
+ return !p_176198_3_.func_176740_k().func_176720_b() && (func_150119_a(p_176198_1_.func_180495_p(p_176198_2_).func_177230_c()) || p_176198_1_.isSideSolid(p_176198_2_, p_176198_3_, true));
|
||||
@@ -241,6 +241,18 @@
|
||||
return new BlockStateContainer(this, new IProperty[] {field_176284_a, field_176283_b, field_176285_M});
|
||||
}
|
||||
|
||||
protected static EnumFacing func_176281_b(int p_176281_0_)
|
||||
@@ -223,6 +229,7 @@
|
||||
|
||||
private static boolean func_150119_a(Block p_150119_0_)
|
||||
+ @Override
|
||||
+ public boolean isLadder(IBlockState state, IBlockAccess world, BlockPos pos, EntityLivingBase entity)
|
||||
+ {
|
||||
+ if (state.func_177229_b(field_176283_b))
|
||||
+ {
|
||||
+ IBlockState down = world.func_180495_p(pos.func_177977_b());
|
||||
+ if (down.func_177230_c() == net.minecraft.init.Blocks.field_150468_ap)
|
||||
+ return down.func_177229_b(BlockLadder.field_176382_a) == state.func_177229_b(field_176284_a);
|
||||
+ }
|
||||
+ return false;
|
||||
+ }
|
||||
+
|
||||
public static enum DoorHalf implements IStringSerializable
|
||||
{
|
||||
+ if (disableValidation) return true;
|
||||
return p_150119_0_.field_149764_J.func_76218_k() && p_150119_0_.func_149686_d() || p_150119_0_ == Blocks.field_150426_aN || p_150119_0_ instanceof BlockSlab || p_150119_0_ instanceof BlockStairs;
|
||||
}
|
||||
|
||||
TOP("top"),
|
||||
|
|
|
@ -1,28 +1,28 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockTripWireHook.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockTripWireHook.java
|
||||
@@ -58,14 +58,14 @@
|
||||
@@ -77,14 +77,14 @@
|
||||
|
||||
public boolean func_176198_a(World p_176198_1_, BlockPos p_176198_2_, EnumFacing p_176198_3_)
|
||||
{
|
||||
- return p_176198_3_.func_176740_k().func_176722_c() && p_176198_1_.func_180495_p(p_176198_2_.func_177972_a(p_176198_3_.func_176734_d())).func_177230_c().func_149721_r();
|
||||
+ return p_176198_3_.func_176740_k().func_176722_c() && p_176198_1_.isSideSolid(p_176198_2_.func_177972_a(p_176198_3_.func_176734_d()), p_176198_3_, true);
|
||||
- return p_176198_3_.func_176740_k().func_176722_c() && p_176198_1_.func_180495_p(p_176198_2_.func_177972_a(p_176198_3_.func_176734_d())).func_185915_l();
|
||||
+ return p_176198_3_.func_176740_k().func_176722_c() && p_176198_1_.func_180495_p(p_176198_2_.func_177972_a(p_176198_3_.func_176734_d())).isSideSolid(p_176198_1_, p_176198_2_.func_177972_a(p_176198_3_.func_176734_d()), p_176198_3_);
|
||||
}
|
||||
|
||||
public boolean func_176196_c(World p_176196_1_, BlockPos p_176196_2_)
|
||||
{
|
||||
for (EnumFacing enumfacing : EnumFacing.Plane.HORIZONTAL)
|
||||
{
|
||||
- if (p_176196_1_.func_180495_p(p_176196_2_.func_177972_a(enumfacing)).func_177230_c().func_149721_r())
|
||||
+ if (p_176196_1_.isSideSolid(p_176196_2_.func_177972_a(enumfacing), enumfacing.func_176734_d(), true))
|
||||
- if (p_176196_1_.func_180495_p(p_176196_2_.func_177972_a(enumfacing)).func_185915_l())
|
||||
+ if (p_176196_1_.func_180495_p(p_176196_2_.func_177972_a(enumfacing)).isSideSolid(p_176196_1_, p_176196_2_.func_177972_a(enumfacing), enumfacing.func_176734_d()))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -99,7 +99,7 @@
|
||||
@@ -118,7 +118,7 @@
|
||||
{
|
||||
EnumFacing enumfacing = (EnumFacing)p_176204_3_.func_177229_b(field_176264_a);
|
||||
|
||||
- if (!p_176204_1_.func_180495_p(p_176204_2_.func_177972_a(enumfacing.func_176734_d())).func_177230_c().func_149721_r())
|
||||
+ if (!p_176204_1_.isSideSolid(p_176204_2_.func_177972_a(enumfacing.func_176734_d()), enumfacing, true))
|
||||
- if (!p_176204_1_.func_180495_p(p_176204_2_.func_177972_a(enumfacing.func_176734_d())).func_185915_l())
|
||||
+ if (!p_176204_1_.func_180495_p(p_176204_2_.func_177972_a(enumfacing.func_176734_d())).isSideSolid(p_176204_1_, p_176204_2_.func_177972_a(enumfacing.func_176734_d()), enumfacing))
|
||||
{
|
||||
this.func_176226_b(p_176204_1_, p_176204_2_, p_176204_3_, 0);
|
||||
p_176204_1_.func_175698_g(p_176204_2_);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/BlockVine.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/BlockVine.java
|
||||
@@ -25,7 +25,7 @@
|
||||
@@ -26,7 +26,7 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
|
@ -9,26 +9,21 @@
|
|||
{
|
||||
public static final PropertyBool field_176277_a = PropertyBool.func_177716_a("up");
|
||||
public static final PropertyBool field_176273_b = PropertyBool.func_177716_a("north");
|
||||
@@ -387,13 +387,7 @@
|
||||
@@ -342,7 +342,7 @@
|
||||
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_)
|
||||
public void func_180657_a(World p_180657_1_, EntityPlayer p_180657_2_, BlockPos p_180657_3_, IBlockState p_180657_4_, TileEntity p_180657_5_, ItemStack p_180657_6_)
|
||||
{
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_2_.func_71045_bC() != null && p_180657_2_.func_71045_bC().func_77973_b() == Items.field_151097_aZ)
|
||||
- if (!p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ)
|
||||
+ if (false && !p_180657_1_.field_72995_K && p_180657_6_ != null && p_180657_6_.func_77973_b() == Items.field_151097_aZ) // Forge: Noop, Covered by IShearable
|
||||
{
|
||||
- p_180657_2_.func_71029_a(StatList.field_75934_C[Block.func_149682_b(this)]);
|
||||
- func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150395_bd, 1, 0));
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
super.func_180657_a(p_180657_1_, p_180657_2_, p_180657_3_, p_180657_4_, p_180657_5_);
|
||||
}
|
||||
}
|
||||
@@ -474,4 +468,14 @@
|
||||
p_180657_2_.func_71029_a(StatList.func_188055_a(this));
|
||||
func_180635_a(p_180657_1_, p_180657_3_, new ItemStack(Blocks.field_150395_bd, 1, 0));
|
||||
@@ -457,4 +457,14 @@
|
||||
|
||||
return i;
|
||||
}
|
||||
+ /*************************FORGE START***********************************/
|
||||
+ @Override public boolean isLadder(IBlockAccess world, BlockPos pos, EntityLivingBase entity){ return true; }
|
||||
+ @Override public boolean isLadder(IBlockState state, IBlockAccess world, BlockPos pos, EntityLivingBase entity){ return true; }
|
||||
+ @Override public boolean isShearable(ItemStack item, IBlockAccess world, BlockPos pos){ return true; }
|
||||
+ @Override
|
||||
+ public java.util.List<ItemStack> onSheared(ItemStack item, IBlockAccess world, BlockPos pos, int fortune)
|
||||
|
|
|
@ -1,29 +1,29 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/state/BlockPistonStructureHelper.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/state/BlockPistonStructureHelper.java
|
||||
@@ -78,7 +78,7 @@
|
||||
{
|
||||
Block block = this.field_177261_a.func_180495_p(p_177251_1_).func_177230_c();
|
||||
@@ -80,7 +80,7 @@
|
||||
IBlockState iblockstate = this.field_177261_a.func_180495_p(p_177251_1_);
|
||||
Block block = iblockstate.func_177230_c();
|
||||
|
||||
- if (block.func_149688_o() == Material.field_151579_a)
|
||||
+ if (block.isAir(field_177261_a, p_177251_1_))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151579_a)
|
||||
+ if (iblockstate.func_177230_c().isAir(iblockstate, this.field_177261_a, p_177251_1_))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -109,7 +109,7 @@
|
||||
BlockPos blockpos = p_177251_1_.func_177967_a(this.field_177257_d.func_176734_d(), i);
|
||||
block = this.field_177261_a.func_180495_p(blockpos).func_177230_c();
|
||||
@@ -112,7 +112,7 @@
|
||||
iblockstate = this.field_177261_a.func_180495_p(blockpos);
|
||||
block = iblockstate.func_177230_c();
|
||||
|
||||
- if (block.func_149688_o() == Material.field_151579_a || !BlockPistonBase.func_180696_a(block, this.field_177261_a, blockpos, this.field_177257_d, false) || blockpos.equals(this.field_177259_b))
|
||||
+ if (block.isAir(field_177261_a, blockpos)|| !BlockPistonBase.func_180696_a(block, this.field_177261_a, blockpos, this.field_177257_d, false) || blockpos.equals(this.field_177259_b))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151579_a || !BlockPistonBase.func_185646_a(iblockstate, this.field_177261_a, blockpos, this.field_177257_d, false) || blockpos.equals(this.field_177259_b))
|
||||
+ if (iblockstate.func_177230_c().isAir(iblockstate, this.field_177261_a, blockpos) || !BlockPistonBase.func_185646_a(iblockstate, this.field_177261_a, blockpos, this.field_177257_d, false) || blockpos.equals(this.field_177259_b))
|
||||
{
|
||||
break;
|
||||
}
|
||||
@@ -156,7 +156,7 @@
|
||||
@@ -159,7 +159,7 @@
|
||||
|
||||
block = this.field_177261_a.func_180495_p(blockpos1).func_177230_c();
|
||||
iblockstate = this.field_177261_a.func_180495_p(blockpos1);
|
||||
|
||||
- if (block.func_149688_o() == Material.field_151579_a)
|
||||
+ if (block.isAir(field_177261_a, blockpos1))
|
||||
- if (iblockstate.func_185904_a() == Material.field_151579_a)
|
||||
+ if (iblockstate.func_177230_c().isAir(iblockstate, this.field_177261_a, blockpos1))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -1,53 +0,0 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/state/BlockState.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/state/BlockState.java
|
||||
@@ -38,6 +38,16 @@
|
||||
|
||||
public BlockState(Block p_i45663_1_, IProperty... p_i45663_2_)
|
||||
{
|
||||
+ this(p_i45663_1_, p_i45663_2_, null);
|
||||
+ }
|
||||
+
|
||||
+ protected StateImplementation createState(Block block, ImmutableMap<IProperty, Comparable> properties, ImmutableMap<net.minecraftforge.common.property.IUnlistedProperty<?>, com.google.common.base.Optional<?>> unlistedProperties)
|
||||
+ {
|
||||
+ return new StateImplementation(block, properties);
|
||||
+ }
|
||||
+
|
||||
+ protected BlockState(Block p_i45663_1_, IProperty[] p_i45663_2_, ImmutableMap<net.minecraftforge.common.property.IUnlistedProperty<?>, com.google.common.base.Optional<?>> unlistedProperties)
|
||||
+ {
|
||||
this.field_177627_c = p_i45663_1_;
|
||||
Arrays.sort(p_i45663_2_, new Comparator<IProperty>()
|
||||
{
|
||||
@@ -53,7 +63,7 @@
|
||||
for (List<Comparable> list1 : Cartesian.func_179321_a(this.func_177620_e()))
|
||||
{
|
||||
Map<IProperty, Comparable> map1 = MapPopulator.<IProperty, Comparable>func_179400_b(this.field_177624_d, list1);
|
||||
- BlockState.StateImplementation blockstate$stateimplementation = new BlockState.StateImplementation(p_i45663_1_, ImmutableMap.copyOf(map1));
|
||||
+ BlockState.StateImplementation blockstate$stateimplementation = createState(p_i45663_1_, ImmutableMap.copyOf(map1), unlistedProperties);
|
||||
map.put(map1, blockstate$stateimplementation);
|
||||
list.add(blockstate$stateimplementation);
|
||||
}
|
||||
@@ -132,6 +142,13 @@
|
||||
}
|
||||
}
|
||||
|
||||
+ protected StateImplementation(Block blockIn, ImmutableMap<IProperty, Comparable> propertiesIn, ImmutableTable<IProperty, Comparable, IBlockState> propertyValueTable)
|
||||
+ {
|
||||
+ this.field_177239_a = blockIn;
|
||||
+ this.field_177237_b = propertiesIn;
|
||||
+ this.field_177238_c = propertyValueTable;
|
||||
+ }
|
||||
+
|
||||
public <T extends Comparable<T>, V extends T> IBlockState func_177226_a(IProperty<T> p_177226_1_, V p_177226_2_)
|
||||
{
|
||||
if (!this.field_177237_b.containsKey(p_177226_1_))
|
||||
@@ -199,5 +216,10 @@
|
||||
map.put(p_177236_1_, p_177236_2_);
|
||||
return map;
|
||||
}
|
||||
+
|
||||
+ public ImmutableTable<IProperty, Comparable, IBlockState> getPropertyValueTable()
|
||||
+ {
|
||||
+ return field_177238_c;
|
||||
+ }
|
||||
}
|
||||
}
|
|
@ -1,11 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/state/BlockStateBase.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/state/BlockStateBase.java
|
||||
@@ -67,4 +67,9 @@
|
||||
@@ -71,4 +71,9 @@
|
||||
|
||||
return stringbuilder.toString();
|
||||
}
|
||||
+
|
||||
+ public com.google.common.collect.ImmutableTable<IProperty, Comparable, IBlockState> getPropertyValueTable()
|
||||
+
|
||||
+ public com.google.common.collect.ImmutableTable<IProperty<?>, Comparable<?>, IBlockState> getPropertyValueTable()
|
||||
+ {
|
||||
+ return null;
|
||||
+ }
|
||||
|
|
|
@ -0,0 +1,138 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/state/BlockStateContainer.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/state/BlockStateContainer.java
|
||||
@@ -55,12 +55,22 @@
|
||||
|
||||
public BlockStateContainer(Block p_i45663_1_, IProperty<?>... p_i45663_2_)
|
||||
{
|
||||
- this.field_177627_c = p_i45663_1_;
|
||||
+ this(p_i45663_1_, p_i45663_2_, null);
|
||||
+ }
|
||||
+
|
||||
+ protected StateImplementation createState(Block block, ImmutableMap<IProperty<?>, Comparable<?>> properties, ImmutableMap<net.minecraftforge.common.property.IUnlistedProperty<?>, com.google.common.base.Optional<?>> unlistedProperties)
|
||||
+ {
|
||||
+ return new StateImplementation(block, properties);
|
||||
+ }
|
||||
+
|
||||
+ protected BlockStateContainer(Block blockIn, IProperty<?>[] properties, ImmutableMap<net.minecraftforge.common.property.IUnlistedProperty<?>, com.google.common.base.Optional<?>> unlistedProperties)
|
||||
+ {
|
||||
+ this.field_177627_c = blockIn;
|
||||
Map < String, IProperty<? >> map = Maps. < String, IProperty<? >> newHashMap();
|
||||
|
||||
- for (IProperty<?> iproperty : p_i45663_2_)
|
||||
+ for (IProperty<?> iproperty : properties)
|
||||
{
|
||||
- func_185919_a(p_i45663_1_, iproperty);
|
||||
+ func_185919_a(blockIn, iproperty);
|
||||
map.put(iproperty.func_177701_a(), iproperty);
|
||||
}
|
||||
|
||||
@@ -71,7 +81,7 @@
|
||||
for (List < Comparable<? >> list : Cartesian.func_179321_a(this.func_177620_e()))
|
||||
{
|
||||
Map < IProperty<?>, Comparable<? >> map1 = MapPopulator. < IProperty<?>, Comparable<? >> func_179400_b(this.field_177624_d.values(), list);
|
||||
- BlockStateContainer.StateImplementation blockstatecontainer$stateimplementation = new BlockStateContainer.StateImplementation(p_i45663_1_, ImmutableMap.copyOf(map1));
|
||||
+ BlockStateContainer.StateImplementation blockstatecontainer$stateimplementation = createState(blockIn, ImmutableMap.copyOf(map1), unlistedProperties);
|
||||
map2.put(map1, blockstatecontainer$stateimplementation);
|
||||
list1.add(blockstatecontainer$stateimplementation);
|
||||
}
|
||||
@@ -163,6 +173,13 @@
|
||||
this.field_177237_b = p_i45660_2_;
|
||||
}
|
||||
|
||||
+ protected StateImplementation(Block blockIn, ImmutableMap<IProperty<?>, Comparable<?>> propertiesIn, ImmutableTable<IProperty<?>, Comparable<?>, IBlockState> propertyValueTable)
|
||||
+ {
|
||||
+ this.field_177239_a = blockIn;
|
||||
+ this.field_177237_b = propertiesIn;
|
||||
+ this.field_177238_c = propertyValueTable;
|
||||
+ }
|
||||
+
|
||||
public Collection < IProperty<? >> func_177227_a()
|
||||
{
|
||||
return Collections. < IProperty<? >> unmodifiableCollection(this.field_177237_b.keySet());
|
||||
@@ -414,5 +431,86 @@
|
||||
{
|
||||
return this.field_177239_a.func_185481_k(this);
|
||||
}
|
||||
+
|
||||
+ //Forge Start
|
||||
+ public ImmutableTable<IProperty<?>, Comparable<?>, IBlockState> getPropertyValueTable()
|
||||
+ {
|
||||
+ return field_177238_c;
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public int getLightOpacity(IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return this.field_177239_a.getLightOpacity(this, world, pos);
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public int getLightValue(IBlockAccess world, BlockPos pos)
|
||||
+ {
|
||||
+ return this.field_177239_a.getLightValue(this, world, pos);
|
||||
+ }
|
||||
+
|
||||
+ public boolean isSideSolid(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ {
|
||||
+ return this.field_177239_a.isSideSolid(this, world, pos, side);
|
||||
+ }
|
||||
+
|
||||
+ @Override
|
||||
+ public boolean doesSideBlockRendering(IBlockAccess world, BlockPos pos, EnumFacing side)
|
||||
+ {
|
||||
+ return this.field_177239_a.doesSideBlockRendering(this, world, pos, side);
|
||||
+ }
|
||||
}
|
||||
+
|
||||
+ /**
|
||||
+ * Forge added class to make building things easier.
|
||||
+ * Will return an instance of BlockStateContainer appropriate for
|
||||
+ * the list of properties passed in.
|
||||
+ *
|
||||
+ * Example usage:
|
||||
+ *
|
||||
+ * protected BlockStateContainer createBlockState()
|
||||
+ * {
|
||||
+ * return (new BlockStateContainer.Builder(this)).add(FACING).add(SOME_UNLISTED).build();
|
||||
+ * }
|
||||
+ *
|
||||
+ */
|
||||
+ public static class Builder
|
||||
+ {
|
||||
+ private final Block block;
|
||||
+ private final List<IProperty<?>> listed = Lists.newArrayList();
|
||||
+ private final List<net.minecraftforge.common.property.IUnlistedProperty<?>> unlisted = Lists.newArrayList();
|
||||
+
|
||||
+ public Builder(Block block)
|
||||
+ {
|
||||
+ this.block = block;
|
||||
+ }
|
||||
+
|
||||
+ public Builder add(IProperty<?>... props)
|
||||
+ {
|
||||
+ for (IProperty<?> prop : props)
|
||||
+ this.listed.add(prop);
|
||||
+ return this;
|
||||
+ }
|
||||
+
|
||||
+ public Builder add(net.minecraftforge.common.property.IUnlistedProperty<?>... props)
|
||||
+ {
|
||||
+ for (net.minecraftforge.common.property.IUnlistedProperty<?> prop : props)
|
||||
+ this.unlisted.add(prop);
|
||||
+ return this;
|
||||
+ }
|
||||
+
|
||||
+ public BlockStateContainer build()
|
||||
+ {
|
||||
+ IProperty<?>[] listed = new IProperty[this.listed.size()];
|
||||
+ listed = this.listed.toArray(listed);
|
||||
+ if (this.unlisted.size() == 0)
|
||||
+ return new BlockStateContainer(this.block, listed);
|
||||
+
|
||||
+ net.minecraftforge.common.property.IUnlistedProperty<?>[] unlisted = new net.minecraftforge.common.property.IUnlistedProperty[this.unlisted.size()];
|
||||
+ unlisted = this.unlisted.toArray(unlisted);
|
||||
+
|
||||
+ return new net.minecraftforge.common.property.ExtendedBlockState(this.block, listed, unlisted);
|
||||
+ }
|
||||
+ }
|
||||
}
|
|
@ -0,0 +1,27 @@
|
|||
--- ../src-base/minecraft/net/minecraft/block/state/IBlockProperties.java
|
||||
+++ ../src-work/minecraft/net/minecraft/block/state/IBlockProperties.java
|
||||
@@ -25,9 +25,13 @@
|
||||
|
||||
boolean func_185913_b();
|
||||
|
||||
+ @Deprecated //Forge location aware version below
|
||||
int func_185891_c();
|
||||
+ int getLightOpacity(IBlockAccess world, BlockPos pos);
|
||||
|
||||
+ @Deprecated //Forge location aware version below
|
||||
int func_185906_d();
|
||||
+ int getLightValue(IBlockAccess world, BlockPos pos);
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
boolean func_185895_e();
|
||||
@@ -88,5 +92,10 @@
|
||||
|
||||
RayTraceResult func_185910_a(World p_185910_1_, BlockPos p_185910_2_, Vec3d p_185910_3_, Vec3d p_185910_4_);
|
||||
|
||||
+ @Deprecated // Forge: Use isSideSolid(IBlockAccess, BlockPos, EnumFacing.UP) instead
|
||||
boolean func_185896_q();
|
||||
+
|
||||
+ //Forge added functions
|
||||
+ boolean doesSideBlockRendering(IBlockAccess world, BlockPos pos, EnumFacing side);
|
||||
+ boolean isSideSolid(IBlockAccess world, BlockPos pos, EnumFacing side);
|
||||
}
|
|
@ -9,10 +9,10 @@
|
|||
+ if (!net.minecraftforge.fml.client.FMLClientHandler.instance().handleLoadingScreen(scaledresolution)) //FML Don't render while FML's pre-screen is rendering
|
||||
+ {
|
||||
Tessellator tessellator = Tessellator.func_178181_a();
|
||||
WorldRenderer worldrenderer = tessellator.func_178180_c();
|
||||
VertexBuffer vertexbuffer = tessellator.func_178180_c();
|
||||
this.field_73725_b.func_110434_K().func_110577_a(Gui.field_110325_k);
|
||||
@@ -174,6 +178,12 @@
|
||||
GlStateManager.func_179120_a(770, 771, 1, 0);
|
||||
GlStateManager.func_187428_a(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA, GlStateManager.SourceFactor.ONE, GlStateManager.DestFactor.ZERO);
|
||||
this.field_73725_b.field_71466_p.func_175063_a(this.field_73726_c, (float)((k - this.field_73725_b.field_71466_p.func_78256_a(this.field_73726_c)) / 2), (float)(l / 2 - 4 - 16), 16777215);
|
||||
this.field_73725_b.field_71466_p.func_175063_a(this.field_73727_a, (float)((k - this.field_73725_b.field_71466_p.func_78256_a(this.field_73727_a)) / 2), (float)(l / 2 - 4 + 8), 16777215);
|
||||
+ }
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/Minecraft.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/Minecraft.java
|
||||
@@ -301,7 +301,6 @@
|
||||
this.field_152355_az = (new YggdrasilAuthenticationService(p_i45547_1_.field_178745_a.field_178751_c, UUID.randomUUID().toString())).createMinecraftSessionService();
|
||||
@@ -318,7 +318,6 @@
|
||||
this.field_152355_az = (new YggdrasilAuthenticationService(this.field_110453_aa, UUID.randomUUID().toString())).createMinecraftSessionService();
|
||||
this.field_71449_j = p_i45547_1_.field_178745_a.field_178752_a;
|
||||
field_147123_G.info("Setting user: " + this.field_71449_j.func_111285_a());
|
||||
- field_147123_G.info("(Session ID is " + this.field_71449_j.func_111286_b() + ")");
|
||||
this.field_71459_aj = p_i45547_1_.field_178741_d.field_178756_a;
|
||||
this.field_71443_c = p_i45547_1_.field_178743_b.field_178764_a > 0 ? p_i45547_1_.field_178743_b.field_178764_a : 1;
|
||||
this.field_71440_d = p_i45547_1_.field_178743_b.field_178762_b > 0 ? p_i45547_1_.field_178743_b.field_178762_b : 1;
|
||||
@@ -415,10 +414,10 @@
|
||||
@@ -432,10 +431,10 @@
|
||||
this.field_110451_am = new SimpleReloadableResourceManager(this.field_110452_an);
|
||||
this.field_135017_as = new LanguageManager(this.field_110452_an, this.field_71474_y.field_74363_ab);
|
||||
this.field_110451_am.func_110542_a(this.field_135017_as);
|
||||
|
@ -18,10 +18,19 @@
|
|||
this.field_110451_am.func_110542_a(this.field_71446_o);
|
||||
- this.func_180510_a(this.field_71446_o);
|
||||
+ net.minecraftforge.fml.client.SplashProgress.drawVanillaScreen(this.field_71446_o);
|
||||
this.func_175595_al();
|
||||
this.field_152350_aA = new SkinManager(this.field_71446_o, new File(this.field_110446_Y, "skins"), this.field_152355_az);
|
||||
this.field_71469_aa = new AnvilSaveConverter(new File(this.field_71412_D, "saves"));
|
||||
@@ -453,6 +452,8 @@
|
||||
this.field_71469_aa = new AnvilSaveConverter(new File(this.field_71412_D, "saves"), this.field_184131_U);
|
||||
this.field_147127_av = new SoundHandler(this.field_110451_am, this.field_71474_y);
|
||||
@@ -460,7 +459,7 @@
|
||||
{
|
||||
try
|
||||
{
|
||||
- return String.format(p_74535_1_, new Object[] {GameSettings.func_74298_c(Minecraft.this.field_71474_y.field_151445_Q.func_151463_i())});
|
||||
+ return String.format(p_74535_1_, new Object[] {Minecraft.this.field_71474_y.field_151445_Q.getDisplayName()});
|
||||
}
|
||||
catch (Exception exception)
|
||||
{
|
||||
@@ -469,6 +468,8 @@
|
||||
}
|
||||
});
|
||||
this.field_71417_B = new MouseHelper();
|
||||
|
@ -30,13 +39,13 @@
|
|||
this.func_71361_d("Pre startup");
|
||||
GlStateManager.func_179098_w();
|
||||
GlStateManager.func_179103_j(7425);
|
||||
@@ -466,17 +467,21 @@
|
||||
@@ -482,19 +483,23 @@
|
||||
GlStateManager.func_179096_D();
|
||||
GlStateManager.func_179128_n(5888);
|
||||
this.func_71361_d("Startup");
|
||||
- this.field_147128_au = new TextureMap("textures");
|
||||
+ bar.step("Loading Texture Map");
|
||||
+ this.field_147128_au = new TextureMap("textures",true);
|
||||
+ this.field_147128_au = new TextureMap("textures", true);
|
||||
this.field_147128_au.func_147633_a(this.field_71474_y.field_151442_I);
|
||||
this.field_71446_o.func_110580_a(TextureMap.field_110575_b, this.field_147128_au);
|
||||
this.field_71446_o.func_110577_a(TextureMap.field_110575_b);
|
||||
|
@ -44,16 +53,18 @@
|
|||
+ bar.step("Loading Model Manager");
|
||||
this.field_175617_aL = new ModelManager(this.field_147128_au);
|
||||
this.field_110451_am.func_110542_a(this.field_175617_aL);
|
||||
this.field_184127_aH = BlockColors.func_186723_a();
|
||||
this.field_184128_aI = ItemColors.func_186729_a(this.field_184127_aH);
|
||||
+ bar.step("Loading Item Renderer");
|
||||
this.field_175621_X = new RenderItem(this.field_71446_o, this.field_175617_aL);
|
||||
this.field_175621_X = new RenderItem(this.field_71446_o, this.field_175617_aL, this.field_184128_aI);
|
||||
this.field_175616_W = new RenderManager(this.field_71446_o, this.field_175621_X);
|
||||
this.field_175620_Y = new ItemRenderer(this);
|
||||
this.field_110451_am.func_110542_a(this.field_175621_X);
|
||||
+ bar.step("Loading Entity Renderer");
|
||||
this.field_71460_t = new EntityRenderer(this, this.field_110451_am);
|
||||
this.field_110451_am.func_110542_a(this.field_71460_t);
|
||||
this.field_175618_aM = new BlockRendererDispatcher(this.field_175617_aL.func_174954_c(), this.field_71474_y);
|
||||
@@ -486,22 +491,25 @@
|
||||
this.field_175618_aM = new BlockRendererDispatcher(this.field_175617_aL.func_174954_c(), this.field_184127_aH);
|
||||
@@ -504,23 +509,26 @@
|
||||
this.field_71458_u = new GuiAchievement(this);
|
||||
GlStateManager.func_179083_b(0, 0, this.field_71443_c, this.field_71440_d);
|
||||
this.field_71452_i = new EffectRenderer(this.field_71441_e, this.field_71446_o);
|
||||
|
@ -77,12 +88,13 @@
|
|||
+ net.minecraftforge.fml.client.SplashProgress.clearVanillaResources(field_71446_o, field_152354_ay);
|
||||
this.field_152354_ay = null;
|
||||
this.field_71461_s = new LoadingScreenRenderer(this);
|
||||
this.field_184132_p = new DebugRenderer(this);
|
||||
|
||||
+ net.minecraftforge.fml.client.FMLClientHandler.instance().onInitializationComplete();
|
||||
if (this.field_71474_y.field_74353_u && !this.field_71431_Q)
|
||||
{
|
||||
this.func_71352_k();
|
||||
@@ -681,21 +689,23 @@
|
||||
@@ -692,21 +700,23 @@
|
||||
File file2 = new File(file1, "crash-" + (new SimpleDateFormat("yyyy-MM-dd_HH.mm.ss")).format(new Date()) + "-client.txt");
|
||||
Bootstrap.func_179870_a(p_71377_1_.func_71502_e());
|
||||
|
||||
|
@ -109,7 +121,7 @@
|
|||
}
|
||||
|
||||
public boolean func_152349_b()
|
||||
@@ -883,11 +893,6 @@
|
||||
@@ -899,11 +909,6 @@
|
||||
|
||||
public void func_147108_a(GuiScreen p_147108_1_)
|
||||
{
|
||||
|
@ -121,8 +133,8 @@
|
|||
if (p_147108_1_ == null && this.field_71441_e == null)
|
||||
{
|
||||
p_147108_1_ = new GuiMainMenu();
|
||||
@@ -897,6 +902,17 @@
|
||||
p_147108_1_ = new GuiGameOver();
|
||||
@@ -913,6 +918,17 @@
|
||||
p_147108_1_ = new GuiGameOver((ITextComponent)null);
|
||||
}
|
||||
|
||||
+ GuiScreen old = this.field_71462_r;
|
||||
|
@ -130,16 +142,16 @@
|
|||
+
|
||||
+ if (net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(event)) return;
|
||||
+
|
||||
+ p_147108_1_ = event.gui;
|
||||
+ p_147108_1_ = event.getGui();
|
||||
+ if (old != null && p_147108_1_ != old)
|
||||
+ {
|
||||
+ old.func_146281_b();
|
||||
+ }
|
||||
+
|
||||
if (p_147108_1_ instanceof GuiMainMenu)
|
||||
if (p_147108_1_ instanceof GuiMainMenu || p_147108_1_ instanceof GuiMultiplayer)
|
||||
{
|
||||
this.field_71474_y.field_74330_P = false;
|
||||
@@ -1030,9 +1046,11 @@
|
||||
@@ -1051,9 +1067,11 @@
|
||||
|
||||
if (!this.field_71454_w)
|
||||
{
|
||||
|
@ -151,47 +163,46 @@
|
|||
}
|
||||
|
||||
this.field_71424_I.func_76319_b();
|
||||
@@ -1377,7 +1395,7 @@
|
||||
@@ -1393,9 +1411,9 @@
|
||||
{
|
||||
BlockPos blockpos = this.field_71476_x.func_178782_a();
|
||||
|
||||
if (this.field_71441_e.func_180495_p(blockpos).func_177230_c().func_149688_o() != Material.field_151579_a && this.field_71442_b.func_180512_c(blockpos, this.field_71476_x.field_178784_b))
|
||||
- if (this.field_71441_e.func_180495_p(blockpos).func_185904_a() != Material.field_151579_a && this.field_71442_b.func_180512_c(blockpos, this.field_71476_x.field_178784_b))
|
||||
+ if (!this.field_71441_e.func_175623_d(blockpos) && this.field_71442_b.func_180512_c(blockpos, this.field_71476_x.field_178784_b))
|
||||
{
|
||||
- this.field_71452_i.func_180532_a(blockpos, this.field_71476_x.field_178784_b);
|
||||
+ this.field_71452_i.addBlockHitEffects(blockpos, this.field_71476_x);
|
||||
this.field_71439_g.func_71038_i();
|
||||
this.field_71439_g.func_184609_a(EnumHand.MAIN_HAND);
|
||||
}
|
||||
}
|
||||
@@ -1463,15 +1481,19 @@
|
||||
@@ -1429,7 +1447,7 @@
|
||||
case BLOCK:
|
||||
BlockPos blockpos = this.field_71476_x.func_178782_a();
|
||||
|
||||
- if (this.field_71441_e.func_180495_p(blockpos).func_177230_c().func_149688_o() != Material.field_151579_a)
|
||||
- if (this.field_71441_e.func_180495_p(blockpos).func_185904_a() != Material.field_151579_a)
|
||||
+ if (!this.field_71441_e.func_175623_d(blockpos))
|
||||
{
|
||||
int i = itemstack != null ? itemstack.field_77994_a : 0;
|
||||
this.field_71442_b.func_180511_b(blockpos, this.field_71476_x.field_178784_b);
|
||||
break;
|
||||
@@ -1473,7 +1491,7 @@
|
||||
switch (this.field_71476_x.field_72313_a)
|
||||
{
|
||||
case ENTITY:
|
||||
-
|
||||
+ if(!net.minecraftforge.common.ForgeHooks.onInteractEntityAt(field_71439_g, field_71476_x.field_72308_g, field_71476_x, field_71439_g.func_184586_b(enumhand), enumhand))
|
||||
if (this.field_71442_b.func_187102_a(this.field_71439_g, this.field_71476_x.field_72308_g, this.field_71476_x, this.field_71439_g.func_184586_b(enumhand), enumhand) == EnumActionResult.SUCCESS)
|
||||
{
|
||||
return;
|
||||
@@ -1516,7 +1534,7 @@
|
||||
}
|
||||
|
||||
+
|
||||
+ boolean result = !net.minecraftforge.event.ForgeEventFactory.onPlayerInteract(field_71439_g, net.minecraftforge.event.entity.player.PlayerInteractEvent.Action.RIGHT_CLICK_BLOCK, this.field_71441_e, blockpos, this.field_71476_x.field_178784_b, this.field_71476_x.field_72307_f).isCanceled();
|
||||
+ if (result) { //Forge: Kept separate to simplify patch
|
||||
if (this.field_71442_b.func_178890_a(this.field_71439_g, this.field_71441_e, itemstack, blockpos, this.field_71476_x.field_178784_b, this.field_71476_x.field_72307_f))
|
||||
{
|
||||
flag = false;
|
||||
this.field_71439_g.func_71038_i();
|
||||
}
|
||||
+ }
|
||||
|
||||
if (itemstack == null)
|
||||
{
|
||||
@@ -1494,7 +1516,8 @@
|
||||
{
|
||||
ItemStack itemstack1 = this.field_71439_g.field_71071_by.func_70448_g();
|
||||
|
||||
- if (itemstack1 != null && this.field_71442_b.func_78769_a(this.field_71439_g, this.field_71441_e, itemstack1))
|
||||
+ boolean result = !net.minecraftforge.event.ForgeEventFactory.onPlayerInteract(field_71439_g, net.minecraftforge.event.entity.player.PlayerInteractEvent.Action.RIGHT_CLICK_AIR, field_71441_e, null, null, null).isCanceled();
|
||||
+ if (result && itemstack1 != null && this.field_71442_b.func_78769_a(this.field_71439_g, this.field_71441_e, itemstack1))
|
||||
{
|
||||
this.field_71460_t.field_78516_c.func_78445_c();
|
||||
}
|
||||
@@ -1598,6 +1621,8 @@
|
||||
ItemStack itemstack1 = this.field_71439_g.func_184586_b(enumhand);
|
||||
-
|
||||
+ if (itemstack1 == null) net.minecraftforge.common.ForgeHooks.onEmptyClick(this.field_71439_g, enumhand);
|
||||
if (itemstack1 != null && this.field_71442_b.func_187101_a(this.field_71439_g, this.field_71441_e, itemstack1, enumhand) == EnumActionResult.SUCCESS)
|
||||
{
|
||||
this.field_71460_t.field_78516_c.func_187460_a(enumhand);
|
||||
@@ -1623,6 +1641,8 @@
|
||||
--this.field_71467_ac;
|
||||
}
|
||||
|
||||
|
@ -200,40 +211,40 @@
|
|||
this.field_71424_I.func_76320_a("gui");
|
||||
|
||||
if (!this.field_71445_n)
|
||||
@@ -1690,6 +1715,8 @@
|
||||
|
||||
while (Mouse.next())
|
||||
{
|
||||
+ if (net.minecraftforge.client.ForgeHooksClient.postMouseEvent()) continue;
|
||||
+
|
||||
int i = Mouse.getEventButton();
|
||||
KeyBinding.func_74510_a(i - 100, Mouse.getEventButtonState());
|
||||
|
||||
@@ -1745,6 +1772,7 @@
|
||||
this.field_71462_r.func_146274_d();
|
||||
}
|
||||
@@ -1734,6 +1754,7 @@
|
||||
this.field_71457_ai = 0;
|
||||
this.field_71441_e.func_72897_h(this.field_71439_g);
|
||||
}
|
||||
+ net.minecraftforge.fml.common.FMLCommonHandler.instance().fireMouseInput();
|
||||
}
|
||||
|
||||
if (this.field_71429_W > 0)
|
||||
@@ -1923,6 +1951,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
+ net.minecraftforge.fml.common.FMLCommonHandler.instance().fireKeyInput();
|
||||
}
|
||||
|
||||
for (int l = 0; l < 9; ++l)
|
||||
@@ -2119,12 +2148,15 @@
|
||||
this.field_71424_I.func_76318_c("gameRenderer");
|
||||
@@ -1821,6 +1842,7 @@
|
||||
this.field_71453_ak.func_74428_b();
|
||||
}
|
||||
|
||||
+ net.minecraftforge.fml.common.FMLCommonHandler.instance().onPostClientTick();
|
||||
+
|
||||
this.field_71424_I.func_76319_b();
|
||||
this.field_71423_H = func_71386_F();
|
||||
}
|
||||
@@ -1927,6 +1949,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
+ net.minecraftforge.fml.common.FMLCommonHandler.instance().fireKeyInput();
|
||||
}
|
||||
|
||||
this.func_184117_aA();
|
||||
@@ -2166,6 +2189,8 @@
|
||||
{
|
||||
while (Mouse.next())
|
||||
{
|
||||
+ if (net.minecraftforge.client.ForgeHooksClient.postMouseEvent()) continue;
|
||||
+
|
||||
int i = Mouse.getEventButton();
|
||||
KeyBinding.func_74510_a(i - 100, Mouse.getEventButtonState());
|
||||
|
||||
@@ -2231,6 +2256,7 @@
|
||||
|
||||
public void func_71371_a(String p_71371_1_, String p_71371_2_, WorldSettings p_71371_3_)
|
||||
{
|
||||
|
@ -241,7 +252,7 @@
|
|||
this.func_71403_a((WorldClient)null);
|
||||
System.gc();
|
||||
ISaveHandler isavehandler = this.field_71469_aa.func_75804_a(p_71371_1_, false);
|
||||
@@ -2160,6 +2192,12 @@
|
||||
@@ -2273,6 +2299,12 @@
|
||||
|
||||
while (!this.field_71437_Z.func_71200_ad())
|
||||
{
|
||||
|
@ -254,24 +265,24 @@
|
|||
String s = this.field_71437_Z.func_71195_b_();
|
||||
|
||||
if (s != null)
|
||||
@@ -2185,8 +2223,14 @@
|
||||
@@ -2298,8 +2330,14 @@
|
||||
SocketAddress socketaddress = this.field_71437_Z.func_147137_ag().func_151270_a();
|
||||
NetworkManager networkmanager = NetworkManager.func_150722_a(socketaddress);
|
||||
networkmanager.func_150719_a(new NetHandlerLoginClient(networkmanager, this, (GuiScreen)null));
|
||||
- networkmanager.func_179290_a(new C00Handshake(47, socketaddress.toString(), 0, EnumConnectionState.LOGIN));
|
||||
- networkmanager.func_179290_a(new C00PacketLoginStart(this.func_110432_I().func_148256_e()));
|
||||
+ networkmanager.func_179290_a(new C00Handshake(47, socketaddress.toString(), 0, EnumConnectionState.LOGIN, true));
|
||||
- networkmanager.func_179290_a(new C00Handshake(107, socketaddress.toString(), 0, EnumConnectionState.LOGIN));
|
||||
- networkmanager.func_179290_a(new CPacketLoginStart(this.func_110432_I().func_148256_e()));
|
||||
+ networkmanager.func_179290_a(new C00Handshake(107, socketaddress.toString(), 0, EnumConnectionState.LOGIN, true));
|
||||
+ com.mojang.authlib.GameProfile gameProfile = this.func_110432_I().func_148256_e();
|
||||
+ if (!this.func_110432_I().hasCachedProperties())
|
||||
+ {
|
||||
+ gameProfile = field_152355_az.fillProfileProperties(gameProfile, true); //Forge: Fill profile properties upon game load. Fixes MC-52974.
|
||||
+ this.func_110432_I().setProperties(gameProfile.getProperties());
|
||||
+ }
|
||||
+ networkmanager.func_179290_a(new C00PacketLoginStart(gameProfile));
|
||||
+ networkmanager.func_179290_a(new CPacketLoginStart(gameProfile));
|
||||
this.field_71453_ak = networkmanager;
|
||||
}
|
||||
|
||||
@@ -2197,6 +2241,8 @@
|
||||
@@ -2310,6 +2348,8 @@
|
||||
|
||||
public void func_71353_a(WorldClient p_71353_1_, String p_71353_2_)
|
||||
{
|
||||
|
@ -280,10 +291,10 @@
|
|||
if (p_71353_1_ == null)
|
||||
{
|
||||
NetHandlerPlayClient nethandlerplayclient = this.func_147114_u();
|
||||
@@ -2210,6 +2256,18 @@
|
||||
@@ -2322,6 +2362,18 @@
|
||||
if (this.field_71437_Z != null && this.field_71437_Z.func_175578_N())
|
||||
{
|
||||
this.field_71437_Z.func_71263_m();
|
||||
this.field_71437_Z.func_175592_a();
|
||||
+ if (field_71461_s != null)
|
||||
+ {
|
||||
+ this.field_71461_s.func_73719_c(I18n.func_135052_a("forge.client.shutdown.internal"));
|
||||
|
@ -299,7 +310,7 @@
|
|||
}
|
||||
|
||||
this.field_71437_Z = null;
|
||||
@@ -2232,6 +2290,7 @@
|
||||
@@ -2345,6 +2397,7 @@
|
||||
this.field_71456_v.func_181029_i();
|
||||
this.func_71351_a((ServerData)null);
|
||||
this.field_71455_al = false;
|
||||
|
@ -307,77 +318,72 @@
|
|||
}
|
||||
|
||||
this.field_147127_av.func_147690_c();
|
||||
@@ -2336,126 +2395,10 @@
|
||||
if (this.field_71476_x != null)
|
||||
@@ -2461,159 +2514,8 @@
|
||||
{
|
||||
if (this.field_71476_x != null && this.field_71476_x.field_72313_a != RayTraceResult.Type.MISS)
|
||||
{
|
||||
boolean flag = this.field_71439_g.field_71075_bZ.field_75098_d;
|
||||
- int i = 0;
|
||||
- boolean flag1 = false;
|
||||
- boolean flag = this.field_71439_g.field_71075_bZ.field_75098_d;
|
||||
- TileEntity tileentity = null;
|
||||
- Item item;
|
||||
- ItemStack itemstack;
|
||||
-
|
||||
- if (this.field_71476_x.field_72313_a == MovingObjectPosition.MovingObjectType.BLOCK)
|
||||
- if (this.field_71476_x.field_72313_a == RayTraceResult.Type.BLOCK)
|
||||
- {
|
||||
- BlockPos blockpos = this.field_71476_x.func_178782_a();
|
||||
- Block block = this.field_71441_e.func_180495_p(blockpos).func_177230_c();
|
||||
- IBlockState iblockstate = this.field_71441_e.func_180495_p(blockpos);
|
||||
- Block block = iblockstate.func_177230_c();
|
||||
-
|
||||
- if (block.func_149688_o() == Material.field_151579_a)
|
||||
- if (iblockstate.func_185904_a() == Material.field_151579_a)
|
||||
- {
|
||||
- return;
|
||||
- }
|
||||
-
|
||||
- item = block.func_180665_b(this.field_71441_e, blockpos);
|
||||
- itemstack = block.func_185473_a(this.field_71441_e, blockpos, iblockstate);
|
||||
-
|
||||
- if (item == null)
|
||||
- if (itemstack == null)
|
||||
- {
|
||||
- return;
|
||||
- }
|
||||
-
|
||||
- if (flag && GuiScreen.func_146271_m())
|
||||
- if (flag && GuiScreen.func_146271_m() && block.func_149716_u())
|
||||
- {
|
||||
- tileentity = this.field_71441_e.func_175625_s(blockpos);
|
||||
- }
|
||||
-
|
||||
- Block block1 = item instanceof ItemBlock && !block.func_149648_K() ? Block.func_149634_a(item) : block;
|
||||
- i = block1.func_176222_j(this.field_71441_e, blockpos);
|
||||
- flag1 = item.func_77614_k();
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- if (this.field_71476_x.field_72313_a != MovingObjectPosition.MovingObjectType.ENTITY || this.field_71476_x.field_72308_g == null || !flag)
|
||||
- if (this.field_71476_x.field_72313_a != RayTraceResult.Type.ENTITY || this.field_71476_x.field_72308_g == null || !flag)
|
||||
- {
|
||||
- return;
|
||||
- }
|
||||
-
|
||||
- if (this.field_71476_x.field_72308_g instanceof EntityPainting)
|
||||
- {
|
||||
- item = Items.field_151159_an;
|
||||
- itemstack = new ItemStack(Items.field_151159_an);
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityLeashKnot)
|
||||
- {
|
||||
- item = Items.field_151058_ca;
|
||||
- itemstack = new ItemStack(Items.field_151058_ca);
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityItemFrame)
|
||||
- {
|
||||
- EntityItemFrame entityitemframe = (EntityItemFrame)this.field_71476_x.field_72308_g;
|
||||
- ItemStack itemstack = entityitemframe.func_82335_i();
|
||||
- ItemStack itemstack1 = entityitemframe.func_82335_i();
|
||||
-
|
||||
- if (itemstack == null)
|
||||
- if (itemstack1 == null)
|
||||
- {
|
||||
- item = Items.field_151160_bD;
|
||||
- itemstack = new ItemStack(Items.field_151160_bD);
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- item = itemstack.func_77973_b();
|
||||
- i = itemstack.func_77960_j();
|
||||
- flag1 = true;
|
||||
- itemstack = ItemStack.func_77944_b(itemstack1);
|
||||
- }
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityMinecart)
|
||||
- {
|
||||
- EntityMinecart entityminecart = (EntityMinecart)this.field_71476_x.field_72308_g;
|
||||
- Item item;
|
||||
-
|
||||
- switch (entityminecart.func_180456_s())
|
||||
- switch (entityminecart.func_184264_v())
|
||||
- {
|
||||
- case FURNACE:
|
||||
- item = Items.field_151109_aJ;
|
||||
|
@ -397,53 +403,91 @@
|
|||
- default:
|
||||
- item = Items.field_151143_au;
|
||||
- }
|
||||
-
|
||||
- itemstack = new ItemStack(item);
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityBoat)
|
||||
- {
|
||||
- item = Items.field_151124_az;
|
||||
- itemstack = new ItemStack(((EntityBoat)this.field_71476_x.field_72308_g).func_184455_j());
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityArmorStand)
|
||||
- {
|
||||
- item = Items.field_179565_cj;
|
||||
- itemstack = new ItemStack(Items.field_179565_cj);
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72308_g instanceof EntityEnderCrystal)
|
||||
- {
|
||||
- itemstack = new ItemStack(Items.field_185158_cP);
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- item = Items.field_151063_bx;
|
||||
- i = EntityList.func_75619_a(this.field_71476_x.field_72308_g);
|
||||
- flag1 = true;
|
||||
- String s = EntityList.func_75621_b(this.field_71476_x.field_72308_g);
|
||||
-
|
||||
- if (!EntityList.field_75627_a.containsKey(Integer.valueOf(i)))
|
||||
- if (!EntityList.field_75627_a.containsKey(s))
|
||||
- {
|
||||
- return;
|
||||
- }
|
||||
-
|
||||
- itemstack = new ItemStack(Items.field_151063_bx);
|
||||
- ItemMonsterPlacer.func_185078_a(itemstack, s);
|
||||
- }
|
||||
- }
|
||||
-
|
||||
InventoryPlayer inventoryplayer = this.field_71439_g.field_71071_by;
|
||||
|
||||
- if (tileentity == null)
|
||||
- if (itemstack.func_77973_b() == null)
|
||||
- {
|
||||
- inventoryplayer.func_146030_a(item, i, flag1, flag);
|
||||
- String s1 = "";
|
||||
-
|
||||
- if (this.field_71476_x.field_72313_a == RayTraceResult.Type.BLOCK)
|
||||
- {
|
||||
- s1 = ((ResourceLocation)Block.field_149771_c.func_177774_c(this.field_71441_e.func_180495_p(this.field_71476_x.func_178782_a()).func_177230_c())).toString();
|
||||
- }
|
||||
- else if (this.field_71476_x.field_72313_a == RayTraceResult.Type.ENTITY)
|
||||
- {
|
||||
- s1 = EntityList.func_75621_b(this.field_71476_x.field_72308_g);
|
||||
- }
|
||||
-
|
||||
- field_147123_G.warn("Picking on: [{}] {} gave null item", new Object[] {this.field_71476_x.field_72313_a, s1});
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- ItemStack itemstack1 = this.func_181036_a(item, i, tileentity);
|
||||
- inventoryplayer.func_70299_a(inventoryplayer.field_70461_c, itemstack1);
|
||||
- }
|
||||
- InventoryPlayer inventoryplayer = this.field_71439_g.field_71071_by;
|
||||
-
|
||||
+ if (!net.minecraftforge.common.ForgeHooks.onPickBlock(this.field_71476_x, this.field_71439_g, this.field_71441_e)) return;
|
||||
- if (tileentity != null)
|
||||
- {
|
||||
- this.func_184119_a(itemstack, tileentity);
|
||||
- }
|
||||
-
|
||||
- int i = inventoryplayer.func_184429_b(itemstack);
|
||||
-
|
||||
- if (flag)
|
||||
- {
|
||||
- inventoryplayer.func_184434_a(itemstack);
|
||||
- this.field_71442_b.func_78761_a(this.field_71439_g.func_184586_b(EnumHand.MAIN_HAND), 36 + inventoryplayer.field_70461_c);
|
||||
- }
|
||||
- else if (i != -1)
|
||||
- {
|
||||
- if (InventoryPlayer.func_184435_e(i))
|
||||
- {
|
||||
- inventoryplayer.field_70461_c = i;
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- this.field_71442_b.func_187100_a(i);
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
+ net.minecraftforge.common.ForgeHooks.onPickBlock(this.field_71476_x, this.field_71439_g, this.field_71441_e);
|
||||
+ // We delete this code wholly instead of commenting it out, to make sure we detect changes in it between MC versions
|
||||
if (flag)
|
||||
{
|
||||
int j = this.field_71439_g.field_71069_bz.field_75151_b.size() - 9 + inventoryplayer.field_70461_c;
|
||||
@@ -2756,18 +2699,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2909,18 +2811,8 @@
|
||||
|
||||
public static int func_71369_N()
|
||||
{
|
||||
- for (int i = 16384; i > 0; i >>= 1)
|
||||
- {
|
||||
- GL11.glTexImage2D(GL11.GL_PROXY_TEXTURE_2D, 0, GL11.GL_RGBA, i, i, 0, GL11.GL_RGBA, GL11.GL_UNSIGNED_BYTE, (ByteBuffer)((ByteBuffer)null));
|
||||
- int j = GL11.glGetTexLevelParameteri(GL11.GL_PROXY_TEXTURE_2D, 0, GL11.GL_TEXTURE_WIDTH);
|
||||
- GlStateManager.func_187419_a(32868, 0, 6408, i, i, 0, 6408, 5121, (IntBuffer)null);
|
||||
- int j = GlStateManager.func_187411_c(32868, 0, 4096);
|
||||
-
|
||||
- if (j != 0)
|
||||
- {
|
||||
|
@ -457,15 +501,33 @@
|
|||
}
|
||||
|
||||
public boolean func_70002_Q()
|
||||
@@ -2924,9 +2857,9 @@
|
||||
{
|
||||
this.func_147108_a(new GuiYesNo(new GuiYesNoCallback()
|
||||
{
|
||||
- public void func_73878_a(boolean p_73878_1_, int p_73878_2_)
|
||||
+ public void func_73878_a(boolean result, int id)
|
||||
{
|
||||
- if (p_73878_1_)
|
||||
+ if (result)
|
||||
{
|
||||
Minecraft.this.func_152346_Z().func_152930_t();
|
||||
}
|
||||
@@ -3057,15 +2949,16 @@
|
||||
{
|
||||
if (Keyboard.getEventKeyState())
|
||||
{
|
||||
- if (i == this.field_71474_y.field_152395_am.func_151463_i())
|
||||
+ if (this.field_71474_y.field_152395_am.isActiveAndMatches(i))
|
||||
{
|
||||
this.func_71352_k();
|
||||
}
|
||||
- else if (i == this.field_71474_y.field_151447_Z.func_151463_i())
|
||||
+ else if (this.field_71474_y.field_151447_Z.isActiveAndMatches(i))
|
||||
{
|
||||
this.field_71456_v.func_146158_b().func_146227_a(ScreenShotHelper.func_148260_a(this.field_71412_D, this.field_71443_c, this.field_71440_d, this.field_147124_at));
|
||||
}
|
||||
}
|
||||
+ else if (this.field_71462_r instanceof GuiControls) ((GuiControls)this.field_71462_r).field_146491_f = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3192,4 +3085,10 @@
|
||||
{
|
||||
return this.field_184127_aH;
|
||||
}
|
||||
+
|
||||
+ // FORGE
|
||||
+ public ItemColors getItemColors()
|
||||
+ {
|
||||
+ return this.field_184128_aI;
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/audio/SoundManager.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/audio/SoundManager.java
|
||||
@@ -69,6 +69,7 @@
|
||||
@@ -76,6 +76,7 @@
|
||||
{
|
||||
SoundSystemConfig.addLibrary(LibraryLWJGLOpenAL.class);
|
||||
SoundSystemConfig.setCodec("ogg", CodecJOrbis.class);
|
||||
|
@ -8,34 +8,34 @@
|
|||
}
|
||||
catch (SoundSystemException soundsystemexception)
|
||||
{
|
||||
@@ -80,6 +81,7 @@
|
||||
{
|
||||
@@ -100,6 +101,7 @@
|
||||
|
||||
this.func_148613_b();
|
||||
this.func_148608_i();
|
||||
+ net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.sound.SoundLoadEvent(this));
|
||||
}
|
||||
|
||||
private synchronized void func_148608_i()
|
||||
@@ -316,6 +318,9 @@
|
||||
}
|
||||
else
|
||||
{
|
||||
+ p_148611_1_ = net.minecraftforge.client.ForgeHooksClient.playSound(this, p_148611_1_);
|
||||
+ if (p_148611_1_ == null) return;
|
||||
@@ -338,6 +340,9 @@
|
||||
{
|
||||
if (this.field_148617_f)
|
||||
{
|
||||
+ p_148611_1_ = net.minecraftforge.client.ForgeHooksClient.playSound(this, p_148611_1_);
|
||||
+ if (p_148611_1_ == null) return;
|
||||
+
|
||||
SoundEventAccessorComposite soundeventaccessorcomposite = this.field_148622_c.func_147680_a(p_148611_1_.func_147650_b());
|
||||
SoundEventAccessor soundeventaccessor = p_148611_1_.func_184366_a(this.field_148622_c);
|
||||
ResourceLocation resourcelocation = p_148611_1_.func_147650_b();
|
||||
|
||||
if (soundeventaccessorcomposite == null)
|
||||
@@ -357,10 +362,12 @@
|
||||
if (soundpoolentry.func_148648_d())
|
||||
@@ -400,10 +405,12 @@
|
||||
if (sound.func_188723_h())
|
||||
{
|
||||
this.field_148620_e.newStreamingSource(false, s, func_148612_a(resourcelocation), resourcelocation.toString(), flag, p_148611_1_.func_147649_g(), p_148611_1_.func_147654_h(), p_148611_1_.func_147651_i(), p_148611_1_.func_147656_j().func_148586_a(), f1);
|
||||
this.field_148620_e.newStreamingSource(false, s, func_148612_a(resourcelocation1), resourcelocation1.toString(), flag, p_148611_1_.func_147649_g(), p_148611_1_.func_147654_h(), p_148611_1_.func_147651_i(), p_148611_1_.func_147656_j().func_148586_a(), f);
|
||||
+ net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.sound.PlayStreamingSourceEvent(this, p_148611_1_, s));
|
||||
}
|
||||
else
|
||||
{
|
||||
this.field_148620_e.newSource(false, s, func_148612_a(resourcelocation), resourcelocation.toString(), flag, p_148611_1_.func_147649_g(), p_148611_1_.func_147654_h(), p_148611_1_.func_147651_i(), p_148611_1_.func_147656_j().func_148586_a(), f1);
|
||||
this.field_148620_e.newSource(false, s, func_148612_a(resourcelocation1), resourcelocation1.toString(), flag, p_148611_1_.func_147649_g(), p_148611_1_.func_147654_h(), p_148611_1_.func_147651_i(), p_148611_1_.func_147656_j().func_148586_a(), f);
|
||||
+ net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.sound.PlaySoundSourceEvent(this, p_148611_1_, s));
|
||||
}
|
||||
|
||||
field_148621_b.debug(field_148623_a, "Playing sound {} for event {} as channel {}", new Object[] {soundpoolentry.func_148652_a(), soundeventaccessorcomposite.func_148729_c(), s});
|
||||
field_148621_b.debug(field_148623_a, "Playing sound {} for event {} as channel {}", new Object[] {sound.func_188719_a(), resourcelocation1, s});
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/entity/AbstractClientPlayer.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/entity/AbstractClientPlayer.java
|
||||
@@ -128,6 +128,6 @@
|
||||
@@ -148,6 +148,6 @@
|
||||
f *= 1.0F - f1 * 0.15F;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/entity/EntityPlayerSP.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/entity/EntityPlayerSP.java
|
||||
@@ -345,6 +345,15 @@
|
||||
@@ -400,6 +400,15 @@
|
||||
this.field_71159_c.field_71456_v.func_146158_b().func_146227_a(p_146105_1_);
|
||||
}
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
|||
protected boolean func_145771_j(double p_145771_1_, double p_145771_3_, double p_145771_5_)
|
||||
{
|
||||
if (this.field_70145_X)
|
||||
@@ -357,30 +366,34 @@
|
||||
@@ -412,30 +421,34 @@
|
||||
double d0 = p_145771_1_ - (double)blockpos.func_177958_n();
|
||||
double d1 = p_145771_5_ - (double)blockpos.func_177952_p();
|
||||
|
||||
|
@ -56,25 +56,27 @@
|
|||
{
|
||||
d2 = 1.0D - d1;
|
||||
i = 5;
|
||||
@@ -415,7 +428,7 @@
|
||||
@@ -470,7 +483,7 @@
|
||||
|
||||
private boolean func_175162_d(BlockPos p_175162_1_)
|
||||
{
|
||||
- return !this.field_70170_p.func_180495_p(p_175162_1_).func_177230_c().func_149721_r() && !this.field_70170_p.func_180495_p(p_175162_1_.func_177984_a()).func_177230_c().func_149721_r();
|
||||
+ return !this.field_70170_p.func_180495_p(p_175162_1_).func_177230_c().func_149721_r();
|
||||
- return !this.field_70170_p.func_180495_p(p_175162_1_).func_185915_l() && !this.field_70170_p.func_180495_p(p_175162_1_.func_177984_a()).func_185915_l();
|
||||
+ return !this.field_70170_p.func_180495_p(p_175162_1_).func_185915_l();
|
||||
}
|
||||
|
||||
public void func_70031_b(boolean p_70031_1_)
|
||||
@@ -448,6 +461,12 @@
|
||||
@@ -515,7 +528,13 @@
|
||||
|
||||
public void func_85030_a(String p_85030_1_, float p_85030_2_, float p_85030_3_)
|
||||
public void func_184185_a(SoundEvent p_184185_1_, float p_184185_2_, float p_184185_3_)
|
||||
{
|
||||
+ net.minecraftforge.event.entity.PlaySoundAtEntityEvent event = net.minecraftforge.event.ForgeEventFactory.onPlaySoundAtEntity(this, p_85030_1_, p_85030_2_, p_85030_3_);
|
||||
+ if (event.isCanceled() || event.name == null) return;
|
||||
+ p_85030_1_ = event.name;
|
||||
+ p_85030_2_ = event.newVolume;
|
||||
+ p_85030_3_ = event.newPitch;
|
||||
- this.field_70170_p.func_184134_a(this.field_70165_t, this.field_70163_u, this.field_70161_v, p_184185_1_, this.func_184176_by(), p_184185_2_, p_184185_3_, false);
|
||||
+ net.minecraftforge.event.entity.PlaySoundAtEntityEvent event = net.minecraftforge.event.ForgeEventFactory.onPlaySoundAtEntity(this, p_184185_1_, this.func_184176_by(), p_184185_2_, p_184185_3_);
|
||||
+ if (event.isCanceled() || event.getSound() == null) return;
|
||||
+ p_184185_1_ = event.getSound();
|
||||
+ p_184185_2_ = event.getVolume();
|
||||
+ p_184185_3_ = event.getPitch();
|
||||
+
|
||||
this.field_70170_p.func_72980_b(this.field_70165_t, this.field_70163_u, this.field_70161_v, p_85030_1_, p_85030_2_, p_85030_3_, false);
|
||||
+ this.field_70170_p.func_184134_a(this.field_70165_t, this.field_70163_u, this.field_70161_v, p_184185_1_, event.getCategory(), p_184185_2_, p_184185_3_, false);
|
||||
}
|
||||
|
||||
public boolean func_70613_aW()
|
||||
|
|
|
@ -17,25 +17,25 @@
|
|||
}
|
||||
|
||||
private void func_111272_d()
|
||||
@@ -105,7 +106,7 @@
|
||||
@@ -106,7 +107,7 @@
|
||||
|
||||
try
|
||||
{
|
||||
- bufferedimage = TextureUtil.func_177053_a(Minecraft.func_71410_x().func_110442_L().func_110536_a(this.field_111273_g).func_110527_b());
|
||||
+ bufferedimage = TextureUtil.func_177053_a(getResourceInputStream(this.field_111273_g));
|
||||
- iresource = Minecraft.func_71410_x().func_110442_L().func_110536_a(this.field_111273_g);
|
||||
+ iresource = getResource(this.field_111273_g);
|
||||
bufferedimage = TextureUtil.func_177053_a(iresource.func_110527_b());
|
||||
}
|
||||
catch (IOException ioexception)
|
||||
{
|
||||
@@ -165,7 +166,7 @@
|
||||
@@ -171,7 +172,7 @@
|
||||
|
||||
try
|
||||
{
|
||||
- inputstream = Minecraft.func_71410_x().func_110442_L().func_110536_a(new ResourceLocation("font/glyph_sizes.bin")).func_110527_b();
|
||||
+ inputstream = getResourceInputStream(new ResourceLocation("font/glyph_sizes.bin"));
|
||||
inputstream.read(this.field_78287_e);
|
||||
- iresource = Minecraft.func_71410_x().func_110442_L().func_110536_a(new ResourceLocation("font/glyph_sizes.bin"));
|
||||
+ iresource = getResource(new ResourceLocation("font/glyph_sizes.bin"));
|
||||
iresource.func_110527_b().read(this.field_78287_e);
|
||||
}
|
||||
catch (IOException ioexception)
|
||||
@@ -196,7 +197,7 @@
|
||||
@@ -202,7 +203,7 @@
|
||||
int i = p_78266_1_ % 16 * 8;
|
||||
int j = p_78266_1_ / 16 * 8;
|
||||
int k = p_78266_2_ ? 1 : 0;
|
||||
|
@ -43,8 +43,8 @@
|
|||
+ bindTexture(this.field_111273_g);
|
||||
int l = this.field_78286_d[p_78266_1_];
|
||||
float f = (float)l - 0.01F;
|
||||
GL11.glBegin(GL11.GL_TRIANGLE_STRIP);
|
||||
@@ -224,7 +225,7 @@
|
||||
GlStateManager.func_187447_r(5);
|
||||
@@ -230,7 +231,7 @@
|
||||
|
||||
private void func_78257_a(int p_78257_1_)
|
||||
{
|
||||
|
@ -53,7 +53,7 @@
|
|||
}
|
||||
|
||||
protected float func_78277_a(char p_78277_1_, boolean p_78277_2_)
|
||||
@@ -271,7 +272,7 @@
|
||||
@@ -279,7 +280,7 @@
|
||||
|
||||
public int func_175065_a(String p_175065_1_, float p_175065_2_, float p_175065_3_, int p_175065_4_, boolean p_175065_5_)
|
||||
{
|
||||
|
@ -62,7 +62,7 @@
|
|||
this.func_78265_b();
|
||||
int i;
|
||||
|
||||
@@ -341,7 +342,7 @@
|
||||
@@ -349,7 +350,7 @@
|
||||
|
||||
int j1 = this.field_78285_g[i1];
|
||||
this.field_78304_r = j1;
|
||||
|
@ -71,7 +71,7 @@
|
|||
}
|
||||
else if (i1 == 16)
|
||||
{
|
||||
@@ -370,7 +371,7 @@
|
||||
@@ -378,7 +379,7 @@
|
||||
this.field_78299_w = false;
|
||||
this.field_78300_v = false;
|
||||
this.field_78301_u = false;
|
||||
|
@ -80,7 +80,7 @@
|
|||
}
|
||||
|
||||
++i;
|
||||
@@ -398,7 +399,7 @@
|
||||
@@ -406,7 +407,7 @@
|
||||
c0 = c1;
|
||||
}
|
||||
|
||||
|
@ -89,7 +89,7 @@
|
|||
boolean flag = (c0 == 0 || j == -1 || this.field_78293_l) && p_78255_2_;
|
||||
|
||||
if (flag)
|
||||
@@ -436,7 +437,16 @@
|
||||
@@ -444,7 +445,16 @@
|
||||
|
||||
++f;
|
||||
}
|
||||
|
@ -106,7 +106,7 @@
|
|||
if (this.field_78299_w)
|
||||
{
|
||||
Tessellator tessellator = Tessellator.func_178181_a();
|
||||
@@ -509,7 +519,7 @@
|
||||
@@ -517,7 +527,7 @@
|
||||
this.field_78292_o = (float)(p_180455_4_ >> 8 & 255) / 255.0F;
|
||||
this.field_78306_p = (float)(p_180455_4_ & 255) / 255.0F;
|
||||
this.field_78305_q = (float)(p_180455_4_ >> 24 & 255) / 255.0F;
|
||||
|
@ -115,19 +115,7 @@
|
|||
this.field_78295_j = p_180455_2_;
|
||||
this.field_78296_k = p_180455_3_;
|
||||
this.func_78255_a(p_180455_1_, p_180455_5_);
|
||||
@@ -588,11 +598,6 @@
|
||||
int j = this.field_78287_e[p_78263_1_] >>> 4;
|
||||
int k = this.field_78287_e[p_78263_1_] & 15;
|
||||
|
||||
- if (k > 7)
|
||||
- {
|
||||
- k = 15;
|
||||
- j = 0;
|
||||
- }
|
||||
|
||||
++k;
|
||||
return (k - j) / 2 + 1;
|
||||
@@ -846,6 +851,26 @@
|
||||
@@ -848,6 +858,26 @@
|
||||
return this.field_78294_m;
|
||||
}
|
||||
|
||||
|
@ -146,11 +134,11 @@
|
|||
+ field_78298_i.func_110577_a(location);
|
||||
+ }
|
||||
+
|
||||
+ protected InputStream getResourceInputStream(ResourceLocation location) throws IOException
|
||||
+ protected IResource getResource(ResourceLocation location) throws IOException
|
||||
+ {
|
||||
+ return Minecraft.func_71410_x().func_110442_L().func_110536_a(location).func_110527_b();
|
||||
+ return Minecraft.func_71410_x().func_110442_L().func_110536_a(location);
|
||||
+ }
|
||||
+
|
||||
public int func_175064_b(char p_175064_1_)
|
||||
{
|
||||
return this.field_78285_g["0123456789abcdef".indexOf(p_175064_1_)];
|
||||
int i = "0123456789abcdef".indexOf(p_175064_1_);
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiBossOverlay.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiBossOverlay.java
|
||||
@@ -35,13 +35,18 @@
|
||||
for (BossInfoLerping bossinfolerping : this.field_184060_g.values())
|
||||
{
|
||||
int k = i / 2 - 91;
|
||||
+ net.minecraftforge.client.event.RenderGameOverlayEvent.BossInfo event =
|
||||
+ net.minecraftforge.client.ForgeHooksClient.bossBarRenderPre(scaledresolution, bossinfolerping, k, j, 10 + this.field_184059_f.field_71466_p.field_78288_b);
|
||||
+ if (!event.isCanceled()) {
|
||||
GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
this.field_184059_f.func_110434_K().func_110577_a(field_184058_a);
|
||||
this.func_184052_a(k, j, bossinfolerping);
|
||||
String s = bossinfolerping.func_186744_e().func_150254_d();
|
||||
this.field_184059_f.field_71466_p.func_175063_a(s, (float)(i / 2 - this.field_184059_f.field_71466_p.func_78256_a(s) / 2), (float)(j - 9), 16777215);
|
||||
- j += 10 + this.field_184059_f.field_71466_p.field_78288_b;
|
||||
+ }
|
||||
+ j += event.getIncrement();
|
||||
|
||||
+ net.minecraftforge.client.ForgeHooksClient.bossBarRenderPost(scaledresolution);
|
||||
if (j >= scaledresolution.func_78328_b() / 3)
|
||||
{
|
||||
break;
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiButton.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiButton.java
|
||||
@@ -21,6 +21,7 @@
|
||||
@@ -22,6 +22,7 @@
|
||||
public boolean field_146124_l;
|
||||
public boolean field_146125_m;
|
||||
protected boolean field_146123_n;
|
||||
|
@ -8,7 +8,7 @@
|
|||
|
||||
public GuiButton(int p_i1020_1_, int p_i1020_2_, int p_i1020_3_, String p_i1020_4_)
|
||||
{
|
||||
@@ -74,6 +75,11 @@
|
||||
@@ -75,6 +76,11 @@
|
||||
this.func_146119_b(p_146112_1_, p_146112_2_, p_146112_3_);
|
||||
int j = 14737632;
|
||||
|
||||
|
|
|
@ -1,39 +1,10 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiChat.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiChat.java
|
||||
@@ -215,13 +215,14 @@
|
||||
this.field_146297_k.field_71456_v.func_146158_b().func_146234_a(new ChatComponentText(stringbuilder.toString()), 1);
|
||||
}
|
||||
@@ -250,6 +250,7 @@
|
||||
|
||||
- this.field_146415_a.func_146191_b((String)this.field_146412_t.get(this.field_146413_s++));
|
||||
+ this.field_146415_a.func_146191_b(net.minecraft.util.EnumChatFormatting.func_110646_a((String)this.field_146412_t.get(this.field_146413_s++)));
|
||||
}
|
||||
|
||||
private void func_146405_a(String p_146405_1_, String p_146405_2_)
|
||||
{
|
||||
if (p_146405_1_.length() >= 1)
|
||||
{
|
||||
+ net.minecraftforge.client.ClientCommandHandler.instance.autoComplete(p_146405_1_, p_146405_2_);
|
||||
BlockPos blockpos = null;
|
||||
|
||||
if (this.field_146297_k.field_71476_x != null && this.field_146297_k.field_71476_x.field_72313_a == MovingObjectPosition.MovingObjectType.BLOCK)
|
||||
@@ -281,6 +282,12 @@
|
||||
this.field_146417_i = false;
|
||||
this.field_146412_t.clear();
|
||||
|
||||
+ String[] complete = net.minecraftforge.client.ClientCommandHandler.instance.latestAutoComplete;
|
||||
+ if (complete != null)
|
||||
+ {
|
||||
+ p_146406_1_ = com.google.common.collect.ObjectArrays.concat(complete, p_146406_1_, String.class);
|
||||
+ }
|
||||
public BlockPos func_186839_b()
|
||||
{
|
||||
+
|
||||
for (String s : p_146406_1_)
|
||||
{
|
||||
if (s.length() > 0)
|
||||
@@ -291,6 +298,7 @@
|
||||
BlockPos blockpos = null;
|
||||
|
||||
String s1 = this.field_146415_a.func_146179_b().substring(this.field_146415_a.func_146197_a(-1, this.field_146415_a.func_146198_h(), false));
|
||||
String s2 = StringUtils.getCommonPrefix(p_146406_1_);
|
||||
+ s2 = net.minecraft.util.EnumChatFormatting.func_110646_a(s2);
|
||||
|
||||
if (s2.length() > 0 && !s1.equalsIgnoreCase(s2))
|
||||
{
|
||||
if (this.field_186853_g.field_71476_x != null && this.field_186853_g.field_71476_x.field_72313_a == RayTraceResult.Type.BLOCK)
|
||||
|
|
|
@ -0,0 +1,50 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiControls.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiControls.java
|
||||
@@ -65,7 +65,7 @@
|
||||
{
|
||||
for (KeyBinding keybinding : this.field_146297_k.field_71474_y.field_74324_K)
|
||||
{
|
||||
- keybinding.func_151462_b(keybinding.func_151469_h());
|
||||
+ keybinding.setToDefault();
|
||||
}
|
||||
|
||||
KeyBinding.func_74508_b();
|
||||
@@ -81,6 +81,7 @@
|
||||
{
|
||||
if (this.field_146491_f != null)
|
||||
{
|
||||
+ this.field_146491_f.setKeyModifierAndCode(net.minecraftforge.client.settings.KeyModifier.getActiveModifier(), -100 + p_73864_3_);
|
||||
this.field_146497_i.func_151440_a(this.field_146491_f, -100 + p_73864_3_);
|
||||
this.field_146491_f = null;
|
||||
KeyBinding.func_74508_b();
|
||||
@@ -105,17 +106,21 @@
|
||||
{
|
||||
if (p_73869_2_ == 1)
|
||||
{
|
||||
+ this.field_146491_f.setKeyModifierAndCode(net.minecraftforge.client.settings.KeyModifier.NONE, 0);
|
||||
this.field_146497_i.func_151440_a(this.field_146491_f, 0);
|
||||
}
|
||||
else if (p_73869_2_ != 0)
|
||||
{
|
||||
+ this.field_146491_f.setKeyModifierAndCode(net.minecraftforge.client.settings.KeyModifier.getActiveModifier(), p_73869_2_);
|
||||
this.field_146497_i.func_151440_a(this.field_146491_f, p_73869_2_);
|
||||
}
|
||||
else if (p_73869_1_ > 0)
|
||||
{
|
||||
+ this.field_146491_f.setKeyModifierAndCode(net.minecraftforge.client.settings.KeyModifier.getActiveModifier(), p_73869_1_ + 256);
|
||||
this.field_146497_i.func_151440_a(this.field_146491_f, p_73869_1_ + 256);
|
||||
}
|
||||
|
||||
+ if (!net.minecraftforge.client.settings.KeyModifier.isKeyCodeModifier(p_73869_2_))
|
||||
this.field_146491_f = null;
|
||||
this.field_152177_g = Minecraft.func_71386_F();
|
||||
KeyBinding.func_74508_b();
|
||||
@@ -135,7 +140,7 @@
|
||||
|
||||
for (KeyBinding keybinding : this.field_146497_i.field_74324_K)
|
||||
{
|
||||
- if (keybinding.func_151463_i() != keybinding.func_151469_h())
|
||||
+ if (!keybinding.isSetToDefaultValue())
|
||||
{
|
||||
flag = false;
|
||||
break;
|
|
@ -6,10 +6,10 @@
|
|||
|
||||
+ WorldType.field_77139_a[this.field_146331_K].onGUICreateWorldPress();
|
||||
+
|
||||
WorldSettings.GameType worldsettings$gametype = WorldSettings.GameType.func_77142_a(this.field_146342_r);
|
||||
WorldSettings worldsettings = new WorldSettings(i, worldsettings$gametype, this.field_146341_s, this.field_146337_w, WorldType.field_77139_a[this.field_146331_K]);
|
||||
WorldSettings worldsettings = new WorldSettings(i, WorldSettings.GameType.func_77142_a(this.field_146342_r), this.field_146341_s, this.field_146337_w, WorldType.field_77139_a[this.field_146331_K]);
|
||||
worldsettings.func_82750_a(this.field_146334_a);
|
||||
@@ -312,14 +314,7 @@
|
||||
|
||||
@@ -311,14 +313,7 @@
|
||||
}
|
||||
else if (p_146284_1_.field_146127_k == 8)
|
||||
{
|
||||
|
@ -25,7 +25,7 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
@@ -371,7 +366,7 @@
|
||||
@@ -370,7 +365,7 @@
|
||||
this.field_146326_C.field_146125_m = this.field_146344_y;
|
||||
this.field_146320_D.field_146125_m = this.field_146344_y;
|
||||
this.field_146321_E.field_146125_m = this.field_146344_y;
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiIngame.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiIngame.java
|
||||
@@ -360,7 +360,8 @@
|
||||
|
||||
BlockPos blockpos = raytraceresult.func_178782_a();
|
||||
|
||||
- if (!this.field_73839_d.field_71441_e.func_180495_p(blockpos).func_177230_c().func_149716_u() || !(this.field_73839_d.field_71441_e.func_175625_s(blockpos) instanceof IInventory))
|
||||
+ net.minecraft.block.state.IBlockState state = this.field_73839_d.field_71441_e.func_180495_p(blockpos);
|
||||
+ if (!state.func_177230_c().hasTileEntity(state) || !(this.field_73839_d.field_71441_e.func_175625_s(blockpos) instanceof IInventory))
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -418,7 +419,10 @@
|
||||
{
|
||||
Potion potion = potioneffect.func_188419_a();
|
||||
|
||||
- if (potion.func_76400_d() && potioneffect.func_188418_e())
|
||||
+ if (!potion.shouldRenderHUD(potioneffect)) continue;
|
||||
+ // Rebind in case previous renderHUDEffect changed texture
|
||||
+ this.field_73839_d.func_110434_K().func_110577_a(GuiContainer.field_147001_a);
|
||||
+ if (potioneffect.func_188418_e())
|
||||
{
|
||||
int k = p_184048_1_.func_78326_a();
|
||||
int l = 1;
|
||||
@@ -455,7 +459,10 @@
|
||||
}
|
||||
|
||||
GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, f);
|
||||
+ // FORGE - Move status icon check down from above so renderHUDEffect will still be called without a status icon
|
||||
+ if (potion.func_76400_d())
|
||||
this.func_73729_b(k + 3, l + 3, i1 % 8 * 18, 198 + i1 / 8 * 18, 18, 18);
|
||||
+ potion.renderHUDEffect(k, l, potioneffect, field_73839_d, f);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,67 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiKeyBindingList.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiKeyBindingList.java
|
||||
@@ -62,7 +62,7 @@
|
||||
|
||||
protected int func_148137_d()
|
||||
{
|
||||
- return super.func_148137_d() + 15;
|
||||
+ return super.func_148137_d() + 35;
|
||||
}
|
||||
|
||||
public int func_148139_c()
|
||||
@@ -113,7 +113,7 @@
|
||||
{
|
||||
this.field_148282_b = p_i45029_2_;
|
||||
this.field_148283_c = I18n.func_135052_a(p_i45029_2_.func_151464_g(), new Object[0]);
|
||||
- this.field_148280_d = new GuiButton(0, 0, 0, 75, 20, I18n.func_135052_a(p_i45029_2_.func_151464_g(), new Object[0]));
|
||||
+ this.field_148280_d = new GuiButton(0, 0, 0, 95, 20, I18n.func_135052_a(p_i45029_2_.func_151464_g(), new Object[0]));
|
||||
this.field_148281_e = new GuiButton(0, 0, 0, 50, 20, I18n.func_135052_a("controls.reset", new Object[0]));
|
||||
}
|
||||
|
||||
@@ -121,23 +121,24 @@
|
||||
{
|
||||
boolean flag = GuiKeyBindingList.this.field_148191_k.field_146491_f == this.field_148282_b;
|
||||
GuiKeyBindingList.this.field_148189_l.field_71466_p.func_78276_b(this.field_148283_c, p_180790_2_ + 90 - GuiKeyBindingList.this.field_148188_n, p_180790_3_ + p_180790_5_ / 2 - GuiKeyBindingList.this.field_148189_l.field_71466_p.field_78288_b / 2, 16777215);
|
||||
- this.field_148281_e.field_146128_h = p_180790_2_ + 190;
|
||||
+ this.field_148281_e.field_146128_h = p_180790_2_ + 210;
|
||||
this.field_148281_e.field_146129_i = p_180790_3_;
|
||||
- this.field_148281_e.field_146124_l = this.field_148282_b.func_151463_i() != this.field_148282_b.func_151469_h();
|
||||
+ this.field_148281_e.field_146124_l = !this.field_148282_b.isSetToDefaultValue();
|
||||
this.field_148281_e.func_146112_a(GuiKeyBindingList.this.field_148189_l, p_180790_6_, p_180790_7_);
|
||||
this.field_148280_d.field_146128_h = p_180790_2_ + 105;
|
||||
this.field_148280_d.field_146129_i = p_180790_3_;
|
||||
- this.field_148280_d.field_146126_j = GameSettings.func_74298_c(this.field_148282_b.func_151463_i());
|
||||
+ this.field_148280_d.field_146126_j = this.field_148282_b.getDisplayName();
|
||||
boolean flag1 = false;
|
||||
+ boolean keyCodeModifierConflict = true; // less severe form of conflict, like SHIFT conflicting with SHIFT+G
|
||||
|
||||
if (this.field_148282_b.func_151463_i() != 0)
|
||||
{
|
||||
for (KeyBinding keybinding : GuiKeyBindingList.this.field_148189_l.field_71474_y.field_74324_K)
|
||||
{
|
||||
- if (keybinding != this.field_148282_b && keybinding.func_151463_i() == this.field_148282_b.func_151463_i())
|
||||
+ if (keybinding != this.field_148282_b && keybinding.conflicts(this.field_148282_b))
|
||||
{
|
||||
flag1 = true;
|
||||
- break;
|
||||
+ keyCodeModifierConflict &= keybinding.hasKeyCodeModifierConflict(this.field_148282_b);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -148,7 +149,7 @@
|
||||
}
|
||||
else if (flag1)
|
||||
{
|
||||
- this.field_148280_d.field_146126_j = TextFormatting.RED + this.field_148280_d.field_146126_j;
|
||||
+ this.field_148280_d.field_146126_j = (keyCodeModifierConflict ? TextFormatting.GOLD : TextFormatting.RED) + this.field_148280_d.field_146126_j;
|
||||
}
|
||||
|
||||
this.field_148280_d.func_146112_a(GuiKeyBindingList.this.field_148189_l, p_180790_6_, p_180790_7_);
|
||||
@@ -163,6 +164,7 @@
|
||||
}
|
||||
else if (this.field_148281_e.func_146116_c(GuiKeyBindingList.this.field_148189_l, p_148278_2_, p_148278_3_))
|
||||
{
|
||||
+ this.field_148282_b.setToDefault();
|
||||
GuiKeyBindingList.this.field_148189_l.field_71474_y.func_151440_a(this.field_148282_b, this.field_148282_b.func_151469_h());
|
||||
KeyBinding.func_74508_b();
|
||||
return true;
|
|
@ -0,0 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiListWorldSelectionEntry.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiListWorldSelectionEntry.java
|
||||
@@ -242,7 +242,7 @@
|
||||
|
||||
if (this.field_186784_e.func_71359_d().func_90033_f(this.field_186786_g.func_75786_a()))
|
||||
{
|
||||
- this.field_186784_e.func_71371_a(this.field_186786_g.func_75786_a(), this.field_186786_g.func_75788_b(), (WorldSettings)null);
|
||||
+ net.minecraftforge.fml.client.FMLClientHandler.instance().tryLoadExistingWorld(field_186785_f, this.field_186786_g);
|
||||
}
|
||||
}
|
||||
|
|
@ -1,16 +1,32 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiMainMenu.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiMainMenu.java
|
||||
@@ -223,7 +223,8 @@
|
||||
@@ -67,6 +67,8 @@
|
||||
private GuiButton field_175372_K;
|
||||
private boolean field_183502_L;
|
||||
private GuiScreen field_183503_M;
|
||||
+ private GuiButton modButton;
|
||||
+ private net.minecraftforge.client.gui.NotificationModUpdateScreen modUpdateNotification;
|
||||
|
||||
public GuiMainMenu()
|
||||
{
|
||||
@@ -210,13 +212,15 @@
|
||||
this.field_183503_M.func_183500_a(this.field_146294_l, this.field_146295_m);
|
||||
this.field_183503_M.func_73866_w_();
|
||||
}
|
||||
+ modUpdateNotification = net.minecraftforge.client.gui.NotificationModUpdateScreen.init(this, modButton);
|
||||
}
|
||||
|
||||
private void func_73969_a(int p_73969_1_, int p_73969_2_)
|
||||
{
|
||||
this.field_146292_n.add(new GuiButton(1, this.field_146294_l / 2 - 100, p_73969_1_, I18n.func_135052_a("menu.singleplayer", new Object[0])));
|
||||
this.field_146292_n.add(new GuiButton(2, this.field_146294_l / 2 - 100, p_73969_1_ + p_73969_2_ * 1, I18n.func_135052_a("menu.multiplayer", new Object[0])));
|
||||
- this.field_146292_n.add(this.field_175372_K = new GuiButton(14, this.field_146294_l / 2 - 100, p_73969_1_ + p_73969_2_ * 2, I18n.func_135052_a("menu.online", new Object[0])));
|
||||
+ this.field_146292_n.add(this.field_175372_K = new GuiButton(14, this.field_146294_l / 2 + 2, p_73969_1_ + p_73969_2_ * 2, 98, 20, I18n.func_135052_a("menu.online", new Object[0]).replace("Minecraft", "").trim()));
|
||||
+ this.field_146292_n.add(new GuiButton(6, this.field_146294_l / 2 - 100, p_73969_1_ + p_73969_2_ * 2, 98, 20, I18n.func_135052_a("fml.menu.mods")));
|
||||
+ this.field_146292_n.add(modButton = new GuiButton(6, this.field_146294_l / 2 - 100, p_73969_1_ + p_73969_2_ * 2, 98, 20, I18n.func_135052_a("fml.menu.mods")));
|
||||
}
|
||||
|
||||
private void func_73972_b(int p_73972_1_, int p_73972_2_)
|
||||
@@ -271,6 +272,11 @@
|
||||
@@ -264,6 +268,11 @@
|
||||
this.field_146297_k.func_71400_g();
|
||||
}
|
||||
|
||||
|
@ -22,8 +38,17 @@
|
|||
if (p_146284_1_.field_146127_k == 11)
|
||||
{
|
||||
this.field_146297_k.func_71371_a("Demo_World", "Demo_World", DemoWorldServer.field_73071_a);
|
||||
@@ -516,7 +522,16 @@
|
||||
s = s + " Demo";
|
||||
@@ -493,6 +502,8 @@
|
||||
this.func_73729_b(j + 155, k + 0, 0, 45, 155, 44);
|
||||
}
|
||||
|
||||
+ this.field_73975_c = net.minecraftforge.client.ForgeHooksClient.renderMainMenu(this, this.field_146289_q, this.field_146294_l, this.field_146295_m, this.field_73975_c);
|
||||
+
|
||||
GlStateManager.func_179094_E();
|
||||
GlStateManager.func_179109_b((float)(this.field_146294_l / 2 + 90), 70.0F, 0.0F);
|
||||
GlStateManager.func_179114_b(-20.0F, 0.0F, 0.0F, 1.0F);
|
||||
@@ -512,7 +523,15 @@
|
||||
s = s + ("release".equalsIgnoreCase(this.field_146297_k.func_184123_d()) ? "" : "/" + this.field_146297_k.func_184123_d());
|
||||
}
|
||||
|
||||
- this.func_73731_b(this.field_146289_q, s, 2, this.field_146295_m - 10, -1);
|
||||
|
@ -36,7 +61,23 @@
|
|||
+ this.func_73731_b(this.field_146289_q, brd, 2, this.field_146295_m - ( 10 + brdline * (this.field_146289_q.field_78288_b + 1)), 16777215);
|
||||
+ }
|
||||
+ }
|
||||
+ net.minecraftforge.client.ForgeHooksClient.renderMainMenu(this, this.field_146289_q, this.field_146294_l, this.field_146295_m);
|
||||
String s1 = "Copyright Mojang AB. Do not distribute!";
|
||||
this.func_73731_b(this.field_146289_q, s1, this.field_146294_l - this.field_146289_q.func_78256_a(s1) - 2, this.field_146295_m - 10, -1);
|
||||
|
||||
@@ -529,6 +548,7 @@
|
||||
{
|
||||
this.field_183503_M.func_73863_a(p_73863_1_, p_73863_2_, p_73863_3_);
|
||||
}
|
||||
+ modUpdateNotification.func_73863_a(p_73863_1_, p_73863_2_, p_73863_3_);
|
||||
}
|
||||
|
||||
protected void func_73864_a(int p_73864_1_, int p_73864_2_, int p_73864_3_) throws IOException
|
||||
@@ -549,6 +569,8 @@
|
||||
{
|
||||
this.field_183503_M.func_73864_a(p_73864_1_, p_73864_2_, p_73864_3_);
|
||||
}
|
||||
+
|
||||
+ net.minecraftforge.client.ForgeHooksClient.mainMenuMouseClick(p_73864_1_, p_73864_2_, p_73864_3_, this.field_146289_q, this.field_146294_l);
|
||||
}
|
||||
|
||||
public void func_146281_b()
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiOverlayDebug.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiOverlayDebug.java
|
||||
@@ -176,6 +176,9 @@
|
||||
@@ -190,6 +190,9 @@
|
||||
long l = j - k;
|
||||
List<String> list = Lists.newArrayList(new String[] {String.format("Java: %s %dbit", new Object[]{System.getProperty("java.version"), Integer.valueOf(this.field_175242_a.func_147111_S() ? 64 : 32)}), String.format("Mem: % 2d%% %03d/%03dMB", new Object[]{Long.valueOf(l * 100L / i), Long.valueOf(func_175240_a(l)), Long.valueOf(func_175240_a(i))}), String.format("Allocated: % 2d%% %03dMB", new Object[]{Long.valueOf(j * 100L / i), Long.valueOf(func_175240_a(j))}), "", String.format("CPU: %s", new Object[]{OpenGlHelper.func_183029_j()}), "", String.format("Display: %dx%d (%s)", new Object[]{Integer.valueOf(Display.getWidth()), Integer.valueOf(Display.getHeight()), GL11.glGetString(GL11.GL_VENDOR)}), GL11.glGetString(GL11.GL_RENDERER), GL11.glGetString(GL11.GL_VERSION)});
|
||||
List<String> list = Lists.newArrayList(new String[] {String.format("Java: %s %dbit", new Object[]{System.getProperty("java.version"), Integer.valueOf(this.field_175242_a.func_147111_S() ? 64 : 32)}), String.format("Mem: % 2d%% %03d/%03dMB", new Object[]{Long.valueOf(l * 100L / i), Long.valueOf(func_175240_a(l)), Long.valueOf(func_175240_a(i))}), String.format("Allocated: % 2d%% %03dMB", new Object[]{Long.valueOf(j * 100L / i), Long.valueOf(func_175240_a(j))}), "", String.format("CPU: %s", new Object[]{OpenGlHelper.func_183029_j()}), "", String.format("Display: %dx%d (%s)", new Object[]{Integer.valueOf(Display.getWidth()), Integer.valueOf(Display.getHeight()), GlStateManager.func_187416_u(7936)}), GlStateManager.func_187416_u(7937), GlStateManager.func_187416_u(7938)});
|
||||
|
||||
+ list.add("");
|
||||
+ list.addAll(net.minecraftforge.fml.common.FMLCommonHandler.instance().getBrandings(false));
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiScreen.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiScreen.java
|
||||
@@ -143,7 +143,8 @@
|
||||
@@ -141,7 +141,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
|||
}
|
||||
|
||||
protected void func_146279_a(String p_146279_1_, int p_146279_2_, int p_146279_3_)
|
||||
@@ -153,7 +154,13 @@
|
||||
@@ -151,7 +152,13 @@
|
||||
|
||||
protected void func_146283_a(List<String> p_146283_1_, int p_146283_2_, int p_146283_3_)
|
||||
{
|
||||
|
@ -25,7 +25,7 @@
|
|||
{
|
||||
GlStateManager.func_179101_C();
|
||||
RenderHelper.func_74518_a();
|
||||
@@ -436,6 +443,7 @@
|
||||
@@ -421,6 +428,7 @@
|
||||
{
|
||||
this.field_146297_k.field_71456_v.func_146158_b().func_146239_a(p_175281_1_);
|
||||
}
|
||||
|
@ -33,23 +33,23 @@
|
|||
|
||||
this.field_146297_k.field_71439_g.func_71165_d(p_175281_1_);
|
||||
}
|
||||
@@ -450,9 +458,15 @@
|
||||
@@ -435,9 +443,15 @@
|
||||
|
||||
if (guibutton.func_146116_c(this.field_146297_k, p_73864_1_, p_73864_2_))
|
||||
{
|
||||
+ net.minecraftforge.client.event.GuiScreenEvent.ActionPerformedEvent.Pre event = new net.minecraftforge.client.event.GuiScreenEvent.ActionPerformedEvent.Pre(this, guibutton, this.field_146292_n);
|
||||
+ if (net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(event))
|
||||
+ break;
|
||||
+ guibutton = event.button;
|
||||
+ guibutton = event.getButton();
|
||||
this.field_146290_a = guibutton;
|
||||
guibutton.func_146113_a(this.field_146297_k.func_147118_V());
|
||||
this.func_146284_a(guibutton);
|
||||
+ if (this.equals(this.field_146297_k.field_71462_r))
|
||||
+ net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.GuiScreenEvent.ActionPerformedEvent.Post(this, event.button, this.field_146292_n));
|
||||
+ net.minecraftforge.common.MinecraftForge.EVENT_BUS.post(new net.minecraftforge.client.event.GuiScreenEvent.ActionPerformedEvent.Post(this, event.getButton(), this.field_146292_n));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -482,8 +496,12 @@
|
||||
@@ -467,8 +481,12 @@
|
||||
this.field_146289_q = p_146280_1_.field_71466_p;
|
||||
this.field_146294_l = p_146280_2_;
|
||||
this.field_146295_m = p_146280_3_;
|
||||
|
@ -62,7 +62,7 @@
|
|||
}
|
||||
|
||||
public void func_183500_a(int p_183500_1_, int p_183500_2_)
|
||||
@@ -502,7 +520,9 @@
|
||||
@@ -487,7 +505,9 @@
|
||||
{
|
||||
while (Mouse.next())
|
||||
{
|
||||
|
@ -72,7 +72,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
@@ -510,7 +530,9 @@
|
||||
@@ -495,7 +515,9 @@
|
||||
{
|
||||
while (Keyboard.next())
|
||||
{
|
||||
|
@ -82,7 +82,7 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
@@ -570,6 +592,7 @@
|
||||
@@ -557,6 +579,7 @@
|
||||
public void func_146276_q_()
|
||||
{
|
||||
this.func_146270_b(0);
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiScreenDemo.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiScreenDemo.java
|
||||
@@ -73,10 +73,10 @@
|
||||
this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.title", new Object[0]), i, j, 2039583);
|
||||
j = j + 12;
|
||||
GameSettings gamesettings = this.field_146297_k.field_71474_y;
|
||||
- this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.movementShort", new Object[] {GameSettings.func_74298_c(gamesettings.field_74351_w.func_151463_i()), GameSettings.func_74298_c(gamesettings.field_74370_x.func_151463_i()), GameSettings.func_74298_c(gamesettings.field_74368_y.func_151463_i()), GameSettings.func_74298_c(gamesettings.field_74366_z.func_151463_i())}), i, j, 5197647);
|
||||
+ this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.movementShort", new Object[] {gamesettings.field_74351_w.getDisplayName(), gamesettings.field_74370_x.getDisplayName(), gamesettings.field_74368_y.getDisplayName(), gamesettings.field_74366_z.getDisplayName()}), i, j, 5197647);
|
||||
this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.movementMouse", new Object[0]), i, j + 12, 5197647);
|
||||
- this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.jump", new Object[] {GameSettings.func_74298_c(gamesettings.field_74314_A.func_151463_i())}), i, j + 24, 5197647);
|
||||
- this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.inventory", new Object[] {GameSettings.func_74298_c(gamesettings.field_151445_Q.func_151463_i())}), i, j + 36, 5197647);
|
||||
+ this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.jump", new Object[] {gamesettings.field_74314_A.getDisplayName()}), i, j + 24, 5197647);
|
||||
+ this.field_146289_q.func_78276_b(I18n.func_135052_a("demo.help.inventory", new Object[] {gamesettings.field_151445_Q.getDisplayName()}), i, j + 36, 5197647);
|
||||
this.field_146289_q.func_78279_b(I18n.func_135052_a("demo.help.fullWrapped", new Object[0]), i, j + 68, 218, 2039583);
|
||||
super.func_73863_a(p_73863_1_, p_73863_2_, p_73863_3_);
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiSelectWorld.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiSelectWorld.java
|
||||
@@ -186,7 +186,7 @@
|
||||
|
||||
if (this.field_146297_k.func_71359_d().func_90033_f(s))
|
||||
{
|
||||
- this.field_146297_k.func_71371_a(s, s1, (WorldSettings)null);
|
||||
+ net.minecraftforge.fml.client.FMLClientHandler.instance().tryLoadExistingWorld(this, s, s1);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -3,15 +3,15 @@
|
|||
@@ -181,15 +181,8 @@
|
||||
GlStateManager.func_179106_n();
|
||||
Tessellator tessellator = Tessellator.func_178181_a();
|
||||
WorldRenderer worldrenderer = tessellator.func_178180_c();
|
||||
VertexBuffer vertexbuffer = tessellator.func_178180_c();
|
||||
- this.field_148161_k.func_110434_K().func_110577_a(Gui.field_110325_k);
|
||||
- GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
- float f = 32.0F;
|
||||
- worldrenderer.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
- worldrenderer.func_181662_b((double)this.field_148152_e, (double)this.field_148154_c, 0.0D).func_181673_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- worldrenderer.func_181662_b((double)this.field_148151_d, (double)this.field_148154_c, 0.0D).func_181673_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- worldrenderer.func_181662_b((double)this.field_148151_d, (double)this.field_148153_b, 0.0D).func_181673_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- worldrenderer.func_181662_b((double)this.field_148152_e, (double)this.field_148153_b, 0.0D).func_181673_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- vertexbuffer.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
- vertexbuffer.func_181662_b((double)this.field_148152_e, (double)this.field_148154_c, 0.0D).func_187315_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- vertexbuffer.func_181662_b((double)this.field_148151_d, (double)this.field_148154_c, 0.0D).func_187315_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- vertexbuffer.func_181662_b((double)this.field_148151_d, (double)this.field_148153_b, 0.0D).func_187315_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- vertexbuffer.func_181662_b((double)this.field_148152_e, (double)this.field_148153_b, 0.0D).func_187315_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
- tessellator.func_78381_a();
|
||||
+ // Forge: background rendering moved into separate method.
|
||||
+ this.drawContainerBackground(tessellator);
|
||||
|
@ -25,15 +25,15 @@
|
|||
+
|
||||
+ protected void drawContainerBackground(Tessellator tessellator)
|
||||
+ {
|
||||
+ WorldRenderer worldrenderer = tessellator.func_178180_c();
|
||||
+ VertexBuffer buffer = tessellator.func_178180_c();
|
||||
+ this.field_148161_k.func_110434_K().func_110577_a(Gui.field_110325_k);
|
||||
+ GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
+ float f = 32.0F;
|
||||
+ worldrenderer.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
+ worldrenderer.func_181662_b((double)this.field_148152_e, (double)this.field_148154_c, 0.0D).func_181673_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ worldrenderer.func_181662_b((double)this.field_148151_d, (double)this.field_148154_c, 0.0D).func_181673_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ worldrenderer.func_181662_b((double)this.field_148151_d, (double)this.field_148153_b, 0.0D).func_181673_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ worldrenderer.func_181662_b((double)this.field_148152_e, (double)this.field_148153_b, 0.0D).func_181673_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ buffer.func_181668_a(7, DefaultVertexFormats.field_181709_i);
|
||||
+ buffer.func_181662_b((double)this.field_148152_e, (double)this.field_148154_c, 0.0D).func_187315_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ buffer.func_181662_b((double)this.field_148151_d, (double)this.field_148154_c, 0.0D).func_187315_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148154_c + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ buffer.func_181662_b((double)this.field_148151_d, (double)this.field_148153_b, 0.0D).func_187315_a((double)((float)this.field_148151_d / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ buffer.func_181662_b((double)this.field_148152_e, (double)this.field_148153_b, 0.0D).func_187315_a((double)((float)this.field_148152_e / f), (double)((float)(this.field_148153_b + (int)this.field_148169_q) / f)).func_181669_b(32, 32, 32, 255).func_181675_d();
|
||||
+ tessellator.func_78381_a();
|
||||
+ }
|
||||
}
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/GuiSpectator.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/GuiSpectator.java
|
||||
@@ -109,7 +109,7 @@
|
||||
GlStateManager.func_179131_c(f, f, f, p_175266_4_);
|
||||
p_175266_5_.func_178663_a(f, i);
|
||||
GlStateManager.func_179121_F();
|
||||
- String s = String.valueOf((Object)GameSettings.func_74298_c(this.field_175268_g.field_71474_y.field_151456_ac[p_175266_1_].func_151463_i()));
|
||||
+ String s = String.valueOf(this.field_175268_g.field_71474_y.field_151456_ac[p_175266_1_].getDisplayName());
|
||||
|
||||
if (i > 3 && p_175266_5_.func_178662_A_())
|
||||
{
|
|
@ -5,6 +5,6 @@
|
|||
}
|
||||
|
||||
+ s3 = FontRenderer.func_78282_e(s2) + s3; //Forge: Fix chat formatting not surviving line wrapping.
|
||||
ChatComponentText chatcomponenttext2 = new ChatComponentText(s3);
|
||||
chatcomponenttext2.func_150255_a(ichatcomponent1.func_150256_b().func_150232_l());
|
||||
list1.add(j + 1, chatcomponenttext2);
|
||||
TextComponentString textcomponentstring2 = new TextComponentString(s3);
|
||||
textcomponentstring2.func_150255_a(itextcomponent1.func_150256_b().func_150232_l());
|
||||
list1.add(j + 1, textcomponentstring2);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/ServerListEntryNormal.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/ServerListEntryNormal.java
|
||||
@@ -82,7 +82,7 @@
|
||||
boolean flag1 = this.field_148301_e.field_82821_f < 47;
|
||||
boolean flag1 = this.field_148301_e.field_82821_f < 107;
|
||||
boolean flag2 = flag || flag1;
|
||||
this.field_148300_d.field_71466_p.func_78276_b(this.field_148301_e.field_78847_a, p_180790_2_ + 32 + 3, p_180790_3_ + 1, 16777215);
|
||||
- List<String> list = this.field_148300_d.field_71466_p.func_78271_c(this.field_148301_e.field_78843_d, p_180790_4_ - 32 - 2);
|
||||
|
|
|
@ -13,10 +13,10 @@
|
|||
this.field_146562_a = p_i45026_1_;
|
||||
@@ -57,6 +61,14 @@
|
||||
int j = 141;
|
||||
this.field_146569_s = this.field_146567_u = this.field_146565_w = (double)(AchievementList.field_76004_f.field_75993_a * 24 - i / 2 - 12);
|
||||
this.field_146568_t = this.field_146566_v = this.field_146573_x = (double)(AchievementList.field_76004_f.field_75991_b * 24 - j / 2);
|
||||
this.field_146569_s = this.field_146567_u = this.field_146565_w = (double)(AchievementList.field_187982_f.field_75993_a * 24 - i / 2 - 12);
|
||||
this.field_146568_t = this.field_146566_v = this.field_146573_x = (double)(AchievementList.field_187982_f.field_75991_b * 24 - j / 2);
|
||||
+ minecraftAchievements.clear();
|
||||
+ for (Achievement achievement : AchievementList.field_76007_e)
|
||||
+ for (Achievement achievement : AchievementList.field_187981_e)
|
||||
+ {
|
||||
+ if (!net.minecraftforge.common.AchievementPage.isAchievementInPages(achievement))
|
||||
+ {
|
||||
|
@ -27,14 +27,14 @@
|
|||
|
||||
public void func_73866_w_()
|
||||
@@ -64,6 +76,7 @@
|
||||
this.field_146297_k.func_147114_u().func_147297_a(new C16PacketClientStatus(C16PacketClientStatus.EnumState.REQUEST_STATS));
|
||||
this.field_146297_k.func_147114_u().func_147297_a(new CPacketClientStatus(CPacketClientStatus.State.REQUEST_STATS));
|
||||
this.field_146292_n.clear();
|
||||
this.field_146292_n.add(new GuiOptionButton(1, this.field_146294_l / 2 + 24, this.field_146295_m / 2 + 74, 80, 20, I18n.func_135052_a("gui.done", new Object[0])));
|
||||
+ this.field_146292_n.add(button = new GuiButton(2, (field_146294_l - field_146555_f) / 2 + 24, field_146295_m / 2 + 74, 125, 20, net.minecraftforge.common.AchievementPage.getTitle(currentPage)));
|
||||
}
|
||||
|
||||
protected void func_146284_a(GuiButton p_146284_1_) throws IOException
|
||||
@@ -74,6 +87,16 @@
|
||||
@@ -74,12 +87,22 @@
|
||||
{
|
||||
this.field_146297_k.func_147108_a(this.field_146562_a);
|
||||
}
|
||||
|
@ -51,6 +51,13 @@
|
|||
}
|
||||
}
|
||||
|
||||
protected void func_73869_a(char p_73869_1_, int p_73869_2_) throws IOException
|
||||
{
|
||||
- if (p_73869_2_ == this.field_146297_k.field_71474_y.field_151445_Q.func_151463_i())
|
||||
+ if (this.field_146297_k.field_71474_y.field_151445_Q.isActiveAndMatches(p_73869_2_))
|
||||
{
|
||||
this.field_146297_k.func_147108_a((GuiScreen)null);
|
||||
this.field_146297_k.func_71381_h();
|
||||
@@ -257,7 +280,9 @@
|
||||
GlStateManager.func_179143_c(518);
|
||||
GlStateManager.func_179094_E();
|
||||
|
@ -66,12 +73,11 @@
|
|||
GlStateManager.func_179143_c(515);
|
||||
this.field_146297_k.func_110434_K().func_110577_a(field_146561_C);
|
||||
|
||||
- for (int j5 = 0; j5 < AchievementList.field_76007_e.size(); ++j5)
|
||||
- for (int j5 = 0; j5 < AchievementList.field_187981_e.size(); ++j5)
|
||||
+ java.util.List<Achievement> achievementList = (currentPage == -1 ? minecraftAchievements : net.minecraftforge.common.AchievementPage.getAchievementPage(currentPage).getAchievements());
|
||||
+ for (int j5 = 0; j5 < achievementList.size(); ++j5)
|
||||
{
|
||||
- Achievement achievement1 = (Achievement)AchievementList.field_76007_e.get(j5);
|
||||
+ Achievement achievement1 = achievementList.get(j5);
|
||||
Achievement achievement1 = (Achievement)AchievementList.field_187981_e.get(j5);
|
||||
|
||||
- if (achievement1.field_75992_c != null)
|
||||
+ if (achievement1.field_75992_c != null && achievementList.contains(achievement1.field_75992_c))
|
||||
|
@ -82,10 +88,10 @@
|
|||
GlStateManager.func_179091_B();
|
||||
GlStateManager.func_179142_g();
|
||||
|
||||
- for (int i6 = 0; i6 < AchievementList.field_76007_e.size(); ++i6)
|
||||
- for (int i6 = 0; i6 < AchievementList.field_187981_e.size(); ++i6)
|
||||
+ for (int i6 = 0; i6 < achievementList.size(); ++i6)
|
||||
{
|
||||
- Achievement achievement2 = (Achievement)AchievementList.field_76007_e.get(i6);
|
||||
- Achievement achievement2 = (Achievement)AchievementList.field_187981_e.get(i6);
|
||||
+ Achievement achievement2 = achievementList.get(i6);
|
||||
int l6 = achievement2.field_75993_a * 24 - i;
|
||||
int j7 = achievement2.field_75991_b * 24 - j;
|
||||
|
@ -114,4 +120,4 @@
|
|||
+ GlStateManager.func_179140_f(); //Forge: Make sure Lighting is disabled. Fixes MC-33065
|
||||
GlStateManager.func_179089_o();
|
||||
this.field_146296_j.func_180450_b(achievement2.field_75990_d, l6 + 3, j7 + 3);
|
||||
GlStateManager.func_179112_b(770, 771);
|
||||
GlStateManager.func_187401_a(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
|
||||
|
|
|
@ -1,69 +0,0 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/achievement/GuiStats.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/achievement/GuiStats.java
|
||||
@@ -5,6 +5,8 @@
|
||||
import java.util.Collections;
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
+
|
||||
+import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.audio.PositionedSoundRecord;
|
||||
import net.minecraft.client.gui.GuiButton;
|
||||
@@ -443,17 +445,18 @@
|
||||
for (StatCrafting statcrafting : StatList.field_75939_e)
|
||||
{
|
||||
boolean flag = false;
|
||||
- int i = Item.func_150891_b(statcrafting.func_150959_a());
|
||||
+ int i = Block.func_149682_b(Block.func_149634_a(statcrafting.func_150959_a()));
|
||||
+ int itemId = Item.func_150891_b(statcrafting.func_150959_a());
|
||||
|
||||
if (GuiStats.this.field_146546_t.func_77444_a(statcrafting) > 0)
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
- else if (StatList.field_75929_E[i] != null && GuiStats.this.field_146546_t.func_77444_a(StatList.field_75929_E[i]) > 0)
|
||||
+ else if (StatList.field_75929_E[itemId] != null && GuiStats.this.field_146546_t.func_77444_a(StatList.field_75929_E[itemId]) > 0)
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
- else if (StatList.field_75928_D[i] != null && GuiStats.this.field_146546_t.func_77444_a(StatList.field_75928_D[i]) > 0)
|
||||
+ else if (StatList.field_75928_D[itemId] != null && GuiStats.this.field_146546_t.func_77444_a(StatList.field_75928_D[itemId]) > 0)
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
@@ -468,8 +471,15 @@
|
||||
{
|
||||
public int compare(StatCrafting p_compare_1_, StatCrafting p_compare_2_)
|
||||
{
|
||||
- int j = Item.func_150891_b(p_compare_1_.func_150959_a());
|
||||
- int k = Item.func_150891_b(p_compare_2_.func_150959_a());
|
||||
+ int j;
|
||||
+ int k;
|
||||
+ if (StatsBlock.this.field_148217_o == 2) {
|
||||
+ j = Block.func_149682_b(Block.func_149634_a(p_compare_1_.func_150959_a()));
|
||||
+ k = Block.func_149682_b(Block.func_149634_a(p_compare_2_.func_150959_a()));
|
||||
+ } else {
|
||||
+ j = Item.func_150891_b(p_compare_1_.func_150959_a());
|
||||
+ k = Item.func_150891_b(p_compare_2_.func_150959_a());
|
||||
+ }
|
||||
StatBase statbase = null;
|
||||
StatBase statbase1 = null;
|
||||
|
||||
@@ -748,7 +758,7 @@
|
||||
super(p_i45510_2_, GuiStats.this.field_146294_l, GuiStats.this.field_146295_m, 32, GuiStats.this.field_146295_m - 64, GuiStats.this.field_146289_q.field_78288_b * 4);
|
||||
this.func_148130_a(false);
|
||||
|
||||
- for (EntityList.EntityEggInfo entitylist$entityegginfo : EntityList.field_75627_a.values())
|
||||
+ for (EntityList.EntityEggInfo entitylist$entityegginfo : com.google.common.collect.Iterables.concat(EntityList.field_75627_a.values(), net.minecraftforge.fml.common.registry.EntityRegistry.getEggs().values()))
|
||||
{
|
||||
if (GuiStats.this.field_146546_t.func_77444_a(entitylist$entityegginfo.field_151512_d) > 0 || GuiStats.this.field_146546_t.func_77444_a(entitylist$entityegginfo.field_151513_e) > 0)
|
||||
{
|
||||
@@ -784,7 +794,7 @@
|
||||
protected void func_180791_a(int p_180791_1_, int p_180791_2_, int p_180791_3_, int p_180791_4_, int p_180791_5_, int p_180791_6_)
|
||||
{
|
||||
EntityList.EntityEggInfo entitylist$entityegginfo = (EntityList.EntityEggInfo)this.field_148222_l.get(p_180791_1_);
|
||||
- String s = I18n.func_135052_a("entity." + EntityList.func_75617_a(entitylist$entityegginfo.field_75613_a) + ".name", new Object[0]);
|
||||
+ String s = I18n.func_135052_a("entity." + entitylist$entityegginfo.name + ".name", new Object[0]);
|
||||
int i = GuiStats.this.field_146546_t.func_77444_a(entitylist$entityegginfo.field_151512_d);
|
||||
int j = GuiStats.this.field_146546_t.func_77444_a(entitylist$entityegginfo.field_151513_e);
|
||||
String s1 = I18n.func_135052_a("stat.entityKills", new Object[] {Integer.valueOf(i), s});
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/inventory/GuiContainer.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/inventory/GuiContainer.java
|
||||
@@ -175,8 +175,11 @@
|
||||
@@ -176,8 +176,11 @@
|
||||
GlStateManager.func_179109_b(0.0F, 0.0F, 32.0F);
|
||||
this.field_73735_i = 200.0F;
|
||||
this.field_146296_j.field_77023_b = 200.0F;
|
||||
|
@ -13,9 +13,9 @@
|
|||
this.field_73735_i = 0.0F;
|
||||
this.field_146296_j.field_77023_b = 0.0F;
|
||||
}
|
||||
@@ -239,13 +242,12 @@
|
||||
@@ -240,13 +243,12 @@
|
||||
|
||||
if (itemstack == null)
|
||||
if (itemstack == null && p_146977_1_.func_111238_b())
|
||||
{
|
||||
- String s1 = p_146977_1_.func_178171_c();
|
||||
+ TextureAtlasSprite textureatlassprite = p_146977_1_.getBackgroundSprite();
|
||||
|
@ -30,7 +30,16 @@
|
|||
this.func_175175_a(i, j, textureatlassprite, 16, 16);
|
||||
GlStateManager.func_179145_e();
|
||||
flag1 = true;
|
||||
@@ -326,6 +328,7 @@
|
||||
@@ -316,7 +318,7 @@
|
||||
protected void func_73864_a(int p_73864_1_, int p_73864_2_, int p_73864_3_) throws IOException
|
||||
{
|
||||
super.func_73864_a(p_73864_1_, p_73864_2_, p_73864_3_);
|
||||
- boolean flag = p_73864_3_ == this.field_146297_k.field_71474_y.field_74322_I.func_151463_i() + 100;
|
||||
+ boolean flag = this.field_146297_k.field_71474_y.field_74322_I.isActiveAndMatches(p_73864_3_ - 100);
|
||||
Slot slot = this.func_146975_c(p_73864_1_, p_73864_2_);
|
||||
long i = Minecraft.func_71386_F();
|
||||
this.field_146993_M = this.field_146998_K == slot && i - this.field_146997_J < 250L && this.field_146992_L == p_73864_3_;
|
||||
@@ -327,6 +329,7 @@
|
||||
int j = this.field_147003_i;
|
||||
int k = this.field_147009_r;
|
||||
boolean flag1 = p_73864_1_ < j || p_73864_2_ < k || p_73864_1_ >= j + this.field_146999_f || p_73864_2_ >= k + this.field_147000_g;
|
||||
|
@ -38,7 +47,25 @@
|
|||
int l = -1;
|
||||
|
||||
if (slot != null)
|
||||
@@ -463,10 +466,12 @@
|
||||
@@ -364,7 +367,7 @@
|
||||
{
|
||||
if (this.field_146297_k.field_71439_g.field_71071_by.func_70445_o() == null)
|
||||
{
|
||||
- if (p_73864_3_ == this.field_146297_k.field_71474_y.field_74322_I.func_151463_i() + 100)
|
||||
+ if (this.field_146297_k.field_71474_y.field_74322_I.isActiveAndMatches(p_73864_3_ - 100))
|
||||
{
|
||||
this.func_184098_a(slot, l, p_73864_3_, ClickType.CLONE);
|
||||
}
|
||||
@@ -402,7 +405,7 @@
|
||||
{
|
||||
this.field_146987_F = 1;
|
||||
}
|
||||
- else if (p_73864_3_ == this.field_146297_k.field_71474_y.field_74322_I.func_151463_i() + 100)
|
||||
+ else if (this.field_146297_k.field_71474_y.field_74322_I.isActiveAndMatches(p_73864_3_ - 100))
|
||||
{
|
||||
this.field_146987_F = 2;
|
||||
}
|
||||
@@ -464,10 +467,12 @@
|
||||
|
||||
protected void func_146286_b(int p_146286_1_, int p_146286_2_, int p_146286_3_)
|
||||
{
|
||||
|
@ -51,7 +78,48 @@
|
|||
int k = -1;
|
||||
|
||||
if (slot != null)
|
||||
@@ -685,4 +690,16 @@
|
||||
@@ -575,7 +580,7 @@
|
||||
}
|
||||
else if (this.field_146297_k.field_71439_g.field_71071_by.func_70445_o() != null)
|
||||
{
|
||||
- if (p_146286_3_ == this.field_146297_k.field_71474_y.field_74322_I.func_151463_i() + 100)
|
||||
+ if (this.field_146297_k.field_71474_y.field_74322_I.isActiveAndMatches(p_146286_3_ - 100))
|
||||
{
|
||||
this.func_184098_a(slot, k, p_146286_3_, ClickType.CLONE);
|
||||
}
|
||||
@@ -627,7 +632,7 @@
|
||||
|
||||
protected void func_73869_a(char p_73869_1_, int p_73869_2_) throws IOException
|
||||
{
|
||||
- if (p_73869_2_ == 1 || p_73869_2_ == this.field_146297_k.field_71474_y.field_151445_Q.func_151463_i())
|
||||
+ if (p_73869_2_ == 1 || this.field_146297_k.field_71474_y.field_151445_Q.isActiveAndMatches(p_73869_2_))
|
||||
{
|
||||
this.field_146297_k.field_71439_g.func_71053_j();
|
||||
}
|
||||
@@ -636,11 +641,11 @@
|
||||
|
||||
if (this.field_147006_u != null && this.field_147006_u.func_75216_d())
|
||||
{
|
||||
- if (p_73869_2_ == this.field_146297_k.field_71474_y.field_74322_I.func_151463_i())
|
||||
+ if (this.field_146297_k.field_71474_y.field_74322_I.isActiveAndMatches(p_73869_2_))
|
||||
{
|
||||
this.func_184098_a(this.field_147006_u, this.field_147006_u.field_75222_d, 0, ClickType.CLONE);
|
||||
}
|
||||
- else if (p_73869_2_ == this.field_146297_k.field_71474_y.field_74316_C.func_151463_i())
|
||||
+ else if (this.field_146297_k.field_71474_y.field_74316_C.isActiveAndMatches(p_73869_2_))
|
||||
{
|
||||
this.func_184098_a(this.field_147006_u, this.field_147006_u.field_75222_d, func_146271_m() ? 1 : 0, ClickType.THROW);
|
||||
}
|
||||
@@ -653,7 +658,7 @@
|
||||
{
|
||||
for (int i = 0; i < 9; ++i)
|
||||
{
|
||||
- if (p_146983_1_ == this.field_146297_k.field_71474_y.field_151456_ac[i].func_151463_i())
|
||||
+ if (this.field_146297_k.field_71474_y.field_151456_ac[i].isActiveAndMatches(p_146983_1_))
|
||||
{
|
||||
this.func_184098_a(this.field_147006_u, this.field_147006_u.field_75222_d, i, ClickType.SWAP);
|
||||
return true;
|
||||
@@ -686,4 +691,16 @@
|
||||
this.field_146297_k.field_71439_g.func_71053_j();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/gui/inventory/GuiContainerCreative.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/gui/inventory/GuiContainerCreative.java
|
||||
@@ -48,6 +48,8 @@
|
||||
@@ -49,6 +49,8 @@
|
||||
private Slot field_147064_C;
|
||||
private boolean field_147057_D;
|
||||
private CreativeCrafting field_147059_E;
|
||||
|
@ -9,16 +9,7 @@
|
|||
|
||||
public GuiContainerCreative(EntityPlayer p_i1088_1_)
|
||||
{
|
||||
@@ -175,7 +177,7 @@
|
||||
return;
|
||||
}
|
||||
|
||||
- if (itemstack1 != null && itemstack2 != null && itemstack1.func_77969_a(itemstack2))
|
||||
+ if (itemstack1 != null && itemstack2 != null && itemstack1.func_77969_a(itemstack2) && ItemStack.func_77970_a(itemstack1, itemstack2)) //Forge: Bugfix, Compare NBT data, allow for deletion of enchanted books, MC-12770
|
||||
{
|
||||
if (p_146984_3_ == 0)
|
||||
{
|
||||
@@ -259,6 +261,13 @@
|
||||
@@ -258,6 +260,13 @@
|
||||
this.func_147050_b(CreativeTabs.field_78032_a[i]);
|
||||
this.field_147059_E = new CreativeCrafting(this.field_146297_k);
|
||||
this.field_146297_k.field_71439_g.field_71069_bz.func_75132_a(this.field_147059_E);
|
||||
|
@ -32,7 +23,7 @@
|
|||
}
|
||||
else
|
||||
{
|
||||
@@ -280,7 +289,7 @@
|
||||
@@ -279,7 +288,7 @@
|
||||
|
||||
protected void func_73869_a(char p_73869_1_, int p_73869_2_) throws IOException
|
||||
{
|
||||
|
@ -41,7 +32,7 @@
|
|||
{
|
||||
if (GameSettings.func_100015_a(this.field_146297_k.field_71474_y.field_74310_D))
|
||||
{
|
||||
@@ -318,6 +327,14 @@
|
||||
@@ -317,6 +326,14 @@
|
||||
GuiContainerCreative.ContainerCreative guicontainercreative$containercreative = (GuiContainerCreative.ContainerCreative)this.field_147002_h;
|
||||
guicontainercreative$containercreative.field_148330_a.clear();
|
||||
|
||||
|
@ -56,7 +47,7 @@
|
|||
for (Item item : Item.field_150901_e)
|
||||
{
|
||||
if (item != null && item.func_77640_w() != null)
|
||||
@@ -325,7 +342,13 @@
|
||||
@@ -324,7 +341,13 @@
|
||||
item.func_150895_a(item, (CreativeTabs)null, guicontainercreative$containercreative.field_148330_a);
|
||||
}
|
||||
}
|
||||
|
@ -66,11 +57,11 @@
|
|||
+ //split from above for custom search tabs
|
||||
+ private void updateFilteredItems(GuiContainerCreative.ContainerCreative guicontainercreative$containercreative)
|
||||
+ {
|
||||
+ if (CreativeTabs.field_78032_a[field_147058_w] == CreativeTabs.field_78027_g) // FORGE: Only add enchanted books to the regular search
|
||||
for (Enchantment enchantment : Enchantment.field_77331_b)
|
||||
+ if (CreativeTabs.field_78032_a[field_147058_w] == CreativeTabs.field_78027_g) // FORGE: Only add enchanted books to the regular search
|
||||
for (Enchantment enchantment : Enchantment.field_185264_b)
|
||||
{
|
||||
if (enchantment != null && enchantment.field_77351_y != null)
|
||||
@@ -333,7 +356,6 @@
|
||||
@@ -332,7 +355,6 @@
|
||||
Items.field_151134_bR.func_92113_a(enchantment, guicontainercreative$containercreative.field_148330_a);
|
||||
}
|
||||
}
|
||||
|
@ -78,7 +69,7 @@
|
|||
Iterator<ItemStack> iterator = guicontainercreative$containercreative.field_148330_a.iterator();
|
||||
String s1 = this.field_147062_A.func_146179_b().toLowerCase();
|
||||
|
||||
@@ -365,7 +387,7 @@
|
||||
@@ -364,7 +386,7 @@
|
||||
{
|
||||
CreativeTabs creativetabs = CreativeTabs.field_78032_a[field_147058_w];
|
||||
|
||||
|
@ -87,7 +78,7 @@
|
|||
{
|
||||
GlStateManager.func_179084_k();
|
||||
this.field_146289_q.func_78276_b(I18n.func_135052_a(creativetabs.func_78024_c(), new Object[0]), 8, 6, 4210752);
|
||||
@@ -400,7 +422,7 @@
|
||||
@@ -399,7 +421,7 @@
|
||||
|
||||
for (CreativeTabs creativetabs : CreativeTabs.field_78032_a)
|
||||
{
|
||||
|
@ -96,7 +87,7 @@
|
|||
{
|
||||
this.func_147050_b(creativetabs);
|
||||
return;
|
||||
@@ -413,11 +435,13 @@
|
||||
@@ -412,11 +434,13 @@
|
||||
|
||||
private boolean func_147055_p()
|
||||
{
|
||||
|
@ -110,7 +101,7 @@
|
|||
int i = field_147058_w;
|
||||
field_147058_w = p_147050_1_.func_78021_a();
|
||||
GuiContainerCreative.ContainerCreative guicontainercreative$containercreative = (GuiContainerCreative.ContainerCreative)this.field_147002_h;
|
||||
@@ -483,12 +507,14 @@
|
||||
@@ -487,12 +511,14 @@
|
||||
|
||||
if (this.field_147062_A != null)
|
||||
{
|
||||
|
@ -126,7 +117,7 @@
|
|||
this.func_147053_i();
|
||||
}
|
||||
else
|
||||
@@ -558,20 +584,43 @@
|
||||
@@ -562,20 +588,43 @@
|
||||
}
|
||||
|
||||
super.func_73863_a(p_73863_1_, p_73863_2_, p_73863_3_);
|
||||
|
@ -171,7 +162,7 @@
|
|||
GlStateManager.func_179131_c(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
GlStateManager.func_179140_f();
|
||||
}
|
||||
@@ -633,16 +682,35 @@
|
||||
@@ -637,16 +686,35 @@
|
||||
RenderHelper.func_74520_c();
|
||||
CreativeTabs creativetabs = CreativeTabs.field_78032_a[field_147058_w];
|
||||
|
||||
|
@ -208,7 +199,7 @@
|
|||
this.field_146297_k.func_110434_K().func_110577_a(new ResourceLocation("textures/gui/container/creative_inventory/tab_" + creativetabs.func_78015_f()));
|
||||
this.func_73729_b(this.field_147003_i, this.field_147009_r, 0, 0, this.field_146999_f, this.field_147000_g);
|
||||
this.field_147062_A.func_146194_f();
|
||||
@@ -657,6 +725,14 @@
|
||||
@@ -661,6 +729,14 @@
|
||||
this.func_73729_b(i, j + (int)((float)(k - j - 17) * this.field_147067_x), 232 + (this.func_147055_p() ? 0 : 12), 0, 12, 15);
|
||||
}
|
||||
|
||||
|
@ -223,7 +214,7 @@
|
|||
this.func_147051_a(creativetabs);
|
||||
|
||||
if (creativetabs == CreativeTabs.field_78036_m)
|
||||
@@ -667,6 +743,14 @@
|
||||
@@ -671,6 +747,14 @@
|
||||
|
||||
protected boolean func_147049_a(CreativeTabs p_147049_1_, int p_147049_2_, int p_147049_3_)
|
||||
{
|
||||
|
@ -238,7 +229,7 @@
|
|||
int i = p_147049_1_.func_78020_k();
|
||||
int j = 28 * i;
|
||||
int k = 0;
|
||||
@@ -763,6 +847,8 @@
|
||||
@@ -767,6 +851,8 @@
|
||||
}
|
||||
|
||||
GlStateManager.func_179140_f();
|
||||
|
@ -247,7 +238,7 @@
|
|||
this.func_73729_b(l, i1, j, k, 28, j1);
|
||||
this.field_73735_i = 100.0F;
|
||||
this.field_146296_j.field_77023_b = 100.0F;
|
||||
@@ -789,6 +875,15 @@
|
||||
@@ -793,6 +879,15 @@
|
||||
{
|
||||
this.field_146297_k.func_147108_a(new GuiStats(this, this.field_146297_k.field_71439_g.func_146107_m()));
|
||||
}
|
||||
|
|
|
@ -13,6 +13,6 @@
|
|||
}
|
||||
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void func_178780_a(WorldRenderer p_178780_1_, float p_178780_2_)
|
||||
public void func_178780_a(VertexBuffer p_178780_1_, float p_178780_2_)
|
||||
{
|
||||
for (int i = 0; i < this.field_78254_i.length; ++i)
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/model/ModelRenderer.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/model/ModelRenderer.java
|
||||
@@ -10,7 +10,6 @@
|
||||
@@ -9,7 +9,6 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class ModelRenderer
|
||||
{
|
||||
public float field_78801_a;
|
||||
@@ -109,6 +108,7 @@
|
||||
@@ -108,6 +107,7 @@
|
||||
this.field_78798_e = p_78793_3_;
|
||||
}
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
|||
public void func_78785_a(float p_78785_1_)
|
||||
{
|
||||
if (!this.field_78807_k)
|
||||
@@ -190,6 +190,7 @@
|
||||
@@ -189,6 +189,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -24,7 +24,7 @@
|
|||
public void func_78791_b(float p_78791_1_)
|
||||
{
|
||||
if (!this.field_78807_k)
|
||||
@@ -225,6 +226,7 @@
|
||||
@@ -224,6 +225,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -32,7 +32,7 @@
|
|||
public void func_78794_c(float p_78794_1_)
|
||||
{
|
||||
if (!this.field_78807_k)
|
||||
@@ -266,6 +268,7 @@
|
||||
@@ -265,6 +267,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -3,11 +3,11 @@
|
|||
@@ -1,10 +1,7 @@
|
||||
package net.minecraft.client.model;
|
||||
|
||||
import net.minecraft.util.Vec3;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
-import net.minecraftforge.fml.relauncher.Side;
|
||||
-import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class PositionTextureVertex
|
||||
{
|
||||
public Vec3 field_78243_a;
|
||||
public Vec3d field_78243_a;
|
||||
|
|
|
@ -1,13 +1,18 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/model/TexturedQuad.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/model/TexturedQuad.java
|
||||
@@ -4,10 +4,7 @@
|
||||
import net.minecraft.client.renderer.WorldRenderer;
|
||||
import net.minecraft.client.renderer.vertex.DefaultVertexFormats;
|
||||
import net.minecraft.util.Vec3;
|
||||
-import net.minecraftforge.fml.relauncher.Side;
|
||||
-import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
@@ -7,7 +7,6 @@
|
||||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
|
||||
-@SideOnly(Side.CLIENT)
|
||||
public class TexturedQuad
|
||||
{
|
||||
public PositionTextureVertex[] field_78239_a;
|
||||
@@ -43,6 +42,7 @@
|
||||
this.field_78239_a = apositiontexturevertex;
|
||||
}
|
||||
|
||||
+ @SideOnly(Side.CLIENT)
|
||||
public void func_178765_a(VertexBuffer p_178765_1_, float p_178765_2_)
|
||||
{
|
||||
Vec3d vec3d = this.field_78239_a[1].field_78243_a.func_72444_a(this.field_78239_a[0].field_78243_a);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../src-base/minecraft/net/minecraft/client/multiplayer/ChunkProviderClient.java
|
||||
+++ ../src-work/minecraft/net/minecraft/client/multiplayer/ChunkProviderClient.java
|
||||
@@ -55,6 +55,7 @@
|
||||
@@ -52,6 +52,7 @@
|
||||
Chunk chunk = new Chunk(this.field_73235_d, p_73158_1_, p_73158_2_);
|
||||
this.field_73236_b.func_76163_a(ChunkCoordIntPair.func_77272_a(p_73158_1_, p_73158_2_), chunk);
|
||||
this.field_73237_c.add(chunk);
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
inetaddress = InetAddress.getByName(p_146367_1_);
|
||||
GuiConnecting.this.field_146371_g = NetworkManager.func_181124_a(inetaddress, p_146367_2_, GuiConnecting.this.field_146297_k.field_71474_y.func_181148_f());
|
||||
GuiConnecting.this.field_146371_g.func_150719_a(new NetHandlerLoginClient(GuiConnecting.this.field_146371_g, GuiConnecting.this.field_146297_k, GuiConnecting.this.field_146374_i));
|
||||
- GuiConnecting.this.field_146371_g.func_179290_a(new C00Handshake(47, p_146367_1_, p_146367_2_, EnumConnectionState.LOGIN));
|
||||
+ GuiConnecting.this.field_146371_g.func_179290_a(new C00Handshake(47, p_146367_1_, p_146367_2_, EnumConnectionState.LOGIN, true));
|
||||
GuiConnecting.this.field_146371_g.func_179290_a(new C00PacketLoginStart(GuiConnecting.this.field_146297_k.func_110432_I().func_148256_e()));
|
||||
- GuiConnecting.this.field_146371_g.func_179290_a(new C00Handshake(107, p_146367_1_, p_146367_2_, EnumConnectionState.LOGIN));
|
||||
+ GuiConnecting.this.field_146371_g.func_179290_a(new C00Handshake(107, p_146367_1_, p_146367_2_, EnumConnectionState.LOGIN, true));
|
||||
GuiConnecting.this.field_146371_g.func_179290_a(new CPacketLoginStart(GuiConnecting.this.field_146297_k.func_110432_I().func_148256_e()));
|
||||
}
|
||||
catch (UnknownHostException unknownhostexception)
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue