Merge pull request #26 from ENSL/release-v322
Release v322 to master branch
|
@ -0,0 +1,23 @@
|
|||
language: cpp
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- os: linux
|
||||
compiler: gcc
|
||||
script: cd main/source/linux && make
|
||||
env: OPJ_CI_ARCH=i386
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
- gcc-multilib
|
||||
- g++-multilib
|
||||
- libc6-i386
|
||||
- libcurl4-openssl-dev:i386
|
||||
- libpng12-dev:i386
|
||||
|
||||
- os: osx
|
||||
compiler: clang
|
||||
before_script:
|
||||
- export CC=clang
|
||||
- export CPLUS=clang++
|
||||
script: cd main/source/linux && make
|
|
@ -0,0 +1,674 @@
|
|||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU General Public License is a free, copyleft license for
|
||||
software and other kinds of works.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
the GNU General Public License is intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users. We, the Free Software Foundation, use the
|
||||
GNU General Public License for most of our software; it applies also to
|
||||
any other work released this way by its authors. You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, 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
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to prevent others from denying you
|
||||
these rights or asking you to surrender the rights. Therefore, you have
|
||||
certain responsibilities if you distribute copies of the software, or if
|
||||
you modify it: responsibilities to respect the freedom of others.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must pass on to the recipients the same
|
||||
freedoms that you received. You must make sure that they, too, receive
|
||||
or can get the source code. And you must show them these terms so they
|
||||
know their rights.
|
||||
|
||||
Developers that use the GNU GPL protect your rights with two steps:
|
||||
(1) assert copyright on the software, and (2) offer you this License
|
||||
giving you legal permission to copy, distribute and/or modify it.
|
||||
|
||||
For the developers' and authors' protection, the GPL clearly explains
|
||||
that there is no warranty for this free software. For both users' and
|
||||
authors' sake, the GPL requires that modified versions be marked as
|
||||
changed, so that their problems will not be attributed erroneously to
|
||||
authors of previous versions.
|
||||
|
||||
Some devices are designed to deny users access to install or run
|
||||
modified versions of the software inside them, although the manufacturer
|
||||
can do so. This is fundamentally incompatible with the aim of
|
||||
protecting users' freedom to change the software. The systematic
|
||||
pattern of such abuse occurs in the area of products for individuals to
|
||||
use, which is precisely where it is most unacceptable. Therefore, we
|
||||
have designed this version of the GPL to prohibit the practice for those
|
||||
products. If such problems arise substantially in other domains, we
|
||||
stand ready to extend this provision to those domains in future versions
|
||||
of the GPL, as needed to protect the freedom of users.
|
||||
|
||||
Finally, every program is threatened constantly by software patents.
|
||||
States should not allow patents to restrict development and use of
|
||||
software on general-purpose computers, but in those that do, we wish to
|
||||
avoid the special danger that patents applied to a free program could
|
||||
make it effectively proprietary. To prevent this, the GPL assures that
|
||||
patents cannot be used to render the program non-free.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If 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 convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Use with the GNU Affero General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU Affero General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the special requirements of the GNU Affero General Public License,
|
||||
section 13, concerning interaction through a network will apply to the
|
||||
combination as such.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU 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
|
||||
Program specifies that a certain numbered version of the GNU General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "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 PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM 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 PROGRAM (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 PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
<program> Copyright (C) <year> <name of author>
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, your program's commands
|
||||
might be different; for a GUI interface, you would use an "about box".
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU GPL, see
|
||||
<http://www.gnu.org/licenses/>.
|
||||
|
||||
The GNU General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library, you
|
||||
may consider it more useful to permit linking proprietary applications with
|
||||
the library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License. But first, please read
|
||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
117
README.md
|
@ -1,73 +1,108 @@
|
|||
# Natural Selection v3.2.1a
|
||||
This is a complete rebuild of the game [Natural Selection] for Windows and Linux. After the SteamPipe update the game remained in an pretty bad state for years, therefore I decided to recompile its sources which are provided by [Unknownworlds Entertainment]. With this update this might be the first half-life mod which achieves multi-platform support. Speaking of this you are encouraged to compile for Mac OS X. The ultimate goal is to provide a better expierence of the Natural Selection gameplay on all major platforms and a possible distribution in the future through [Steam].
|
||||
# Natural Selection v3.2.2
|
||||
|
||||
### Downloads
|
||||
Here you find the new compiled `.dlls` or `.so` files for client and server. If you just want to play or to host a server you can download them here:
|
||||
- [ns_patch_v321a.7z]
|
||||
[![Build Status](https://travis-ci.org/ENSL/NS.svg?branch=develop)](https://travis-ci.org/ENSL/NS)
|
||||
|
||||
Remember to extract them to your Half-Life/ns directory.
|
||||
This is a complete rebuild of the game [Natural Selection] for Windows, Linux, and OS X. It includes updates and fixes by pierow, Prefix, fmoraw, Bacsu, puzl, and others.
|
||||
|
||||
The offical download url for the complete version ns v3.2 is not working with firefox. Either use:
|
||||
```sh
|
||||
$ wget http://www.unknownworlds.com/files/ns/ns_install_v32.exe
|
||||
```
|
||||
or
|
||||
```sh
|
||||
$ curl -LO http://www.unknownworlds.com/files/ns/ns_install_v32.exe
|
||||
```
|
||||
or follow this link http://sllegacy.unknownworlds.com/files/ns/ns_install_v32.exe
|
||||
### Changes
|
||||
In order to make this game work for linux the old half-life engine files were replaced with the newer ones. In addtion some changes are accounted for the use of an acient glibc library. Some changes to the game itself have been made and these include:
|
||||
- The ChatPanel has been replaced in favor of the old hl chat.
|
||||
## Downloads
|
||||
|
||||
The recommended way to install the game or update an existing installation for Windows users is through the [Natural Selection Launcher](https://github.com/ENSL/NaturalLauncher/releases/) (Thanks Khelben). Simply download the installation exe or portable zip from there and run the launcher. Linux and OS X users, as well as those that want to install or patch the game manually, can find releases [here](https://github.com/ENSL/NS/releases).
|
||||
|
||||
As the game is a Half-Life mod, Steam and Half-Life installations are required to play the game.
|
||||
|
||||
A fresh install of NS from the launcher comes with updated config files containing everything you need to get playing on the standard settings most players prefer. There are also official marine and alien config files that can be uncommented so your binds change when joining the respective teams, but they are off by default as to not override any binds users wish to change within the game menus. Those that wish to use the Nine Legends competitive pack can do so through the settings in advanced options without having to download or install it.
|
||||
|
||||
If you wish to experience the game's default settings and binds from NS 3.2 you can type `exec olddefaults.cfg` in console before loading a map. A file named `backupb4old.cfg` will be saved with your previous settings if you wish to return to those after. Note that gamma ramp is no longer a working feature, so brightness will be a slightly different than it originally was, but the game was always very dark by default and still is with that config.
|
||||
|
||||
## Changes
|
||||
|
||||
Updates include:
|
||||
|
||||
- Linux and OS X support
|
||||
- Natural Selection Launcher for installing and updating the game
|
||||
- Widescreen support (now expands FOV up to 16:9 aspect instead of cutting it off)
|
||||
- Many FPS dependencies fixed, including jetpack acceleration, so the game can now be fairly played at 200+ FPS
|
||||
- Perfect jump timing no longer required for bunnyhopping (server adjustable via sv_jumpmode)
|
||||
- New minimal HUD (work in progress) and the Nine Legends HUD can be selected through advanced options or hud_style and hud_mapstyle
|
||||
- New crosshair system that can be adjusted through the advanced options and cl_cross commands (Thanks [OpenAG](https://github.com/YaLTeR/OpenAG))
|
||||
- Ambient sounds can be changed in advanced options or via cl_ambientsound
|
||||
- Raw input and sensitivity scaling options now available
|
||||
- Spectator overlay is now transparent and shows health/armor
|
||||
- Numerous bug fixes for things that broke from recent updates to Half-Life
|
||||
- The observatory has now a spherical detection like the sensory chamber
|
||||
- Removed special NS gamma since it is windows only
|
||||
|
||||
The plan is to bring the chat and the gamma back when a cross-platfrom solution can be achieved.
|
||||
|
||||
### Bugs
|
||||
With great changes come great bugs.
|
||||
- Chat input is not visible while spectating
|
||||
- [sg reload bug]
|
||||
- [FPS_Effects] FPS dependant fire rates and player physics
|
||||
- gorge's view rotates when he drops a structure from the popup menu?
|
||||
- The background of text in the menu or in popups does not look nice possible realted to the `special ns gamma`.
|
||||
## Bugs
|
||||
- Process hangs on exit sometimes
|
||||
- Arrow keys don't work for the commander
|
||||
- Chatbox eats inputs occasionally
|
||||
- Some mice experience issues with a previous fix for centering the cursor when the popupmenu is open
|
||||
- Trying to shoot the shotgun while reloading is very fickle and has poor syncronization with the server. A balance-conscientious rework is planned, but yet to be made.
|
||||
- HUD elements are stretched and/or poorly placed in widescreen. User options/commands for hud element placement are planned.
|
||||
- Clicking on the scoreboard can cause +attack to be stuck after closing the scoreboard until firing again.
|
||||
- FPS dependant fire rates and player physics. These have significantly improved with the Half-Life update and are also a non-issue now that other FPS dependency fixes are in the game and the game can be played at high frame rates, where fire rates don't vary. Very high framerates cause collision issues and other engine limitations, so an fps of 200 or 250 is recommended unless fixed.
|
||||
- Flashing available alien upgrade icons (defense, movement and sensory) tend to disappear when a player dies and respawns. The icons won't appear until the alien chooses an upgrade.
|
||||
- func_train and func_tracktrain entities don't reset to their original positions when a round has ended
|
||||
- windows server works only with the hlds tool
|
||||
|
||||
If you find more please report them!
|
||||
### Compile
|
||||
|
||||
First you will need to get the files:
|
||||
## Compiling
|
||||
|
||||
For Windows, compilation should be working if you have VS2017 installed.
|
||||
|
||||
For Linux:
|
||||
|
||||
First you need some libraries. On Ubuntu it is:
|
||||
|
||||
```sh
|
||||
$ git clone https://github.com/fmoraw/NS.git
|
||||
apt-get install build-essential git gdb gcc-multilib g++-multilib libc6-i386 libcurl4-openssl-dev:i386 libpng12-dev:i386
|
||||
```
|
||||
|
||||
Then goto `NS/main/source/linux` and use `make hl_cll` for the client and `make ns` for the server.
|
||||
Then you will need to get the files:
|
||||
```sh
|
||||
git clone https://github.com/fmoraw/NS.git
|
||||
```
|
||||
|
||||
Then to build `` and use `make hl_cll` for the client and `make ns` for the server.
|
||||
|
||||
```sh
|
||||
cd NS/main/source/linux
|
||||
```
|
||||
|
||||
For client use `make hl_cll` and for server use `make ns`
|
||||
|
||||
Make sure you have `g++-multilib` set up for x64 operating systems. For windows compilation should be working if you have VS2010 installed.
|
||||
|
||||
If you get the this error when running the app: `Fatal Error - could not load library (client.so)`, With a high chance it is because of some `UNDEFINED SYMBOLS` in the shared library. But you can check this with this command:
|
||||
|
||||
``` sh
|
||||
$ ldd -r -d client.so
|
||||
ldd -r -d client.so
|
||||
```
|
||||
|
||||
Make sure you have vgui.so copied to cl_dll folder too on Linux.
|
||||
|
||||
## Debugging
|
||||
|
||||
If you want to debug:
|
||||
```sh
|
||||
$ LD_LIBRARY_PATH=".:$LD_LIBRARY_PATH" gdb ./hl_linux r -game ns -dev -steam
|
||||
LD_LIBRARY_PATH=".:$LD_LIBRARY_PATH" gdb ./hl_linux r -game ns -dev -steam
|
||||
```
|
||||
Due to the new engine and the nature of Linux I had to make a lot of changes! You can find them with grep -Ril `@Linux`.
|
||||
|
||||
For MacOS & lldb:
|
||||
```
|
||||
DYLD_LIBRARY_PATH=".:$DYLD_LIBRARY_PATH" /Applications/Xcode.app/Contents/Developer/usr/bin/lldb -- ./hl_osx r -game ns -dev -steam -windowed
|
||||
```
|
||||
Have to use XCode's lldb to get around https://stackoverflow.com/a/33589760 (Lack of environment variables). `-windowed` as windowed mode makes it easier to deal with crashes on MacOS.
|
||||
|
||||
### Hosting a server
|
||||
|
||||
Since servers are really rare at this point in time here is a tutorial how to set up an [Natural Selection] server with [hlds].
|
||||
|
||||
1. Follow these steps: https://developer.valvesoftware.com/wiki/SteamCMD
|
||||
2. Copy the [Natural Selection] directory to steamcmd/servers/
|
||||
3. Run the game :
|
||||
```sh
|
||||
$ ./hlds_run -game ns -autoupdate +map ns_eclipse + sv_secure 1 + port 27015 + ip 127.0.0.1 +hostname "Natural Selection" +maxplayers 32
|
||||
./hlds_run -game ns -autoupdate +map ns_eclipse + sv_secure 1 + port 27015 + ip 127.0.0.1 +hostname "Natural Selection" +maxplayers 32
|
||||
```
|
||||
|
||||
If you are behind a NAT(Router) make sure to open at least those ports:
|
||||
- 27015 UDP (game transmission, pings)
|
||||
- 26900 UDP (VAC service) -- automatically increments if used in case of additional server processes
|
||||
|
@ -82,17 +117,15 @@ There is an updated version of metamod called [metamodp](http://metamod-p.source
|
|||
- [rcbot linux dlls](http://filebase.bots-united.com/index.php?act=download&id=428)
|
||||
|
||||
### Usefull links
|
||||
* [Usefull collection of ns files server addons, maps and erverything ](http://www.brywright.co.uk/downloads/files/index.php?dir=natural-selection/)
|
||||
|
||||
* [Usefull collection of ns files server addons, maps and everything ](http://www.brywright.co.uk/downloads/files/index.php?dir=natural-selection/)
|
||||
* [Great collection of ns guides/tutorials](http://www.naturalns.clanservers.com/forums/index.php?topic=5.0)
|
||||
* [rcbot downloads](http://filebase.bots-united.com/index.php?act=category&id=19)
|
||||
* [dillinger.io markdown editor](http://dillinger.io/)
|
||||
|
||||
[Natural Selection]: <http://unknownworlds.com/ns/>
|
||||
[Unknownworlds Entertainment]:<https://github.com/unknownworlds/NS>
|
||||
[ns_patch_v321a.7z]:<https://github.com/fmoraw/NS/blob/linux/ns_patch_v321a.7z?raw=true>
|
||||
[FPS_Effects]:<http://wiki.sourceruns.org/wiki/FPS_Effects>
|
||||
[Steam]: <http://store.steampowered.com/about/>
|
||||
[sg reload bug]:<https://github.com/unknownworlds/NS/issues/5>
|
||||
[hlds]:<https://developer.valvesoftware.com/wiki/Half-Life_Dedicated_Server>
|
||||
[rcbot]:<http://filebase.bots-united.com/index.php?act=category&id=19>
|
||||
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
//Alien cfg that is part of a default installation on the NS Launcher
|
||||
//Activated by pressing F2 (which also is used to join aliens)
|
||||
|
||||
//bind "mouse2" "+movement"
|
||||
//psoff
|
|
@ -6,10 +6,7 @@ bind "TAB" "+showscores"
|
|||
bind "ENTER" "messagemode"
|
||||
bind "ESCAPE" "cancelselect"
|
||||
bind "SPACE" "+jump"
|
||||
bind "'" "+moveup"
|
||||
bind "+" "sizeup"
|
||||
bind "," "impulse 123"
|
||||
bind "-" "sizedown"
|
||||
bind "." "impulse 124"
|
||||
bind "/" "impulse 125"
|
||||
bind "0" "slot10"
|
||||
|
@ -22,10 +19,6 @@ bind "6" "slot6"
|
|||
bind "7" "slot7"
|
||||
bind "8" "slot8"
|
||||
bind "9" "slot9"
|
||||
bind ";" "+mlook"
|
||||
bind "=" "sizeup"
|
||||
bind "[" "invprev"
|
||||
bind "]" "invnext"
|
||||
bind "`" "toggleconsole"
|
||||
bind "a" "+moveleft"
|
||||
bind "c" "+showmap"
|
||||
|
@ -35,13 +28,14 @@ bind "f" "impulse 100"
|
|||
bind "g" "impulse 3"
|
||||
bind "l" "impulse 105"
|
||||
bind "q" "lastinv"
|
||||
bind "r" "+reload"
|
||||
bind "r" "+movement"
|
||||
bind "s" "+back"
|
||||
bind "t" "impulse 201"
|
||||
bind "b" "impulse 11"
|
||||
bind "t" "+popupmenu"
|
||||
bind "u" "messagemode2"
|
||||
bind "v" "impulse 9"
|
||||
bind "v" "impulse 10"
|
||||
bind "w" "+forward"
|
||||
bind "x" "impulse 81"
|
||||
bind "x" "impulse 14"
|
||||
bind "y" "messagemode"
|
||||
bind "z" "impulse 80"
|
||||
bind "~" "toggleconsole"
|
||||
|
@ -52,47 +46,50 @@ bind "RIGHTARROW" "+right"
|
|||
bind "ALT" "+voicerecord"
|
||||
bind "CTRL" "+duck"
|
||||
bind "SHIFT" "+speed"
|
||||
bind "F1" "jointeamone"
|
||||
bind "F2" "jointeamtwo"
|
||||
alias "marinecfg" "exec marineofficial.cfg"
|
||||
alias "aliencfg" "exec alienofficial.cfg"
|
||||
bind "F1" "jointeamone;marinecfg"
|
||||
bind "F2" "jointeamtwo;aliencfg"
|
||||
bind "F3" "autoassign"
|
||||
bind "F4" "readyroom"
|
||||
bind "F5" "snapshot"
|
||||
bind "F6" "save quick"
|
||||
bind "F7" "load quick"
|
||||
bind "F10" "quit prompt"
|
||||
bind "INS" "+klook"
|
||||
bind "PGDN" "+lookdown"
|
||||
bind "PGUP" "+lookup"
|
||||
bind "END" "centerview"
|
||||
bind "MWHEELDOWN" "invnext"
|
||||
bind "MWHEELUP" "invprev"
|
||||
bind "MOUSE1" "+attack"
|
||||
bind "MOUSE2" "+popupmenu"
|
||||
bind "MOUSE2" "+movement"
|
||||
bind "MOUSE3" "+popupmenu"
|
||||
bind "MOUSE4" "lastinv"
|
||||
bind "PAUSE" "pause"
|
||||
_snd_mixahead "0.1"
|
||||
ati_npatch "1.0"
|
||||
ati_subdiv "2.0"
|
||||
ati_npatch "0"
|
||||
ati_subdiv "0"
|
||||
bgmvolume "1.000000"
|
||||
bottomcolor "144.889999"
|
||||
brightness "1.000000"
|
||||
brightness "5"
|
||||
cl_allowdownload "1"
|
||||
cl_allowupload "1"
|
||||
cl_autohelp "1.0"
|
||||
cl_buildmessages "1"
|
||||
cl_centerentityid "0.0"
|
||||
cl_cmdbackup "2"
|
||||
cl_cmdrate "30"
|
||||
cl_cmdrate "100"
|
||||
cl_cmhotkeys "qwerasdfzxcv"
|
||||
cl_customcrosshair "0"
|
||||
cl_dlmax "128"
|
||||
cl_download_ingame "1"
|
||||
cl_dynamiclights "1"
|
||||
cl_dynamiclights "0"
|
||||
cl_forcedefaultfov "0"
|
||||
cl_gammaramp "1"
|
||||
cl_gammaramp "0"
|
||||
cl_highdetail "1"
|
||||
cl_himodels "0"
|
||||
cl_iconb "221"
|
||||
cl_icong "149"
|
||||
cl_iconr "0"
|
||||
cl_idealpitchscale "0.8"
|
||||
cl_labelhivesight "1"
|
||||
cl_labelmaps "1"
|
||||
cl_lc "1"
|
||||
cl_logocolor "#Valve_Orange"
|
||||
|
@ -100,24 +97,26 @@ cl_logofile "lambda"
|
|||
cl_lw "1"
|
||||
cl_musicdelay "90"
|
||||
cl_musicdirectory ""
|
||||
cl_musicenabled "1.0"
|
||||
cl_musicvolume "155"
|
||||
cl_musicenabled "0"
|
||||
cl_particleinfo "0"
|
||||
cl_quickselecttime ".15"
|
||||
cl_timeout "60"
|
||||
cl_updaterate "20"
|
||||
cl_updaterate "100"
|
||||
cl_vsmoothing "0.05"
|
||||
con_color "255 180 30"
|
||||
console "1.000000"
|
||||
crosshair "1.000000"
|
||||
fps_max "72.0"
|
||||
crosshair "0"
|
||||
fps_max "250"
|
||||
fps_override "1"
|
||||
fps_modem "0.0"
|
||||
gamma "2.500000"
|
||||
gamma "3"
|
||||
gl_vsync "0"
|
||||
gl_dither "1"
|
||||
gl_flipmatrix "0"
|
||||
gl_fog "1"
|
||||
gl_monolights "0"
|
||||
gl_overbright "0"
|
||||
gl_overbright "1"
|
||||
gl_polyoffset "0.1"
|
||||
hisound "1"
|
||||
hpk_maxsize "4"
|
||||
|
@ -125,7 +124,7 @@ hud_capturemouse "1"
|
|||
hud_centerid "0"
|
||||
hud_classautokill "1"
|
||||
hud_draw "1"
|
||||
hud_fastswitch "0"
|
||||
hud_fastswitch "1"
|
||||
hud_takesshots "0"
|
||||
joystick "0"
|
||||
lookspring "0.000000"
|
||||
|
@ -137,7 +136,7 @@ m_side "0.8"
|
|||
m_yaw "0.022"
|
||||
model "barney"
|
||||
MP3FadeTime "2.0"
|
||||
MP3Volume "0.8"
|
||||
MP3Volume "0"
|
||||
mp_decals "300"
|
||||
name "NSPlayer"
|
||||
net_graph "0"
|
||||
|
@ -162,7 +161,7 @@ s_refdelay "4"
|
|||
s_refgain "0.4"
|
||||
s_rolloff "1.0"
|
||||
s_verbwet "0.25"
|
||||
sensitivity "4.960000"
|
||||
sensitivity "2"
|
||||
skin ""
|
||||
suitvolume "0.250000"
|
||||
sv_aim "0"
|
||||
|
@ -174,7 +173,14 @@ voice_enable "1"
|
|||
voice_forcemicrecord "1"
|
||||
voice_modenable "1"
|
||||
voice_scale "1"
|
||||
volume "0.800000"
|
||||
volume "0.500000"
|
||||
m_rawinput "1"
|
||||
zoom_sensitivity_ratio "1"
|
||||
lightgamma "2"
|
||||
ex_interp "0.05"
|
||||
cl_cross "1"
|
||||
rate "30000"
|
||||
cl_bob "0"
|
||||
|
||||
+mlook
|
||||
+jlook
|
||||
exec userconfig.cfg
|
||||
|
|
|
@ -178,7 +178,7 @@ entity_state_player_t gamedll Player_Encode
|
|||
DEFINE_DELTA( spectator, DT_INTEGER, 1, 1.0 ),
|
||||
DEFINE_DELTA( iuser3, DT_INTEGER, 6, 1.0 ), // Need player info for AvHCommanderModeHandler::LookupClassNameForEntity
|
||||
DEFINE_DELTA( iuser4, DT_INTEGER, 32, 1.0 ), // NS custom parameter (needs 32 for AvHSpecialSound)
|
||||
DEFINE_DELTA( fuser2, DT_FLOAT, 12, 1.0 ), // For player health (energy is predicted so this isn't needed for it)
|
||||
DEFINE_DELTA( fuser2, DT_FLOAT, 14, 1.0 ), // For player health (energy is predicted so this isn't needed for it)
|
||||
DEFINE_DELTA( vuser1[0], DT_ANGLE, 8, 1.0 ),
|
||||
DEFINE_DELTA( vuser1[1], DT_ANGLE, 8, 1.0 ),
|
||||
DEFINE_DELTA( vuser1[2], DT_ANGLE, 8, 1.0 ),
|
||||
|
|
BIN
main/dlls/ns.dll
|
@ -19,7 +19,7 @@
|
|||
"blank" "=========================="
|
||||
"+attack" "Attack (important)"
|
||||
"+use" "Use/build"
|
||||
"+reload" "Reload weapon"
|
||||
"+movement" "Reload/Alien movement"
|
||||
"impulse 100" "Flashlight"
|
||||
"+showmap" "Show map"
|
||||
"+showscores" "Display multiplayer scores"
|
||||
|
@ -93,4 +93,4 @@
|
|||
"impulse 201" "Spray logo"
|
||||
"snapshot" "Take screen shot"
|
||||
"pause" "Pause game"
|
||||
"quit" "Quit game"
|
||||
"quit" "Quit game"
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
"INS" "+klook"
|
||||
";" "+mlook"
|
||||
"c" "+showmap"
|
||||
"r" "+reload"
|
||||
"r" "+movement"
|
||||
"SHIFT" "+speed"
|
||||
"MOUSE1" "+attack"
|
||||
"MOUSE2" "+popupmenu"
|
||||
|
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 1.0 KiB |
|
@ -2,13 +2,16 @@
|
|||
// Natural Selection //
|
||||
// by Charlie Cleveland //
|
||||
////////////////////////////
|
||||
game "Natural Selection 3.2 (LUA)"
|
||||
url_info "www.natural-selection.org"
|
||||
url_dl "http://www.natural-selection.org/"
|
||||
version "v3.0"
|
||||
game "Natural Selection"
|
||||
developer "Unknown Worlds"
|
||||
developer_url "http://www.unknownworlds.com/ns/"
|
||||
url_info "http://www.unknownworlds.com/ns/"
|
||||
url_dl "http://www.unknownworlds.com/ns/view?action=files"
|
||||
icon "ns"
|
||||
version "v3.2"
|
||||
size "165000000"
|
||||
svonly "0"
|
||||
secure "1"
|
||||
secure "0"
|
||||
cldll "cl_dlls\client.dll"
|
||||
hlversion "1110"
|
||||
// How to allow training but disable "New game"?
|
||||
|
|
|
@ -11,9 +11,6 @@
|
|||
// Common between listenserver.cfg and server.cfg //
|
||||
////////////////////////////////////////////////////
|
||||
|
||||
// Default server name. Change to "Bob's Server", etc.
|
||||
hostname "Natural Selection v3.1"
|
||||
|
||||
// Must specify sv_region, or it won't show up in Steam server browser
|
||||
// 0: US East coast
|
||||
// 1: US West coast
|
||||
|
@ -72,6 +69,9 @@ sv_clienttrace 3.5
|
|||
///////////////////////////////
|
||||
sv_lan 0
|
||||
|
||||
// Forces a limit on structures on the server
|
||||
sv_structurelimit 300
|
||||
|
||||
// disable clients' ability to pause the server
|
||||
pausable 0
|
||||
|
||||
|
|
|
@ -23,20 +23,24 @@
|
|||
// - Reduced maxplayers on bast and hera for CPU reasons
|
||||
//
|
||||
ns_eon "\minplayers\16\maxplayers\32\"
|
||||
ns_lucid "\minplayers\10\maxplayers\32\"
|
||||
ns_metal "\minplayers\16\maxplayers\32\"
|
||||
ns_caged "\minplayers\16\maxplayers\32\"
|
||||
co_sava "\minplayers\6\maxplayers\20\"
|
||||
co_angst "\minplayers\4\maxplayers\20\"
|
||||
ns_hera "\minplayers\16\maxplayers\24\"
|
||||
ns_lost "\minplayers\16\maxplayers\32\"
|
||||
ns_machina "\minplayers\16\maxplayers\24\"
|
||||
ns_nothing "\minplayers\16\maxplayers\32\"
|
||||
co_niveus "\minplayers\4\maxplayers\20\"
|
||||
co_faceoff "\minplayers\0\maxplayers\18\"
|
||||
co_daimos "\minplayers\8\maxplayers\20\"
|
||||
ns_bast "\minplayers\14\maxplayers\28\"
|
||||
ns_origin "\minplayers\16\maxplayers\32\"
|
||||
ns_shiva "\minplayers\16\maxplayers\32\"
|
||||
co_kestrel "\minplayers\8\maxplayers\20\"
|
||||
ns_tanith "\minplayers\16\maxplayers\32\"
|
||||
co_umbra "\minplayers\8\maxplayers\20\"
|
||||
ns_nancy "\minplayers\14\maxplayers\32\"
|
||||
ns_veil "\minplayers\16\maxplayers\32\"
|
||||
co_core "\minplayers\0\maxplayers\20\"
|
||||
|
|
|
@ -3,16 +3,17 @@ co_sava by Mendasp
|
|||
|
||||
Map information:
|
||||
----------------
|
||||
NS 3.0 version
|
||||
NS 3.1 version
|
||||
|
||||
Credits:
|
||||
--------
|
||||
The custom sounds used are from Marr's Ambience Pack
|
||||
Nanotech texture by spacer
|
||||
Scrolling smoke texture by Elcle
|
||||
Water tank model by CoolCookieCooks
|
||||
Water tank and broken RT models by CoolCookieCooks
|
||||
|
||||
Thanks to:
|
||||
----------
|
||||
Lordy
|
||||
tankefugl
|
||||
tankefugl
|
||||
Crispy
|
|
@ -0,0 +1,27 @@
|
|||
co_umbra by Kalessin
|
||||
|
||||
co_umbra is a large combat which features long, wide corridors with moderate cover and high ceilings. Despite the apparent advantage the marines may have, the aliens can utilise the extensive ventilation network and the many concealed ambush points to hamper the marine's progress. There are three routes linking the alien half of the map to the marine side, each route converges in the centre of the map where most of the action takes place. Because of the size of the map, it is important that the marines play aggressively to be able to secure a victory.
|
||||
|
||||
Object names Objects/Maxobjs Memory / Maxmem Fullness
|
||||
------------ --------------- --------------- --------
|
||||
models 145/400 9280/25600 (36.3%)
|
||||
planes 4662/32768 93240/655360 (14.2%)
|
||||
vertexes 12197/65535 146364/786420 (18.6%)
|
||||
nodes 5059/32767 121416/786408 (15.4%)
|
||||
texinfos 5886/32767 235440/1310680 (18.0%)
|
||||
faces 8775/65535 175500/1310700 (13.4%)
|
||||
clipnodes 10320/32767 82560/262136 (31.5%)
|
||||
leaves 2581/8192 72268/229376 (31.5%)
|
||||
marksurfaces 11684/65535 23368/131070 (17.8%)
|
||||
surfedges 40389/512000 161556/2048000 ( 7.9%)
|
||||
edges 21051/256000 84204/1024000 ( 8.2%)
|
||||
texdata [variable] 4900/4194304 ( 0.1%)
|
||||
lightdata [variable] 1560849/6291456 (24.8%)
|
||||
visdata [variable] 53694/2097152 ( 2.6%)
|
||||
entdata [variable] 56849/524288 (10.8%)
|
||||
86 textures referenced
|
||||
=== Total BSP file data space used: 2881488 bytes ===
|
||||
|
||||
Many thanks to everyone who helped test this map, it has come a long way since its initial release and none of this would have been possible without you!
|
||||
|
||||
Thankyou!
|
|
@ -1,3 +1,7 @@
|
|||
|
||||
|
||||
|
||||
|
||||
=====================================================================
|
||||
Natural-Selection Map Spec Sheet
|
||||
=====================================================================
|
||||
|
@ -6,9 +10,10 @@
|
|||
Title : Altair Underwater Mining Facility
|
||||
Filename : ns_altair.bsp
|
||||
Author : Paul "KungFuDiscoMonkey" Traylor
|
||||
Michael "Olmy" Schouten
|
||||
EMail : kungfudiscomonkey@gmail.com
|
||||
URL : http://kungfudiscomonkey.net
|
||||
Date : February 21, 2005
|
||||
Date : November 05, 2006
|
||||
|
||||
------Play Information-----------------------------------------------
|
||||
|
||||
|
@ -18,15 +23,11 @@ How Many Players: 32
|
|||
------Map Information------------------------------------------------
|
||||
|
||||
New Textures : Yes (ns_altair.wad embedded in BSP)
|
||||
Some Textures taken from Poke646 by Marc Schröder
|
||||
Button Textures, damaged door, and new monitors by
|
||||
Samejima
|
||||
Some Textures taken from Poke646 by Marc Schröder
|
||||
Button Textures, damaged door, and new monitors by Samejima
|
||||
New Sounds : No
|
||||
New Skybox : Yes based on deepsea1
|
||||
by Darc
|
||||
http://telefragged.com/soup/
|
||||
New Models : Not yet
|
||||
New Prefabs : Yes Tube Container by KungFuSquirrel
|
||||
New Skybox : Yes based on deepsea1 by Darc (http://telefragged.com/soup/)
|
||||
New Models : No
|
||||
|
||||
------Construction---------------------------------------------------
|
||||
|
||||
|
@ -37,52 +38,7 @@ Editor(s) used : Valve Hammer Editor 3.5
|
|||
Compile Machine : 3 Ghz P4, 1 gb RAM
|
||||
Compile time : ~1 hour
|
||||
|
||||
------Changelog------------------------------------------------------
|
||||
v1-6 OLD Versions
|
||||
|
||||
v7 (11/8/04)
|
||||
Version number incrimented by request to reflect the massive number of improvemts since the b5 version of the map
|
||||
Added vent from Omega to Zeta with two exits into Phi
|
||||
Added vent from Muck Pump to Parts Room RT
|
||||
Rspeed optimizations
|
||||
Adjustments to Surface Umbilical to reduce LOS
|
||||
Adjustments to MS top entrance
|
||||
New monitor textures by Samejima
|
||||
Covered up pit in Omega
|
||||
More details
|
||||
New minimap built for new changes to rooms
|
||||
|
||||
v7b (1/29/05)
|
||||
Removed Diving tanks and connected Nanite Regulation and Settling tanks
|
||||
Rerouted path from Settling tanks into Communications
|
||||
Moved weldable to Muck Pump
|
||||
Optimized Sub Bay
|
||||
Moved node from outside Parts room into parts room
|
||||
|
||||
v7c (2/10/05)
|
||||
Moved Parts Room RT to Sigma Test Site
|
||||
Added new info_locations to help navigation and direction
|
||||
Split up Life Support info_location
|
||||
Split up Sub Bay info_location
|
||||
Removed weldable door
|
||||
Reopened path between Sub Bay and Parts Room
|
||||
Moved some alien spawns into Life Support instead of being a bit outside the hive room
|
||||
|
||||
v7d (2/14/05)
|
||||
Played with HLRAD compile settings a bit
|
||||
Added a few new lights to sewer
|
||||
Misc detail to parts room and Station Monitoring
|
||||
Small tweek to fix minimap glitch till I have time to do a full sprite again
|
||||
Added new vent weldables
|
||||
|
||||
v7e (2/21/05)
|
||||
Reopened route from Settling Tanks to Consistancy
|
||||
Combined Station Monitoring and Sub Refueling node into one node at SM-Power.
|
||||
Moved Settling Tank node back to Nanite Regulation
|
||||
Added small ledge in sub bay to help get around pool
|
||||
Fixed custom minimap.
|
||||
|
||||
|
||||
|
||||
------Additional Info------------------------------------------------
|
||||
|
||||
Any feedback or suggestions, please send them to kungfudiscomonkey@gmail.com
|
||||
|
@ -91,15 +47,21 @@ Any feedback or suggestions, please send them to kungfudiscomonkey@gmail.com
|
|||
|
||||
I give NO permission whatsoever to decompile this map or use the textures in any other mapping project. Also, please no using ripent or similar to modify the map, if you want something changed, email me about it and if i consider it to be valid i'll sort it.
|
||||
|
||||
------And Finally----------------------------------------------------
|
||||
------Thanks---------------------------------------------------------
|
||||
|
||||
Thanks to the NS Dev team for making this great mod that has kept me from doing as much homework as I should.
|
||||
|
||||
Thanks to the NS Playtester team for helping me with good feedback and taking time to disuss with me the changes and updates to help make the map that much better.
|
||||
|
||||
Thanks Plaguebearer for taking my mediocre layout and turning it into something awsome. Without his help you wouldn't be playing this map.
|
||||
Thanks Plaguebearer for taking my mediocre layout and turning it into something awsome which was the layout for the first Altair in b5.
|
||||
|
||||
Thanks to TyrNemesis^ for helping me walk around the map and pointing out balance issues and node placement issues and generally helping to make Altair even better. Half the reason you are reading this file is because this guy helped make Altair what it is.
|
||||
Thanks to TyrNemesis^ for helping me walk around the map and pointing out balance issues and node placement issues and generally helping to make Altair even better through 3.0.
|
||||
|
||||
------Dedication-----------------------------------------------------
|
||||
Altair is dedicated to my friends from Wake Christian Academy, Cary Alliance Church, and Grace Community Church who will never realize how much their lives have impacted mine and made me a better person because of it.
|
||||
Thanks to kmart and routerbox for helping me adjust the layout to be more condusive to competitive play.
|
||||
|
||||
Thanks to JazzX, Zephor, and Ken for being the top three playtesters when it comes to giving well thought out and detailed feedback.
|
||||
|
||||
Thanks to Olmy for really pushing me to improve Altair with several new ideas which lead me to rebuild several areas of the map to push Altair to be much greater visually and for building a new Life Support and Sub Bay (especially the new sub)
|
||||
|
||||
------Finally--------------------------------------------------------
|
||||
This map has been brought to you by the color purple. Enjoy.
|
|
@ -1,6 +1,28 @@
|
|||
ns_eon version 9
|
||||
ns_eon version 11
|
||||
|
||||
released (27/05/05) Note : v9 was compiled without -extra in rad to save time.
|
||||
released (16/09/05)
|
||||
|
||||
-New console in Marine Start and new boxes.
|
||||
-Clipped the door below the vent in Maintenance.
|
||||
-Minor aesthetic changes in Gunpods.
|
||||
|
||||
v10a changelog (10/08/05)
|
||||
|
||||
-New vent is now alot easier to maneuvre inside
|
||||
-Slight change to Coolant Monitoring's geometry (semi alcove type thing :/).
|
||||
-Gunpods no longer has a wall divide, and the dimensions of the room have been reduced,
|
||||
(mostly width) and the rt position has been moved to the side.
|
||||
|
||||
v10 changelog (27/07/05)
|
||||
|
||||
-New node layout with 9 nodes (thanks jazzx!)
|
||||
-Engine walkway vent now extends to the node room on eastern side.
|
||||
|
||||
*Known issues - New vent is a bit awkward to maneuvre inside.
|
||||
|
||||
v9 changelog (26/05/05)
|
||||
|
||||
Note : v9 was compiled without -extra in rad to save time.
|
||||
Visual quality of the lighting is slightly reduced as a result.
|
||||
|
||||
-Extended Core Monitoring closer towards Core, so that the joining corridor is shorter, and so sieging is easier.
|
||||
|
@ -106,4 +128,7 @@ v4 changelog (26/1/05):
|
|||
-Slightly changed layout in Core Monitoring to reduce line of sight problems.
|
||||
-Fixed a stuck issue in bridge (you would get stuck on light fixtures).
|
||||
-Nearly every vent that could not accomodate two skulks side by side now can.
|
||||
-Included a txt file. :)
|
||||
-Included a txt file. :)
|
||||
|
||||
Thanks:
|
||||
JazzX for unfailing support with eon. Zephor, and other playtesters for their input.
|
|
@ -0,0 +1,11 @@
|
|||
gfx/env/metal_bk.tga
|
||||
gfx/env/metal_dn.tga
|
||||
gfx/env/metal_ft.tga
|
||||
gfx/env/metal_lf.tga
|
||||
gfx/env/metal_rt.tga
|
||||
gfx/env/metal_up.tga
|
||||
maps/ns_metal.bsp
|
||||
maps/ns_metal.txt
|
||||
sprites/minimaps/ns_metal.spr
|
||||
sprites/ns_metal/flare3metal.spr
|
||||
ns_metal.wad
|
|
@ -1,4 +1,4 @@
|
|||
Metal 27-8-2004
|
||||
Metal 17-8-2005
|
||||
===============================================
|
||||
|
||||
Natural Selection map : Metal (ns_metal.bsp)
|
||||
|
@ -46,6 +46,20 @@ Changelog :
|
|||
|
||||
-------------------------
|
||||
|
||||
+ update-14
|
||||
|
||||
* Changed MS-start sign texture.
|
||||
|
||||
-------------------------
|
||||
|
||||
+ update-13
|
||||
|
||||
* Made MS-start smaller.
|
||||
* Fixed 2 location names.
|
||||
* Added more cover.
|
||||
|
||||
-------------------------
|
||||
|
||||
+ update-12
|
||||
|
||||
* Bug Fixes.
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
//Marine cfg that is part of a default installation on the NS Launcher
|
||||
//Activated by pressing F1 (which also is used to join marines)
|
||||
|
||||
|
||||
//bind "mouse2" "impulse 10"
|
||||
//pson
|
|
@ -43,4 +43,4 @@ localmsg "NS-HLTV Broadcast" 90 5 -1 0.825 FFA000FF
|
|||
|
||||
// these commands will be executed on connecting spectator client and may be used
|
||||
// to adjust settings for HLTV (for example voice parameters)
|
||||
signoncommands "voice_scale 2; voice_overdrive 16; volume 0.5; echo Voice adjusted for NS-HLTV"
|
||||
// signoncommands "voice_scale 2; voice_overdrive 16; volume 0.5; echo Voice adjusted for NS-HLTV"
|
||||
|
|
After Width: | Height: | Size: 1.0 KiB |
BIN
main/ns_eon.wad
|
@ -0,0 +1,71 @@
|
|||
writecfg b4oldbinds
|
||||
unbindall
|
||||
bind "TAB" "+showscores"
|
||||
bind "ENTER" "messagemode"
|
||||
bind "ESCAPE" "cancelselect"
|
||||
bind "SPACE" "+jump"
|
||||
bind "'" "+moveup"
|
||||
bind "+" "sizeup"
|
||||
bind "," "impulse 123"
|
||||
bind "-" "sizedown"
|
||||
bind "." "impulse 124"
|
||||
bind "/" "impulse 125"
|
||||
bind "0" "slot10"
|
||||
bind "1" "slot1"
|
||||
bind "2" "slot2"
|
||||
bind "3" "slot3"
|
||||
bind "4" "slot4"
|
||||
bind "5" "slot5"
|
||||
bind "6" "slot6"
|
||||
bind "7" "slot7"
|
||||
bind "8" "slot8"
|
||||
bind "9" "slot9"
|
||||
bind ";" "+mlook"
|
||||
bind "=" "sizeup"
|
||||
bind "[" "invprev"
|
||||
bind "]" "invnext"
|
||||
bind "`" "toggleconsole"
|
||||
bind "a" "+moveleft"
|
||||
bind "c" "+showmap"
|
||||
bind "d" "+moveright"
|
||||
bind "e" "+use"
|
||||
bind "f" "impulse 100"
|
||||
bind "g" "impulse 3"
|
||||
bind "l" "impulse 105"
|
||||
bind "q" "lastinv"
|
||||
bind "r" "+movement"
|
||||
bind "s" "+back"
|
||||
bind "t" "impulse 201"
|
||||
bind "u" "messagemode2"
|
||||
bind "v" "impulse 9"
|
||||
bind "w" "+forward"
|
||||
bind "x" "impulse 14"
|
||||
bind "y" "messagemode"
|
||||
bind "z" "impulse 7"
|
||||
bind "~" "toggleconsole"
|
||||
bind "UPARROW" "+forward"
|
||||
bind "DOWNARROW" "+back"
|
||||
bind "LEFTARROW" "+left"
|
||||
bind "RIGHTARROW" "+right"
|
||||
bind "ALT" "+voicerecord"
|
||||
bind "CTRL" "+duck"
|
||||
bind "SHIFT" "+speed"
|
||||
bind "F1" "jointeamone"
|
||||
bind "F2" "jointeamtwo"
|
||||
bind "F3" "autoassign"
|
||||
bind "F4" "readyroom"
|
||||
bind "F5" "snapshot"
|
||||
bind "F6" "save quick"
|
||||
bind "F7" "load quick"
|
||||
bind "F10" "quit prompt"
|
||||
bind "INS" "+klook"
|
||||
bind "PGDN" "+lookdown"
|
||||
bind "PGUP" "+lookup"
|
||||
bind "END" "centerview"
|
||||
bind "MWHEELDOWN" "invnext"
|
||||
bind "MWHEELUP" "invprev"
|
||||
bind "MOUSE1" "+attack"
|
||||
bind "MOUSE2" "+popupmenu"
|
||||
bind "MOUSE3" "+popupmenu"
|
||||
bind "MOUSE4" "lastinv"
|
||||
bind "PAUSE" "pause"
|
|
@ -0,0 +1,189 @@
|
|||
// This file is overwritten whenever you change your user settings in the game.
|
||||
// Add custom configurations to the file "userconfig.cfg".
|
||||
|
||||
//Backs up current cfg before proceeding.
|
||||
writecfg "backupb4old"
|
||||
|
||||
//NS 3.2 official config.cfg
|
||||
unbindall
|
||||
bind "TAB" "+showscores"
|
||||
bind "ENTER" "messagemode"
|
||||
bind "ESCAPE" "cancelselect"
|
||||
bind "SPACE" "+jump"
|
||||
bind "'" "+moveup"
|
||||
bind "+" "sizeup"
|
||||
bind "," "impulse 123"
|
||||
bind "-" "sizedown"
|
||||
bind "." "impulse 124"
|
||||
bind "/" "impulse 125"
|
||||
bind "0" "slot10"
|
||||
bind "1" "slot1"
|
||||
bind "2" "slot2"
|
||||
bind "3" "slot3"
|
||||
bind "4" "slot4"
|
||||
bind "5" "slot5"
|
||||
bind "6" "slot6"
|
||||
bind "7" "slot7"
|
||||
bind "8" "slot8"
|
||||
bind "9" "slot9"
|
||||
bind ";" "+mlook"
|
||||
bind "=" "sizeup"
|
||||
bind "[" "invprev"
|
||||
bind "]" "invnext"
|
||||
bind "`" "toggleconsole"
|
||||
bind "a" "+moveleft"
|
||||
bind "c" "+showmap"
|
||||
bind "d" "+moveright"
|
||||
bind "e" "+use"
|
||||
bind "f" "impulse 100"
|
||||
bind "g" "impulse 3"
|
||||
bind "l" "impulse 105"
|
||||
bind "q" "lastinv"
|
||||
bind "r" "+movement"
|
||||
bind "s" "+back"
|
||||
bind "t" "impulse 201"
|
||||
bind "u" "messagemode2"
|
||||
bind "v" "impulse 9"
|
||||
bind "w" "+forward"
|
||||
bind "x" "impulse 14"
|
||||
bind "y" "messagemode"
|
||||
bind "z" "impulse 7"
|
||||
bind "~" "toggleconsole"
|
||||
bind "UPARROW" "+forward"
|
||||
bind "DOWNARROW" "+back"
|
||||
bind "LEFTARROW" "+left"
|
||||
bind "RIGHTARROW" "+right"
|
||||
bind "ALT" "+voicerecord"
|
||||
bind "CTRL" "+duck"
|
||||
bind "SHIFT" "+speed"
|
||||
bind "F1" "jointeamone"
|
||||
bind "F2" "jointeamtwo"
|
||||
bind "F3" "autoassign"
|
||||
bind "F4" "readyroom"
|
||||
bind "F5" "snapshot"
|
||||
bind "F6" "save quick"
|
||||
bind "F7" "load quick"
|
||||
bind "F10" "quit prompt"
|
||||
bind "INS" "+klook"
|
||||
bind "PGDN" "+lookdown"
|
||||
bind "PGUP" "+lookup"
|
||||
bind "END" "centerview"
|
||||
bind "MWHEELDOWN" "invnext"
|
||||
bind "MWHEELUP" "invprev"
|
||||
bind "MOUSE1" "+attack"
|
||||
bind "MOUSE2" "+popupmenu"
|
||||
bind "MOUSE3" "+popupmenu"
|
||||
bind "MOUSE4" "lastinv"
|
||||
bind "PAUSE" "pause"
|
||||
_snd_mixahead "0.1"
|
||||
ati_npatch "1.0"
|
||||
ati_subdiv "2.0"
|
||||
bgmvolume "1.000000"
|
||||
bottomcolor "144.889999"
|
||||
brightness "1.000000"
|
||||
cl_allowdownload "1"
|
||||
cl_allowupload "1"
|
||||
cl_autohelp "1.0"
|
||||
cl_buildmessages "1"
|
||||
cl_centerentityid "0.0"
|
||||
cl_cmdbackup "2"
|
||||
cl_cmdrate "30"
|
||||
cl_cmhotkeys "qwerasdfzxcv"
|
||||
cl_customcrosshair "1"
|
||||
cl_dlmax "128"
|
||||
cl_download_ingame "1"
|
||||
cl_dynamiclights "1"
|
||||
cl_forcedefaultfov "0"
|
||||
cl_gammaramp "1"
|
||||
cl_highdetail "1"
|
||||
cl_himodels "0"
|
||||
cl_iconb "221"
|
||||
cl_icong "149"
|
||||
cl_iconr "0"
|
||||
cl_idealpitchscale "0.8"
|
||||
cl_labelhivesight "1"
|
||||
cl_labelmaps "1"
|
||||
cl_lc "1"
|
||||
cl_logocolor "#Valve_Orange"
|
||||
cl_logofile "lambda"
|
||||
cl_lw "1"
|
||||
cl_musicdelay "90"
|
||||
cl_musicdirectory ""
|
||||
cl_musicenabled "1.0"
|
||||
cl_musicvolume "155"
|
||||
cl_particleinfo "0"
|
||||
cl_quickselecttime ".15"
|
||||
cl_timeout "60"
|
||||
cl_updaterate "20"
|
||||
cl_vsmoothing "0.05"
|
||||
con_color "255 180 30"
|
||||
console "1.000000"
|
||||
crosshair "1.000000"
|
||||
fps_max "72.0"
|
||||
fps_modem "0.0"
|
||||
gamma "2.500000"
|
||||
gl_dither "1"
|
||||
gl_flipmatrix "0"
|
||||
gl_fog "1"
|
||||
gl_monolights "0"
|
||||
gl_overbright "0"
|
||||
gl_polyoffset "0.1"
|
||||
hisound "1"
|
||||
hpk_maxsize "4"
|
||||
hud_capturemouse "1"
|
||||
hud_centerid "0"
|
||||
hud_classautokill "1"
|
||||
hud_draw "1"
|
||||
hud_fastswitch "0"
|
||||
hud_takesshots "0"
|
||||
joystick "0"
|
||||
lookspring "0.000000"
|
||||
lookstrafe "0.000000"
|
||||
m_filter "0"
|
||||
m_forward "1"
|
||||
m_pitch "0.022000"
|
||||
m_side "0.8"
|
||||
m_yaw "0.022"
|
||||
model "barney"
|
||||
MP3FadeTime "2.0"
|
||||
MP3Volume "0.8"
|
||||
mp_decals "300"
|
||||
name "NSPlayer"
|
||||
net_graph "0"
|
||||
net_graphpos "1"
|
||||
net_scale "5"
|
||||
r_bmodelhighfrac "5.0"
|
||||
r_detailtextures "0"
|
||||
s_a3d "0.0"
|
||||
s_automax_distance "30.0"
|
||||
s_automin_distance "2.0"
|
||||
s_bloat "2.0"
|
||||
s_distance "60"
|
||||
s_doppler "0.0"
|
||||
s_eax "0.0"
|
||||
s_leafnum "0"
|
||||
s_max_distance "1000.0"
|
||||
s_min_distance "8.0"
|
||||
s_numpolys "200"
|
||||
s_polykeep "1000000000"
|
||||
s_polysize "10000000"
|
||||
s_refdelay "4"
|
||||
s_refgain "0.4"
|
||||
s_rolloff "1.0"
|
||||
s_verbwet "0.25"
|
||||
sensitivity "4.960000"
|
||||
skin ""
|
||||
suitvolume "0.250000"
|
||||
sv_aim "0"
|
||||
sv_voiceenable "1"
|
||||
team ""
|
||||
topcolor "151.169998"
|
||||
viewsize "120.000000"
|
||||
voice_enable "1"
|
||||
voice_forcemicrecord "1"
|
||||
voice_modenable "1"
|
||||
voice_scale "1"
|
||||
volume "0.800000"
|
||||
+mlook
|
||||
+jlook
|
||||
exec userconfig.cfg
|
|
@ -1,5 +1,5 @@
|
|||
--------------------------------------------------------------------------
|
||||
- Natural Selection - http://www.naturalselection.com - v3.1 - 05/14/05 -
|
||||
- Natural Selection - http://www.naturalselection.com - v3.2 - 20/02/06 -
|
||||
--------------------------------------------------------------------------
|
||||
|
||||
The NS Team
|
||||
|
@ -12,13 +12,7 @@ Jon Chapman
|
|||
[ "Merkaba" :: level designer, level tech R&D, 2D art - ns_hera ]
|
||||
|
||||
Joel Rubicam
|
||||
[ "grepdashv" :: qa lead ]
|
||||
|
||||
Florian Schwarzer
|
||||
[ "Nemesis Zero" :: project manager ]
|
||||
|
||||
Karl Patrick
|
||||
[ "Cagey" :: programmer ]
|
||||
[ "grepdashv" :: tools ]
|
||||
|
||||
David Monks
|
||||
[ "MaDMaXX" :: sound effects ]
|
||||
|
@ -26,18 +20,14 @@ David Monks
|
|||
Harry Walsh
|
||||
[ "puzl" :: programmer ]
|
||||
|
||||
Mark Windle
|
||||
[ "Zunni" :: relations manager ]
|
||||
|
||||
Petter Rønningen
|
||||
[ "tankefugl" :: programmer ]
|
||||
|
||||
Joseph Stone
|
||||
[ "Alpha|UK" :: 3D art ]
|
||||
|
||||
Ozgur Yigit
|
||||
[ "gazOzz" :: 2D art ]
|
||||
Jim Olson
|
||||
[ "JazzX" :: QA Lead ]
|
||||
|
||||
Jason Lange
|
||||
[ "J" :: artist ]
|
||||
|
||||
Retired Members
|
||||
-------------
|
||||
|
@ -60,6 +50,12 @@ Alex Boylan
|
|||
Phil Mayfield
|
||||
[ "Def one" :: animator - marine and alien view models ]
|
||||
|
||||
Florian Schwarzer
|
||||
[ "Nemesis Zero" :: project manager ]
|
||||
|
||||
Karl Patrick
|
||||
[ "Cagey" :: programmer ]
|
||||
|
||||
Joe Vaughan
|
||||
[ "joev" :: development manager, code - and server monkey ]
|
||||
|
||||
|
@ -82,6 +78,12 @@ Tom Grim
|
|||
[ "ElvenThief" :: programmer ]
|
||||
|
||||
|
||||
Joseph Stone
|
||||
[ "Alpha|UK" :: 3D art ]
|
||||
|
||||
Ozgur Yigit
|
||||
[ "gazOzz" :: 2D art ]
|
||||
|
||||
Level Designers
|
||||
-------------
|
||||
|
||||
|
@ -140,6 +142,9 @@ Craig Bryson
|
|||
[ "Drath" :: co_niveus ]
|
||||
|
||||
|
||||
Mark Windle
|
||||
[ "Zunni" :: relations manager ]
|
||||
|
||||
Other Credits
|
||||
-------------
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
"2"
|
||||
{
|
||||
"label" "#Menu_ReadyRoom"
|
||||
"command" "engine readyroom"
|
||||
"command" "engine menureadyroom"
|
||||
"OnlyInGame" "1"
|
||||
}
|
||||
"3"
|
||||
|
@ -30,13 +30,13 @@
|
|||
// "command" "OpenLoadGameDialog"
|
||||
// "notmulti" "1"
|
||||
// }
|
||||
"6"
|
||||
{
|
||||
"label" "#GameUI_GameMenu_SaveGame"
|
||||
"command" "OpenSaveGameDialog"
|
||||
"notmulti" "1"
|
||||
"OnlyInGame" "1"
|
||||
}
|
||||
// "6"
|
||||
// {
|
||||
// "label" "#GameUI_GameMenu_SaveGame"
|
||||
// "command" "OpenSaveGameDialog"
|
||||
// "notmulti" "1"
|
||||
// "OnlyInGame" "1"
|
||||
// }
|
||||
"7"
|
||||
{
|
||||
"label" ""
|
||||
|
@ -45,20 +45,27 @@
|
|||
}
|
||||
"8"
|
||||
{
|
||||
"label" "#GameUI_GameMenu_FindServers"
|
||||
"command" "OpenServerBrowser"
|
||||
"label" "#GameUI_GameMenu_PlayerList"
|
||||
"command" "OpenPlayerListDialog"
|
||||
"OnlyInGame" "1"
|
||||
"notmulti" "0"
|
||||
}
|
||||
"9"
|
||||
{
|
||||
"label" "#GameUI_GameMenu_CreateServer"
|
||||
"command" "OpenCreateMultiplayerGameDialog"
|
||||
}
|
||||
// "10"
|
||||
// {
|
||||
// "name" "LoadDemo"
|
||||
// "label" "#GameUI_GameMenu_PlayDemo"
|
||||
// "command" "OpenLoadDemoDialog"
|
||||
// }
|
||||
"10"
|
||||
{
|
||||
"label" "#GameUI_GameMenu_FindServers"
|
||||
"command" "OpenServerBrowser"
|
||||
}
|
||||
//"11"
|
||||
//{
|
||||
//"name" "LoadDemo"
|
||||
//"label" "#GameUI_GameMenu_PlayDemo"
|
||||
//"command" "OpenLoadDemoDialog"
|
||||
//}
|
||||
"11"
|
||||
{
|
||||
"label" ""
|
||||
|
@ -80,4 +87,4 @@
|
|||
"label" "#GameUI_GameMenu_Quit"
|
||||
"command" "Quit"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
////////////////////////////////////////////////////
|
||||
|
||||
// Default server name. Change to "Bob's Server", etc.
|
||||
hostname "Natural Selection v3.1"
|
||||
hostname "Natural Selection v3.2"
|
||||
|
||||
// Must specify sv_region, or it won't show up in Steam server browser
|
||||
// 0: US East coast
|
||||
|
@ -84,6 +84,9 @@ mp_timelimit 60
|
|||
///////////////////////////////
|
||||
sv_lan 0
|
||||
|
||||
// Forces a limit on structures on the server
|
||||
sv_structurelimit 300
|
||||
|
||||
// disable clients' ability to pause the server
|
||||
pausable 0
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
|
||||
|
||||
// Half-Life Server Configuration Layout Script (stores last settings chosen, too)
|
||||
// File generated: Thu Mar 03 11:29:18 PM
|
||||
// File generated: Sun May 07 10:30:06 AM
|
||||
//
|
||||
//
|
||||
// Cvar - Setting
|
||||
|
@ -52,7 +52,7 @@ DESCRIPTION SERVER_OPTIONS
|
|||
{
|
||||
"#Valve_Hostname"
|
||||
{ STRING }
|
||||
{ "Natural Selection 3.1 Server" }
|
||||
{ "Natural Selection 3.2 Server" }
|
||||
}
|
||||
|
||||
"maxplayers"
|
||||
|
|
|
@ -16,8 +16,8 @@
|
|||
<Configurations>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
|
||||
IntermediateDirectory="$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="FALSE">
|
||||
|
@ -88,8 +88,8 @@
|
|||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
|
||||
IntermediateDirectory="$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="FALSE">
|
||||
|
|
|
@ -103,7 +103,7 @@ void WeaponsResource :: LoadAllWeaponSprites( void )
|
|||
|
||||
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
inline void LoadWeaponSprite( client_sprite_t* ptr, HSPRITE& sprite, wrect_t& bounds )
|
||||
inline void LoadWeaponSprite( client_sprite_t* ptr, AVHHSPRITE& sprite, wrect_t& bounds )
|
||||
{
|
||||
if( ptr )
|
||||
{
|
||||
|
@ -300,7 +300,7 @@ void WeaponsResource::SetAmmo( int iId, int iCount )
|
|||
|
||||
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
HSPRITE* WeaponsResource::GetAmmoPicFromWeapon( int iAmmoId, wrect_t& rect )
|
||||
AVHHSPRITE* WeaponsResource::GetAmmoPicFromWeapon( int iAmmoId, wrect_t& rect )
|
||||
{
|
||||
for ( int i = 0; i < MAX_WEAPONS; i++ )
|
||||
{
|
||||
|
@ -533,7 +533,7 @@ void WeaponsResource :: SelectSlot( int iSlot, int fAdvance, int iDirection )
|
|||
|
||||
int giBucketHeight, giBucketWidth, giABHeight, giABWidth; // Ammo Bar width and height
|
||||
|
||||
HSPRITE ghsprBuckets; // Sprite for top row of weapons menu
|
||||
AVHHSPRITE ghsprBuckets; // Sprite for top row of weapons menu
|
||||
|
||||
DECLARE_MESSAGE(m_Ammo, CurWeapon ); // Current weapon and clip
|
||||
DECLARE_MESSAGE(m_Ammo, WeaponList); // new weapon type
|
||||
|
|
|
@ -38,15 +38,15 @@ struct WEAPON
|
|||
|
||||
int iCount; // # of itesm in plist
|
||||
|
||||
HSPRITE hActive;
|
||||
AVHHSPRITE hActive;
|
||||
wrect_t rcActive;
|
||||
HSPRITE hInactive;
|
||||
AVHHSPRITE hInactive;
|
||||
wrect_t rcInactive;
|
||||
HSPRITE hAmmo;
|
||||
AVHHSPRITE hAmmo;
|
||||
wrect_t rcAmmo;
|
||||
HSPRITE hAmmo2;
|
||||
AVHHSPRITE hAmmo2;
|
||||
wrect_t rcAmmo2;
|
||||
HSPRITE hCrosshair;
|
||||
AVHHSPRITE hCrosshair;
|
||||
wrect_t rcCrosshair;
|
||||
|
||||
/* HSPRITE hAutoaim;
|
||||
|
|
|
@ -38,7 +38,7 @@ int HISTORY_DRAW_TIME = 5;
|
|||
struct ITEM_INFO
|
||||
{
|
||||
char szName[MAX_ITEM_NAME];
|
||||
HSPRITE spr;
|
||||
AVHHSPRITE spr;
|
||||
wrect_t rect;
|
||||
};
|
||||
|
||||
|
@ -104,7 +104,7 @@ int HistoryResource :: DrawAmmoHistory( float flTime )
|
|||
else if ( rgAmmoHistory[i].type == HISTSLOT_AMMO )
|
||||
{
|
||||
wrect_t rcPic;
|
||||
HSPRITE *spr = gWR.GetAmmoPicFromWeapon( rgAmmoHistory[i].iId, rcPic );
|
||||
AVHHSPRITE *spr = gWR.GetAmmoPicFromWeapon( rgAmmoHistory[i].iId, rcPic );
|
||||
|
||||
int r, g, b;
|
||||
gHUD.GetPrimaryHudColor(r, g, b);
|
||||
|
|
|
@ -53,7 +53,7 @@ public:
|
|||
int CountAmmo( int iId );
|
||||
int GetAmmo( int iId );
|
||||
void SetAmmo( int iId, int iCount );
|
||||
HSPRITE* GetAmmoPicFromWeapon( int iAmmoId, wrect_t& rect ); //TODO: fix bass-ackwards arrangement and store sprites with ammo types
|
||||
AVHHSPRITE* GetAmmoPicFromWeapon( int iAmmoId, wrect_t& rect ); //TODO: fix bass-ackwards arrangement and store sprites with ammo types
|
||||
|
||||
void AddWeapon( WEAPON* wp );
|
||||
void PickupWeapon( WEAPON* wp );
|
||||
|
|
|
@ -4,13 +4,14 @@
|
|||
#include "chudmisc.h"
|
||||
#include "hud_spectator.h"
|
||||
#include "AvHFont.h"
|
||||
#include "hud_crosshairs.h"
|
||||
|
||||
|
||||
class CHud
|
||||
{
|
||||
private:
|
||||
HUDLIST *m_pHudList;
|
||||
HSPRITE m_hsprLogo;
|
||||
AVHHSPRITE m_hsprLogo;
|
||||
int m_iLogo;
|
||||
client_sprite_t *m_pSpriteList;
|
||||
int m_iSpriteCount;
|
||||
|
@ -19,9 +20,10 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
HSPRITE m_hsprCursor;
|
||||
AVHHSPRITE m_hsprCursor;
|
||||
float m_flTime; // the current client time
|
||||
float m_fOldTime; // the time at which the HUD was last redrawn
|
||||
float m_wsFOV; //fov recalc corrected for widescreen
|
||||
double m_flTimeDelta; // the difference between flTime and fOldTime
|
||||
Vector m_vecOrigin;
|
||||
Vector m_vecAngles;
|
||||
|
@ -45,7 +47,7 @@ public:
|
|||
private:
|
||||
// the memory for these arrays are allocated in the first call to CHud::VidInit(), when the hud.txt and associated sprites are loaded.
|
||||
// freed in ~CHud()
|
||||
HSPRITE *m_rghSprites; /*[HUD_SPRITE_COUNT]*/ // the sprites loaded from hud.txt
|
||||
AVHHSPRITE *m_rghSprites; /*[HUD_SPRITE_COUNT]*/ // the sprites loaded from hud.txt
|
||||
wrect_t *m_rgrcRects; /*[HUD_SPRITE_COUNT]*/
|
||||
char *m_rgszSpriteNames; /*[HUD_SPRITE_COUNT][MAX_SPRITE_NAME_LENGTH]*/
|
||||
|
||||
|
@ -53,7 +55,7 @@ private:
|
|||
|
||||
|
||||
public:
|
||||
HSPRITE GetSprite( int index )
|
||||
AVHHSPRITE GetSprite( int index )
|
||||
{
|
||||
return (index < 0) ? 0 : m_rghSprites[index];
|
||||
}
|
||||
|
@ -81,7 +83,8 @@ public:
|
|||
CHudAmmoSecondary m_AmmoSecondary;
|
||||
CHudTextMessage m_TextMessage;
|
||||
CHudStatusIcons m_StatusIcons;
|
||||
|
||||
CHudCrosshairs m_Crosshairs;
|
||||
|
||||
AvHFont mFont;
|
||||
AvHFont mSmallFont;
|
||||
|
||||
|
|
|
@ -187,7 +187,7 @@ public:
|
|||
int MsgFunc_Train(const char *pszName, int iSize, void *pbuf);
|
||||
|
||||
private:
|
||||
HSPRITE m_hSprite;
|
||||
AVHHSPRITE m_hSprite;
|
||||
int m_iPos;
|
||||
|
||||
};
|
||||
|
@ -343,8 +343,8 @@ public:
|
|||
int MsgFunc_Battery(const char *pszName, int iSize, void *pbuf );
|
||||
|
||||
private:
|
||||
HSPRITE m_hSprite1;
|
||||
HSPRITE m_hSprite2;
|
||||
AVHHSPRITE m_hSprite1;
|
||||
AVHHSPRITE m_hSprite2;
|
||||
wrect_t *m_prc1;
|
||||
wrect_t *m_prc2;
|
||||
int m_iBat;
|
||||
|
@ -368,9 +368,9 @@ public:
|
|||
int MsgFunc_FlashBat(const char *pszName, int iSize, void *pbuf );
|
||||
|
||||
private:
|
||||
HSPRITE m_hSprite1;
|
||||
HSPRITE m_hSprite2;
|
||||
HSPRITE m_hBeam;
|
||||
AVHHSPRITE m_hSprite1;
|
||||
AVHHSPRITE m_hSprite2;
|
||||
AVHHSPRITE m_hBeam;
|
||||
wrect_t *m_prc1;
|
||||
wrect_t *m_prc2;
|
||||
wrect_t *m_prcBeam;
|
||||
|
@ -492,7 +492,7 @@ private:
|
|||
typedef struct
|
||||
{
|
||||
char szSpriteName[MAX_ICONSPRITENAME_LENGTH];
|
||||
HSPRITE spr;
|
||||
AVHHSPRITE spr;
|
||||
wrect_t rc;
|
||||
unsigned char r, g, b;
|
||||
} icon_sprite_t;
|
||||
|
|
|
@ -15,8 +15,8 @@
|
|||
<Configurations>
|
||||
<Configuration
|
||||
Name="Developer - debug|Win32"
|
||||
OutputDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
|
||||
IntermediateDirectory="$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="FALSE"
|
||||
|
@ -99,8 +99,8 @@
|
|||
</Configuration>
|
||||
<Configuration
|
||||
Name="Developer - release|Win32"
|
||||
OutputDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="V:\temp\$(ProjectName)\$(ConfigurationName)"
|
||||
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
|
||||
IntermediateDirectory="$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="FALSE"
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Playtest|Win32">
|
||||
<Configuration>Playtest</Configuration>
|
||||
|
@ -14,7 +14,7 @@
|
|||
<SccLocalPath />
|
||||
<SccProvider />
|
||||
<ProjectGuid>{665C1DAF-9248-E06F-4E5C-A664BAFDE9D8}</ProjectGuid>
|
||||
<WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion>
|
||||
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'" Label="Configuration">
|
||||
|
@ -22,7 +22,7 @@
|
|||
<UseOfMfc>false</UseOfMfc>
|
||||
<UseOfAtl>false</UseOfAtl>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<PlatformToolset>v100</PlatformToolset>
|
||||
<PlatformToolset>v141</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
|
@ -39,13 +39,17 @@
|
|||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">false</LinkIncremental>
|
||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">client</TargetName>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">
|
||||
<IncludePath>.;zlib-1.2.8;includes\zlib-1.2.8;source\includes\zlib-1.2.8;main\source\includes\zlib-1.2.8;$(IncludePath)</IncludePath>
|
||||
<CustomBuildAfterTargets />
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
<IntrinsicFunctions>false</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)\particles;$(SolutionDir)\includes\lpng1251;$(SolutionDir)\includes\zlib-1.2.8;$(SolutionDir)\includes\fmod\inc;$(SolutionDir)\includes\vgui\include;../public;../common;../external;../pm_shared;../game_shared;../mod;../util;../ui;../engine;../cl_dll;../dlls</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>NDEBUG;WIN32;_WINDOWS;AVH_CLIENT;USE_OLDAUTH</PreprocessorDefinitions>
|
||||
<PreprocessorDefinitions>NDEBUG;WIN32;_WINDOWS;AVH_CLIENT;USE_OLDAUTH;_X86_</PreprocessorDefinitions>
|
||||
<StringPooling>true</StringPooling>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<PrecompiledHeader>
|
||||
|
@ -63,13 +67,14 @@
|
|||
<BrowseInformation>true</BrowseInformation>
|
||||
<DisableSpecificWarnings>4996</DisableSpecificWarnings>
|
||||
<BufferSecurityCheck>true</BufferSecurityCheck>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<FavorSizeOrSpeed>Neither</FavorSizeOrSpeed>
|
||||
<ShowIncludes>false</ShowIncludes>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>particles.lib;vgui.lib;zlib.lib;libpng.lib;wsock32.lib;sdl2.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalDependencies>particles.lib;vgui.lib;zlib.lib;libpng.lib;wsock32.lib;sdl2.lib;opengl32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>$(SolutionDir)\particles\WIN32_Release;$(SolutionDir)\includes\lpng1251;$(SolutionDir)\includes\zlib-1.2.8;$(SolutionDir)\includes\vgui\lib\win32_vc6;$(SolutionDir)\lib\public;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<AdditionalLibraryDirectories>$(SolutionDir)\particles\Release;$(SolutionDir)\includes\lpng1251;$(SolutionDir)\includes\zlib-1.2.8;$(SolutionDir)\includes\vgui\lib\win32_vc6;$(SolutionDir)\lib\public;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<IgnoreSpecificDefaultLibraries>
|
||||
</IgnoreSpecificDefaultLibraries>
|
||||
<ProgramDatabaseFile>
|
||||
|
@ -84,6 +89,7 @@
|
|||
<TreatLinkerWarningAsErrors>
|
||||
</TreatLinkerWarningAsErrors>
|
||||
<AdditionalOptions>/NODEFAULTLIB:LIBCMT %(AdditionalOptions)</AdditionalOptions>
|
||||
<OutputFile>$(SolutionDir)..\cl_dlls\client.dll</OutputFile>
|
||||
</Link>
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
|
@ -164,6 +170,10 @@
|
|||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hud_crosshairs.cpp">
|
||||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hud_msg.cpp">
|
||||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
|
@ -184,6 +194,10 @@
|
|||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hudgl.cpp">
|
||||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ClCompile>
|
||||
<ClCompile Include="in_camera.cpp">
|
||||
<Optimization Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Playtest|Win32'">%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
|
@ -799,6 +813,8 @@
|
|||
<ClInclude Include="GameStudioModelRenderer.h" />
|
||||
<ClInclude Include="health.h" />
|
||||
<ClInclude Include="hud.h" />
|
||||
<ClInclude Include="hudgl.h" />
|
||||
<ClInclude Include="hud_crosshairs.h" />
|
||||
<ClInclude Include="hud_iface.h" />
|
||||
<ClInclude Include="hud_servers.h" />
|
||||
<ClInclude Include="hud_servers_priv.h" />
|
||||
|
|
|
@ -594,6 +594,12 @@
|
|||
<ClCompile Include="cdll_int.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hud_crosshairs.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="hudgl.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\mod\AvHAlienAbilities.h">
|
||||
|
@ -1040,6 +1046,12 @@
|
|||
<ClInclude Include="..\textrep\TRTagValuePair.h">
|
||||
<Filter>textrep</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="hud_crosshairs.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="hudgl.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Library Include="..\lib\public\game_controls.lib" />
|
||||
|
|
|
@ -94,8 +94,8 @@ int ScreenWidth();
|
|||
|
||||
|
||||
// Gets the height & width of a sprite, at the specified frame
|
||||
inline int SPR_Height( HSPRITE x, int f ) { return gEngfuncs.pfnSPR_Height(x, f); }
|
||||
inline int SPR_Width( HSPRITE x, int f ) { return gEngfuncs.pfnSPR_Width(x, f); }
|
||||
inline int SPR_Height( AVHHSPRITE x, int f ) { return gEngfuncs.pfnSPR_Height(x, f); }
|
||||
inline int SPR_Width( AVHHSPRITE x, int f ) { return gEngfuncs.pfnSPR_Width(x, f); }
|
||||
|
||||
inline client_textmessage_t *TextMessageGet( const char *pName ) { return gEngfuncs.pfnTextMessageGet( pName ); }
|
||||
inline int TextMessageDrawChar( int x, int y, int number, int r, int g, int b )
|
||||
|
@ -141,7 +141,7 @@ inline void UnpackRGB(int &r, int &g, int &b, unsigned long ulRGB)\
|
|||
|
||||
void FillRGBAClipped(vgui::Panel* inPanel, int inStartX, int inStartY, int inWidth, int inHeight, int r, int g, int b, int a);
|
||||
|
||||
HSPRITE LoadSprite(const char *pszName);
|
||||
AVHHSPRITE LoadSprite(const char *pszName);
|
||||
|
||||
//bool LocalizeString(const char* inMessage, char* outBuffer, int inBufferSize);
|
||||
bool LocalizeString(const char* inMessage, string& outputString);
|
||||
|
|
|
@ -103,8 +103,8 @@ public:
|
|||
float m_fFade;
|
||||
|
||||
private:
|
||||
HSPRITE m_hSprite;
|
||||
HSPRITE m_hDamage;
|
||||
AVHHSPRITE m_hSprite;
|
||||
AVHHSPRITE m_hDamage;
|
||||
|
||||
DAMAGE_IMAGE m_dmg[NUM_DMG_TYPES];
|
||||
int m_bitsDamage;
|
||||
|
|
|
@ -203,15 +203,15 @@ void CHud :: Init( void )
|
|||
g_bDuckToggled = false;
|
||||
// :
|
||||
|
||||
CVAR_CREATE( "zoom_sensitivity_ratio", "1.2", 0 );
|
||||
CVAR_CREATE( "zoom_sensitivity_ratio", "1", 0 );
|
||||
default_fov = CVAR_CREATE( "default_fov", "90", 0 );
|
||||
m_pCvarStealMouse = CVAR_CREATE( "hud_capturemouse", "1", FCVAR_ARCHIVE );
|
||||
m_pCvarDraw = CVAR_CREATE( "hud_draw", "1", FCVAR_ARCHIVE );
|
||||
cl_lw = gEngfuncs.pfnGetCvarPointer( "cl_lw" );
|
||||
|
||||
CVAR_CREATE( "cl_showspeed", "0", 0);
|
||||
CVAR_CREATE( kvLabelMaps, "1", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvGammaRamp, "1", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvLabelMaps, "3", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvGammaRamp, "0", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvCustomCrosshair, "1", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvHudMapZoom, "3", FCVAR_ARCHIVE);
|
||||
CVAR_CREATE( kvLabelHivesight, "1", FCVAR_ARCHIVE);
|
||||
|
@ -251,6 +251,7 @@ void CHud :: Init( void )
|
|||
m_AmmoSecondary.Init();
|
||||
m_TextMessage.Init();
|
||||
m_StatusIcons.Init();
|
||||
m_Crosshairs.Init();
|
||||
|
||||
m_Spectator.m_chatEnabled = (m_SayText.m_HUD_saytext->value!=0);
|
||||
|
||||
|
@ -315,8 +316,16 @@ void CHud :: VidInit( void )
|
|||
|
||||
gHUD.SetViewport(theViewPort);
|
||||
|
||||
mFont.Load("sprites/font_arial");
|
||||
mSmallFont.Load("sprites/font_arialsmall");
|
||||
if (CVAR_GET_FLOAT("hud_style") == 2.0f)
|
||||
{
|
||||
mFont.Load("sprites/nl/font_arial");
|
||||
mSmallFont.Load("sprites/nl/font_arialsmall");
|
||||
}
|
||||
else
|
||||
{
|
||||
mFont.Load("sprites/font_arial");
|
||||
mSmallFont.Load("sprites/font_arialsmall");
|
||||
}
|
||||
|
||||
// ----------
|
||||
// Load Sprites
|
||||
|
@ -335,6 +344,9 @@ void CHud :: VidInit( void )
|
|||
if ( !m_pSpriteList )
|
||||
{
|
||||
// we need to load the hud.txt, and all sprites within
|
||||
if (CVAR_GET_FLOAT("hud_style") == 2.0f)
|
||||
m_pSpriteList = SPR_GetList("sprites/hudnl.txt", &m_iSpriteCountAllRes);
|
||||
else
|
||||
m_pSpriteList = SPR_GetList("sprites/hud.txt", &m_iSpriteCountAllRes);
|
||||
|
||||
if (m_pSpriteList)
|
||||
|
@ -351,7 +363,7 @@ void CHud :: VidInit( void )
|
|||
}
|
||||
|
||||
// allocated memory for sprite handle arrays
|
||||
m_rghSprites = new HSPRITE[m_iSpriteCount];
|
||||
m_rghSprites = new AVHHSPRITE[m_iSpriteCount];
|
||||
m_rgrcRects = new wrect_t[m_iSpriteCount];
|
||||
m_rgszSpriteNames = new char[m_iSpriteCount * MAX_SPRITE_NAME_LENGTH];
|
||||
|
||||
|
@ -414,6 +426,7 @@ void CHud :: VidInit( void )
|
|||
m_AmmoSecondary.VidInit();
|
||||
m_TextMessage.VidInit();
|
||||
m_StatusIcons.VidInit();
|
||||
m_Crosshairs.VidInit();
|
||||
GetClientVoiceMgr()->VidInit();
|
||||
}
|
||||
|
||||
|
@ -535,7 +548,7 @@ int CHud::MsgFunc_SetFOV(const char *pszName, int iSize, void *pbuf)
|
|||
// the clients fov is actually set in the client data update section of the hud
|
||||
|
||||
// Set a new sensitivity
|
||||
if ( m_iFOV == def_fov )
|
||||
if ( m_iFOV == def_fov || CVAR_GET_FLOAT("senslock") == 1.0f)
|
||||
{
|
||||
// reset to saved sensitivity
|
||||
m_flMouseSensitivity = 0;
|
||||
|
|
|
@ -0,0 +1,219 @@
|
|||
#include "hud.h"
|
||||
#include "cl_util.h"
|
||||
#include "parsemsg.h"
|
||||
#include "hudgl.h"
|
||||
|
||||
// Crosshair system based on OpenAG
|
||||
// https://github.com/YaLTeR/OpenAG
|
||||
|
||||
int CHudCrosshairs::Init()
|
||||
{
|
||||
m_iFlags = HUD_ACTIVE;
|
||||
|
||||
cl_cross = CVAR_CREATE("cl_cross", "0", FCVAR_ARCHIVE);
|
||||
cl_cross_color = CVAR_CREATE("cl_cross_color", "255 255 255", FCVAR_ARCHIVE);
|
||||
cl_cross_alpha = CVAR_CREATE("cl_cross_alpha", "255", FCVAR_ARCHIVE);
|
||||
cl_cross_thickness = CVAR_CREATE("cl_cross_thickness", "2", FCVAR_ARCHIVE);
|
||||
cl_cross_size = CVAR_CREATE("cl_cross_size", "6", FCVAR_ARCHIVE);
|
||||
cl_cross_gap = CVAR_CREATE("cl_cross_gap", "3", FCVAR_ARCHIVE);
|
||||
cl_cross_outline = CVAR_CREATE("cl_cross_outline", "2", FCVAR_ARCHIVE);
|
||||
cl_cross_outline_alpha = CVAR_CREATE("cl_cross_outline_alpha", "255", FCVAR_ARCHIVE);
|
||||
cl_cross_outline_inner = CVAR_CREATE("cl_cross_outline_inner", "0", FCVAR_ARCHIVE);
|
||||
cl_cross_circle_radius = CVAR_CREATE("cl_cross_circle_radius", "0", FCVAR_ARCHIVE);
|
||||
cl_cross_dot_size = CVAR_CREATE("cl_cross_dot_size", "0", FCVAR_ARCHIVE);
|
||||
cl_cross_dot_color = CVAR_CREATE("cl_cross_dot_color", "", FCVAR_ARCHIVE);
|
||||
cl_cross_dot_outline = CVAR_CREATE("cl_cross_dot_outline", "0", FCVAR_ARCHIVE);
|
||||
cl_cross_line_top = CVAR_CREATE("cl_cross_line_top", "1", FCVAR_ARCHIVE);
|
||||
cl_cross_line_bottom = CVAR_CREATE("cl_cross_line_bottom", "1", FCVAR_ARCHIVE);
|
||||
cl_cross_line_left = CVAR_CREATE("cl_cross_line_left", "1", FCVAR_ARCHIVE);
|
||||
cl_cross_line_right = CVAR_CREATE("cl_cross_line_right", "1", FCVAR_ARCHIVE);
|
||||
|
||||
gHUD.AddHudElem(this);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int CHudCrosshairs::VidInit()
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
int CHudCrosshairs::Draw(float time)
|
||||
{
|
||||
if (cl_cross->value == 0.0f)
|
||||
return 0;
|
||||
|
||||
unsigned char alpha;
|
||||
if (sscanf(cl_cross_alpha->string, "%hhu", &alpha) != 1)
|
||||
alpha = 255;
|
||||
|
||||
if (alpha == 0)
|
||||
return 0;
|
||||
|
||||
if (gHUD.GetInTopDownMode())
|
||||
return 0;
|
||||
|
||||
// outline alpha perhaps unnecessary since odd numbered thicknesses feather the outline edges
|
||||
unsigned char outalpha;
|
||||
if (sscanf(cl_cross_outline_alpha->string, "%hhu", &outalpha) != 1)
|
||||
outalpha = 255;
|
||||
|
||||
if (outalpha == 0)
|
||||
return 0;
|
||||
|
||||
unsigned char r, g, b;
|
||||
if (sscanf(cl_cross_color->string, "%hhu %hhu %hhu", &r, &g, &b) != 3) {
|
||||
r = 0;
|
||||
g = 255;
|
||||
b = 0;
|
||||
}
|
||||
|
||||
|
||||
Vector2D center(ScreenWidth() / 2.0f, ScreenHeight() / 2.0f);
|
||||
|
||||
HudGL gl;
|
||||
|
||||
// Draw the outline.
|
||||
// TODO: this contains a terrible amount of repeating complex code.
|
||||
//
|
||||
// Possible solution: can be changed to this with the one downside being in rare cases where cl_cross_thickness is high AND its alpha is <255, the center of each line will be slightly darker.
|
||||
// Example below is for bottom line. Would also cause certain crosshairs that have outlines on invisible cross lines to not look right.
|
||||
// gl.rectangle(Vector2D(center.x + offset, center.y + gap - half_width), Vector2D(center.x - offset, center.y + gap + size + half_width));
|
||||
if (cl_cross_outline->value > 0.0f) {
|
||||
//gl.color(0, 0, 0, alpha);
|
||||
gl.color(0, 0, 0, outalpha);
|
||||
gl.line_width(cl_cross_outline->value);
|
||||
|
||||
float size = cl_cross_size->value;
|
||||
float gap = cl_cross_gap->value;
|
||||
float half_thickness = cl_cross_thickness->value / 2.0f;
|
||||
float half_width = cl_cross_outline->value / 2.0f;
|
||||
float offset = half_thickness + half_width;
|
||||
|
||||
// Top line
|
||||
if (cl_cross_line_top->value) {
|
||||
gl.line(Vector2D(center.x - offset, center.y - gap - size), Vector2D(center.x + offset, center.y - gap - size));
|
||||
if (cl_cross_outline_inner->value == 0.0f)
|
||||
{
|
||||
gl.line(Vector2D(center.x + half_thickness, center.y - gap - size + half_width), Vector2D(center.x + half_thickness, center.y - gap));
|
||||
gl.line(Vector2D(center.x - half_thickness, center.y - gap), Vector2D(center.x - half_thickness, center.y - gap - size + half_width));
|
||||
}
|
||||
else
|
||||
{
|
||||
gl.line(Vector2D(center.x + half_thickness, center.y - gap - size + half_width), Vector2D(center.x + half_thickness, center.y - gap - half_width));
|
||||
gl.line(Vector2D(center.x + offset, center.y - gap), Vector2D(center.x - offset, center.y - gap));
|
||||
gl.line(Vector2D(center.x - half_thickness, center.y - gap - half_width), Vector2D(center.x - half_thickness, center.y - gap - size + half_width));
|
||||
}
|
||||
}
|
||||
|
||||
// Bottom line
|
||||
if (cl_cross_line_bottom->value) {
|
||||
gl.line(Vector2D(center.x - offset, center.y + gap + size), Vector2D(center.x + offset, center.y + gap + size));
|
||||
if (cl_cross_outline_inner->value == 0.0f)
|
||||
{
|
||||
gl.line(Vector2D(center.x + half_thickness, center.y + gap + size - half_width), Vector2D(center.x + half_thickness, center.y + gap));
|
||||
gl.line(Vector2D(center.x - half_thickness, center.y + gap), Vector2D(center.x - half_thickness, center.y + gap + size - half_width));
|
||||
}
|
||||
else
|
||||
{
|
||||
gl.line(Vector2D(center.x + half_thickness, center.y + gap + size - half_width), Vector2D(center.x + half_thickness, center.y + gap + half_width));
|
||||
gl.line(Vector2D(center.x + offset, center.y + gap), Vector2D(center.x - offset, center.y + gap));
|
||||
gl.line(Vector2D(center.x - half_thickness, center.y + gap + half_width), Vector2D(center.x - half_thickness, center.y + gap + size - half_width));
|
||||
}
|
||||
}
|
||||
|
||||
// Left line
|
||||
if (cl_cross_line_left->value) {
|
||||
gl.line(Vector2D(center.x - gap - size, center.y - offset), Vector2D(center.x - gap - size, center.y + offset));
|
||||
if (cl_cross_outline_inner->value == 0.0f)
|
||||
{
|
||||
gl.line(Vector2D(center.x - gap - size + half_width, center.y + half_thickness), Vector2D(center.x - gap, center.y + half_thickness));
|
||||
gl.line(Vector2D(center.x - gap, center.y - half_thickness), Vector2D(center.x - gap - size + half_width, center.y - half_thickness));
|
||||
}
|
||||
else
|
||||
{
|
||||
gl.line(Vector2D(center.x - gap - size + half_width, center.y + half_thickness), Vector2D(center.x - gap - half_width, center.y + half_thickness));
|
||||
gl.line(Vector2D(center.x - gap, center.y + offset), Vector2D(center.x - gap, center.y - offset));
|
||||
gl.line(Vector2D(center.x - gap - half_width, center.y - half_thickness), Vector2D(center.x - gap - size + half_width, center.y - half_thickness));
|
||||
}
|
||||
}
|
||||
|
||||
// Right line
|
||||
if (cl_cross_line_right->value) {
|
||||
gl.line(Vector2D(center.x + gap + size, center.y - offset), Vector2D(center.x + gap + size, center.y + offset));
|
||||
if (cl_cross_outline_inner->value == 0.0f)
|
||||
{
|
||||
gl.line(Vector2D(center.x + gap + size - half_width, center.y + half_thickness), Vector2D(center.x + gap, center.y + half_thickness));
|
||||
gl.line(Vector2D(center.x + gap, center.y - half_thickness), Vector2D(center.x + gap + size - half_width, center.y - half_thickness));
|
||||
}
|
||||
else
|
||||
{
|
||||
gl.line(Vector2D(center.x + gap + size - half_width, center.y + half_thickness), Vector2D(center.x + gap + half_width, center.y + half_thickness));
|
||||
gl.line(Vector2D(center.x + gap, center.y + offset), Vector2D(center.x + gap, center.y - offset));
|
||||
gl.line(Vector2D(center.x + gap + half_width, center.y - half_thickness), Vector2D(center.x + gap + size - half_width, center.y - half_thickness));
|
||||
}
|
||||
}
|
||||
|
||||
// Dot
|
||||
if (cl_cross_dot_size->value > 0.0f && cl_cross_dot_outline->value > 0.0f) {
|
||||
float size = cl_cross_dot_size->value;
|
||||
Vector2D offset = Vector2D(size / 2.0f, size / 2.0f);
|
||||
float dot_half_width = cl_cross_dot_outline->value / 2.0f;
|
||||
|
||||
gl.line(Vector2D(center.x - offset.x - dot_half_width, center.y - offset.y), Vector2D(center.x + offset.x + dot_half_width, center.y - offset.y));
|
||||
gl.line(Vector2D(center.x + offset.x, center.y - offset.y + dot_half_width), Vector2D(center.x + offset.x, center.y + offset.y - dot_half_width));
|
||||
gl.line(Vector2D(center.x - offset.x, center.y - offset.y + dot_half_width), Vector2D(center.x - offset.x, center.y + offset.y - dot_half_width));
|
||||
gl.line(Vector2D(center.x - offset.x - dot_half_width, center.y + offset.y), Vector2D(center.x + offset.x + dot_half_width, center.y + offset.y));
|
||||
}
|
||||
}
|
||||
|
||||
gl.color(r, g, b, alpha);
|
||||
|
||||
// Draw the crosshairs.
|
||||
if (cl_cross_thickness->value > 0.0f) {
|
||||
gl.line_width(cl_cross_thickness->value);
|
||||
|
||||
float size = cl_cross_size->value;
|
||||
float gap = cl_cross_gap->value;
|
||||
|
||||
if (cl_cross_line_top->value)
|
||||
gl.line(Vector2D(center.x, center.y - gap - size), Vector2D(center.x, center.y - gap));
|
||||
if (cl_cross_line_bottom->value)
|
||||
gl.line(Vector2D(center.x, center.y + gap + size), Vector2D(center.x, center.y + gap));
|
||||
if (cl_cross_line_left->value)
|
||||
gl.line(Vector2D(center.x - gap - size, center.y), Vector2D(center.x - gap, center.y));
|
||||
if (cl_cross_line_right->value)
|
||||
gl.line(Vector2D(center.x + gap + size, center.y), Vector2D(center.x + gap, center.y));
|
||||
}
|
||||
|
||||
#ifdef __APPLE__
|
||||
//Remove when OSX builds with c++11
|
||||
#else
|
||||
// Draw the circle.
|
||||
if (cl_cross_circle_radius->value > 0.0f) {
|
||||
gl.line_width(1.0f);
|
||||
|
||||
float radius = cl_cross_circle_radius->value;
|
||||
if (old_circle_radius != radius) {
|
||||
// Recompute the circle points.
|
||||
circle_points = HudGL::compute_circle(radius);
|
||||
old_circle_radius = radius;
|
||||
}
|
||||
|
||||
gl.circle(center, circle_points);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Draw the dot.
|
||||
if (cl_cross_dot_size->value > 0.0f) {
|
||||
unsigned char r, g, b;
|
||||
if (sscanf(cl_cross_dot_color->string, "%hhu %hhu %hhu", &r, &g, &b) == 3)
|
||||
gl.color(r, g, b, alpha);
|
||||
|
||||
float size = cl_cross_dot_size->value;
|
||||
Vector2D offset = Vector2D(size / 2.0f, size / 2.0f);
|
||||
|
||||
gl.rectangle(center - offset, center + offset);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|