Added files
2
.gitattributes
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
# Auto detect text files and perform LF normalization
|
||||
* text=auto
|
21
.gitignore
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
################################################################################
|
||||
# This .gitignore file was automatically created by Microsoft(R) Visual Studio.
|
||||
################################################################################
|
||||
|
||||
*.exe
|
||||
/.vs
|
||||
/Debug
|
||||
/Release
|
||||
/Speedy E.e424a3cb
|
||||
/x64
|
||||
/IMAGE08
|
||||
/IMAGE16
|
||||
/SOUND
|
||||
/MOVIE
|
||||
/DATA
|
||||
/msvc5/*.ncb
|
||||
/msvc5/*.opt
|
||||
/msvc5/sb2decomp/*.plg
|
||||
/msvc5/sb2decomp/Debug
|
||||
/msvc5/sb2decomp/Release
|
||||
Speedy Eggbert 2 Source.vcxproj.user
|
3
.gitmodules
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
[submodule "dxsdk3"]
|
||||
path = dxsdk3
|
||||
url = https://code.openeggbert.com/backup/dxsdk3
|
21
CppProperties.json
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
"configurations": [
|
||||
{
|
||||
"inheritEnvironments": [
|
||||
"msvc_x86"
|
||||
],
|
||||
"name": "x86-Debug",
|
||||
"includePath": [
|
||||
"${env.INCLUDE}",
|
||||
"${workspaceRoot}\\**"
|
||||
],
|
||||
"defines": [
|
||||
"WIN32",
|
||||
"_DEBUG",
|
||||
"UNICODE",
|
||||
"_UNICODE"
|
||||
],
|
||||
"intelliSenseMode": "windows-msvc-x86"
|
||||
}
|
||||
]
|
||||
}
|
674
LICENSE
Normal file
@ -0,0 +1,674 @@
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <https://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 <https://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
|
||||
<https://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
|
||||
<https://www.gnu.org/licenses/why-not-lgpl.html>.
|
90
README.md
@ -1,76 +1,84 @@
|
||||
# Speedy Eggbert 2 Source Code Decomp
|
||||
# Free Eggbert
|
||||
|
||||
This is fork of: https://github.com/jummy0/sb2-decomp
|
||||
|
||||

|
||||
|
||||
## Introduction
|
||||
|
||||
This is decompiled source code of Speedy Eggbert 2.
|
||||
|
||||
This repository is based on the following works:
|
||||
- https://github.com/jummy0/sb2-decomp
|
||||
- https://github.com/HMVocaloid/Speedy-Eggbert-2-Source-Code-Decomp
|
||||
|
||||
As of now (5/17/24), there hasn't been any source code found for SE2. So we are using the released (original) source code from Planet Blupi to compare code and help us with the proccess.
|
||||
Currently, no source code has been publicly released for Speedy Blupi. We are using the disassemblers Ghidra and IDA to inspect the game binaries, and comparing with the official Planet Blupi source code.
|
||||
|
||||
## Used technologies
|
||||
|
||||
- C++
|
||||
- DirectX 3
|
||||
|
||||
## Future
|
||||
|
||||
## Clone with git
|
||||
- Migration from DirectX 3 to SDL2
|
||||
- Migration from Visual Studio 2017 to another IDE
|
||||
- Making it multiplatform (Android and web browser too)
|
||||
|
||||
## Init and update submodules
|
||||
## Development
|
||||
Some demangled symbol names are taken from the 2013 Windows Phone version of Speedy Blupi, which we inspected using ILSpy. Big thanks to Ч.У.Ш on the 4PDA forum for archiving this obscure version of the game!!!
|
||||
|
||||
Gameplay is functional, but defective and missing many features.
|
||||
|
||||
These files currently need the **most attention**, in order of priority:
|
||||
- event.cpp
|
||||
- decblupi.cpp
|
||||
- decio.cpp
|
||||
- decdesign.cpp
|
||||
- decblock.cpp
|
||||
- decmove.cpp
|
||||
- decnet.cpp
|
||||
- decor.cpp
|
||||
- misc.cpp
|
||||
|
||||
These files are tentatively **complete**, but require further testing:
|
||||
- blupi.cpp
|
||||
- button.cpp
|
||||
- jauge.cpp
|
||||
- menu.cpp
|
||||
- movie.cpp
|
||||
- network.cpp
|
||||
- pixmap.cpp
|
||||
- sound.cpp
|
||||
- wave.cpp
|
||||
|
||||
## How to setup locally
|
||||
|
||||
### Clone with git
|
||||
|
||||
#init and update submodules
|
||||
git submodule init
|
||||
|
||||
git submodule update
|
||||
|
||||
## How to setup the development environment locally
|
||||
### How to setup the development environment locally
|
||||
|
||||
### Install "Microsoft Visual Studio Community 2017"
|
||||
#### Install "Microsoft Visual Studio Community 2017"
|
||||
|
||||
https://drive.openeggbert.com/other/Visual_Studio_Community_2017.exe
|
||||
|
||||
- This (IDE) will be changed in the future
|
||||
|
||||
### Install v140 toolset for desktop
|
||||
#### Install v140 toolset for desktop
|
||||
|
||||
### Open the Project
|
||||
#### Open the Project
|
||||
|
||||
Click on "Speedy Eggbert 2 Source.sln" and select Open with "Microsoft Visual Studio 2017"
|
||||
|
||||
Set the Platform to x86 and debugging to Win32.
|
||||
|
||||
### Set "Additional Options"
|
||||
#### Set "Additional Options"
|
||||
|
||||
Properties / Configuration Properties / C/C++ / Command Line / Additional Options
|
||||
|
||||
Add : /wd4700 /wd4703
|
||||
|
||||
### Build
|
||||
#### Build
|
||||
|
||||
Click with the right mouse button on "Speedy Eggbert 2 Source.sln"
|
||||
- launch Build/Build Speedy Eggbert 2 Source.sln
|
||||
|
||||
## Current status
|
||||
|
||||
| CPP File | Progress |
|
||||
| -------- | -------- |
|
||||
| blupi.cpp | 99% complete |
|
||||
| button.cpp | 100% complete |
|
||||
| decor.cpp | 80% complete |
|
||||
| event.cpp | 70% complete |
|
||||
| menu.cpp | 100% complete |
|
||||
| misc.cpp | 100% complete |
|
||||
| movie.cpp | 100% complete |
|
||||
| network.cpp | 100% complete |
|
||||
| pixmap.cpp | 99% complete |
|
||||
| sound.cpp | 100% complete |
|
||||
| text.cpp | 100% complete |
|
||||
| wave.cpp | 100% complete |
|
||||
|
||||
|
||||
Credit to jummy over at the Blupi Games Fan Server for doing the decompilation work on the game.
|
||||
|
||||
## Future
|
||||
|
||||
- Migration from DirectX 3 to SDL2
|
||||
- Migration from Visual Studio 2017 to another IDE
|
||||
- Making it crossplatform
|
||||
|
31
Speedy Eggbert 2 Source.sln
Normal file
@ -0,0 +1,31 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.8.34330.188
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Speedy Eggbert 2 Source", "Speedy Eggbert 2 Source.vcxproj", "{07F25327-C838-4ACD-ADBA-BE17F75007EF}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|x64 = Debug|x64
|
||||
Debug|x86 = Debug|x86
|
||||
Release|x64 = Release|x64
|
||||
Release|x86 = Release|x86
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Debug|x64.Build.0 = Debug|x64
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Debug|x86.ActiveCfg = Debug|Win32
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Debug|x86.Build.0 = Debug|Win32
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Release|x64.ActiveCfg = Release|x64
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Release|x64.Build.0 = Release|x64
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Release|x86.ActiveCfg = Release|Win32
|
||||
{07F25327-C838-4ACD-ADBA-BE17F75007EF}.Release|x86.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {13496F7E-739E-4004-A5EA-AAF0B184B7C6}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
244
Speedy Eggbert 2 Source.vcxproj
Normal file
@ -0,0 +1,244 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<VCProjectVersion>17.0</VCProjectVersion>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<ProjectGuid>{e424a3cb-c8b8-447c-be63-41a57e65b449}</ProjectGuid>
|
||||
<RootNamespace>SpeedyEggbert2Source</RootNamespace>
|
||||
<WindowsTargetPlatformVersion>
|
||||
</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v140_xp</PlatformToolset>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v140_xp</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v140_xp</PlatformToolset>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v140_xp</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="Shared">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SDLCheck>false</SDLCheck>
|
||||
<PreprocessorDefinitions>_WIN32;WIN32;_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>dxsdk3\sdk\inc;bass\inc</AdditionalIncludeDirectories>
|
||||
<UndefinePreprocessorDefinitions>UNICODE;_UNICODE</UndefinePreprocessorDefinitions>
|
||||
<PrecompiledHeaderFile />
|
||||
<Optimization>Disabled</Optimization>
|
||||
<FavorSizeOrSpeed>Neither</FavorSizeOrSpeed>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<IntrinsicFunctions>false</IntrinsicFunctions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalOptions>/DYNAMICBASE "legacy_stdio_definitions.lib" %(AdditionalOptions) /VERBOSE</AdditionalOptions>
|
||||
<AdditionalLibraryDirectories>dxsdk3\sdk\lib;bass\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<TreatLinkerWarningAsErrors>false</TreatLinkerWarningAsErrors>
|
||||
<AdditionalDependencies>dxsdk3/sdk/lib/*.lib;bass/lib/*.lib;winmm.lib;kernel32.lib;user32.lib;gdi32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>
|
||||
<EnableCOMDATFolding>false</EnableCOMDATFolding>
|
||||
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>_WIN32;WIN32;_CRT_SECURE_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>dxsdk3\sdk\inc;bass\inc</AdditionalIncludeDirectories>
|
||||
<UndefinePreprocessorDefinitions>UNICODE;_UNICODE</UndefinePreprocessorDefinitions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalLibraryDirectories>dxsdk3\sdk\lib;bass\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>
|
||||
<AdditionalOptions>/DYNAMICBASE "legacy_stdio_definitions.lib" %(AdditionalOptions) /VERBOSE</AdditionalOptions>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalDependencies>dxsdk3/sdk/lib/*.lib;bass/lib/*.lib;winmm.lib;kernel32.lib;user32.lib;gdi32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>_WIN32;WIN32;_CRT_SECURE_NO_WARNINGS;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>dxsdk3\sdk\inc</AdditionalIncludeDirectories>
|
||||
<UndefinePreprocessorDefinitions>UNICODE;_UNICODE</UndefinePreprocessorDefinitions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalLibraryDirectories>dxsdk3\sdk\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>
|
||||
<AdditionalOptions>/DYNAMICBASE "legacy_stdio_definitions.lib" %(AdditionalOptions) /VERBOSE</AdditionalOptions>
|
||||
<AdditionalDependencies>dxsdk3/sdk/lib/*.lib;winmm.lib;kernel32.lib;user32.lib;gdi32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<TreatLinkerWarningAsErrors>false</TreatLinkerWarningAsErrors>
|
||||
<EnableCOMDATFolding>false</EnableCOMDATFolding>
|
||||
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<SDLCheck>true</SDLCheck>
|
||||
<PreprocessorDefinitions>_WIN32;WIN32;_CRT_SECURE_NO_WARNINGS;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ConformanceMode>true</ConformanceMode>
|
||||
<AdditionalIncludeDirectories>dxsdk3\sdk\inc</AdditionalIncludeDirectories>
|
||||
<UndefinePreprocessorDefinitions>UNICODE;_UNICODE</UndefinePreprocessorDefinitions>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalLibraryDirectories>dxsdk3\sdk\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>
|
||||
<AdditionalOptions>/DYNAMICBASE "legacy_stdio_definitions.lib" %(AdditionalOptions) /VERBOSE</AdditionalOptions>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
<AdditionalDependencies>dxsdk3/sdk/lib/*.lib;winmm.lib;kernel32.lib;user32.lib;gdi32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Debug\DATA\config.def" />
|
||||
<None Include="resource\cursor1.cur" />
|
||||
<None Include="resource\IDC_ARROW.cur" />
|
||||
<None Include="resource\IDC_ARROWD.cur" />
|
||||
<None Include="resource\IDC_ARROWDL.cur" />
|
||||
<None Include="resource\IDC_ARROWDR.cur" />
|
||||
<None Include="resource\IDC_ARROWL.cur" />
|
||||
<None Include="resource\IDC_ARROWR.cur" />
|
||||
<None Include="resource\IDC_ARROWU.cur" />
|
||||
<None Include="resource\IDC_ARROWUL.cur" />
|
||||
<None Include="resource\IDC_ARROWUR.cur" />
|
||||
<None Include="resource\IDC_EMPTY.cur" />
|
||||
<None Include="resource\IDC_FILL.cur" />
|
||||
<None Include="resource\IDC_MAP.cur" />
|
||||
<None Include="resource\IDC_POINTER.cur" />
|
||||
<None Include="resource\IDC_WAIT.cur" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\blupi.cpp" />
|
||||
<ClCompile Include="src\button.cpp" />
|
||||
<ClCompile Include="src\ddutil.cpp" />
|
||||
<ClCompile Include="src\decblock.cpp" />
|
||||
<ClCompile Include="src\decblupi.cpp" />
|
||||
<ClCompile Include="src\decdesign.cpp" />
|
||||
<ClCompile Include="src\decio.cpp" />
|
||||
<ClCompile Include="src\decmove.cpp" />
|
||||
<ClCompile Include="src\decnet.cpp" />
|
||||
<ClCompile Include="src\decor.cpp" />
|
||||
<ClCompile Include="src\event.cpp" />
|
||||
<ClCompile Include="src\jauge.cpp" />
|
||||
<ClCompile Include="src\menu.cpp" />
|
||||
<ClCompile Include="src\misc.cpp" />
|
||||
<ClCompile Include="src\movie.cpp" />
|
||||
<ClCompile Include="src\network.cpp" />
|
||||
<ClCompile Include="src\pixmap.cpp" />
|
||||
<ClCompile Include="src\sound.cpp" />
|
||||
<ClCompile Include="src\text.cpp" />
|
||||
<ClCompile Include="src\wave.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="resource\resource.h" />
|
||||
<ClInclude Include="src\button.h" />
|
||||
<ClInclude Include="src\ddutil.h" />
|
||||
<ClInclude Include="src\decor.h" />
|
||||
<ClInclude Include="src\dectables.h" />
|
||||
<ClInclude Include="src\def.h" />
|
||||
<ClInclude Include="src\event.h" />
|
||||
<ClInclude Include="src\jauge.h" />
|
||||
<ClInclude Include="src\menu.h" />
|
||||
<ClInclude Include="src\misc.h" />
|
||||
<ClInclude Include="src\movie.h" />
|
||||
<ClInclude Include="src\network.h" />
|
||||
<ClInclude Include="src\obstacle.h" />
|
||||
<ClInclude Include="src\pixmap.h" />
|
||||
<ClInclude Include="src\pixtables.h" />
|
||||
<ClInclude Include="src\resource.h" />
|
||||
<ClInclude Include="src\sound.h" />
|
||||
<ClInclude Include="src\text.h" />
|
||||
<ClInclude Include="src\texttables.h" />
|
||||
<ClInclude Include="src\wave.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Image Include="resource\IDR_MAINFRAME.ico" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="resource\Eggbert2.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
204
Speedy Eggbert 2 Source.vcxproj.filters
Normal file
@ -0,0 +1,204 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Header Files">
|
||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files">
|
||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Data">
|
||||
<UniqueIdentifier>{0ff9ef1b-78f1-41d7-9a2b-813cedd6907d}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Debug\DATA\config.def">
|
||||
<Filter>Data</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_FILL.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_MAP.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_POINTER.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_WAIT.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROW.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWD.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWDL.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWDR.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWL.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWR.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWU.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWUL.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_ARROWUR.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\IDC_EMPTY.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
<None Include="resource\cursor1.cur">
|
||||
<Filter>Resource Files</Filter>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="src\resource.h">
|
||||
<Filter>Resource Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\decor.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\dectables.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\def.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\ddutil.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\event.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\jauge.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\menu.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\misc.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\movie.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\network.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\obstacle.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\pixmap.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\pixtables.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\sound.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\text.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\texttables.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\wave.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="src\button.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="resource\resource.h">
|
||||
<Filter>Header Files</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Image Include="resource\IDR_MAINFRAME.ico">
|
||||
<Filter>Resource Files</Filter>
|
||||
</Image>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="resource\Eggbert2.rc">
|
||||
<Filter>Resource Files</Filter>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="src\blupi.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\button.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\ddutil.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decblock.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decblupi.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decdesign.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decio.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decmove.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decnet.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\decor.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\event.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\jauge.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\menu.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\misc.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\movie.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\network.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\pixmap.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\sound.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\text.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="src\wave.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
BIN
bass/bass.dll
Normal file
2352
bass/bass.txt
Normal file
BIN
bass/bassmidi.dll
Normal file
734
bass/bassmidi.txt
Normal file
@ -0,0 +1,734 @@
|
||||
BASSMIDI 2.4
|
||||
Copyright (c) 2006-2024 Un4seen Developments Ltd. All rights reserved.
|
||||
|
||||
Files that you should have found in the BASSMIDI package
|
||||
========================================================
|
||||
Win32 version
|
||||
-------------
|
||||
BASSMIDI.TXT This file
|
||||
BASSMIDI.DLL BASSMIDI module
|
||||
BASSMIDI.CHM BASSMIDI documentation
|
||||
X64\
|
||||
BASSMIDI.DLL 64-bit BASSMIDI module
|
||||
C\ C/C++ API and examples...
|
||||
BASSMIDI.H BASSMIDI C/C++ header file
|
||||
BASSMIDI.LIB BASSMIDI import library
|
||||
BASSMIDI.SLN Visual Studio solution for examples
|
||||
MAKEFILE Makefile for examples
|
||||
MAKEFILE.IN Makefile helper macros
|
||||
X64\
|
||||
BASSMIDI.LIB 64-bit BASSMIDI import library
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
SF2PACK\ Soundfont packer
|
||||
...
|
||||
SYNTH\ Real-time MIDI example
|
||||
...
|
||||
BIN\ Precompiled examples
|
||||
MIDITEST.EXE
|
||||
SF2PACK.EXE
|
||||
SYNTH.EXE
|
||||
VB\ Visual Basic API and examples...
|
||||
BASSMIDI.BAS BASSMIDI Visual Basic module
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
DELPHI\ Delphi API and examples...
|
||||
BASSMIDI.PAS BASSMIDI Delphi unit
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
SYNTH\ Real-time MIDI example
|
||||
...
|
||||
|
||||
NOTE: You may need to "Unblock" the BASSMIDI.CHM file in its "Properties" to
|
||||
view it on Windows 7. The documentation can also be viewed online at
|
||||
the BASS website.
|
||||
|
||||
NOTE: To run the example EXEs, first you will have to copy BASSMIDI.DLL and
|
||||
BASS.DLL into the same directory as them.
|
||||
|
||||
NOTE: To build the examples, you will need to copy the BASS API into the same
|
||||
directory as the BASSMIDI API.
|
||||
|
||||
NOTE: The Delphi and VB examples may not always be up to date with the C
|
||||
examples, so the latter should be preferred as references if possible.
|
||||
|
||||
macOS version
|
||||
-------------
|
||||
BASSMIDI.TXT This file
|
||||
LIBBASSMIDI.DYLIB BASSMIDI module
|
||||
BASSMIDI.CHM BASSMIDI documentation
|
||||
BASSMIDI.H BASSMIDI C/C++ header file
|
||||
BASSMIDI.XCODEPROJ Xcode project for examples
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
SF2PACK\ Soundfont packer
|
||||
...
|
||||
SYNTH\ Real-time MIDI example
|
||||
...
|
||||
|
||||
NOTE: To build the examples, you will need to copy the BASS API into the same
|
||||
directory as the BASSMIDI API.
|
||||
|
||||
Linux version
|
||||
-------------
|
||||
BASSMIDI.TXT This file
|
||||
BASSMIDI.CHM BASSMIDI documentation
|
||||
BASSMIDI.H BASSMIDI C/C++ header file
|
||||
MAKEFILE Makefile for examples
|
||||
MAKEFILE.IN Makefile helper macros
|
||||
LIBS\ BASSMIDI modules
|
||||
...
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
SF2PACK\ Soundfont packer
|
||||
...
|
||||
SYNTH\ Real-time MIDI example
|
||||
...
|
||||
|
||||
NOTE: To build the examples, you will need to copy the BASS API into the same
|
||||
directory as the BASSMIDI API.
|
||||
|
||||
Android version
|
||||
---------------
|
||||
BASSMIDI.TXT This file
|
||||
BASSMIDI.CHM BASSMIDI documentation
|
||||
LIBS\ BASSMIDI modules
|
||||
...
|
||||
C\ C/C++ API...
|
||||
BASSMIDI.H BASSMIDI C/C++ header file
|
||||
JAVA\COM\UN4SEEN\BASS\
|
||||
BASSMIDI.JAVA BASSMIDI Java class
|
||||
EXAMPLES\ Java examples
|
||||
BUILD.GRADLE Android Studio build script for examples
|
||||
SETTINGS.GRADLE
|
||||
PROGUARD-BASS.PRO
|
||||
MIDITEST\ MIDI playback example
|
||||
...
|
||||
|
||||
NOTE: To build the examples, you will need to copy the BASS API into the same
|
||||
directory as the BASSMIDI API.
|
||||
|
||||
iOS version
|
||||
-----------
|
||||
BASSMIDI.TXT This file
|
||||
BASSMIDI.XCFRAMEWORK BASSMIDI framework
|
||||
BASSMIDI.CHM BASSMIDI documentation
|
||||
BASSMIDI.H BASSMIDI C/C++ header file
|
||||
|
||||
|
||||
What's the point?
|
||||
=================
|
||||
BASSMIDI is an extension to the BASS audio library, enabling the playing of
|
||||
MIDI files and custom event sequences, using SF2 (including SF2PACK and SF3)
|
||||
and/or SFZ soundfonts to provide the sounds. MIDI input is also supported.
|
||||
|
||||
|
||||
Requirements
|
||||
============
|
||||
BASS 2.4 is required.
|
||||
|
||||
|
||||
Using BASSMIDI
|
||||
==============
|
||||
The MIDI format is used in very much the same way as any of the built-in BASS
|
||||
stream formats; simply call the MIDI stream creation function instead of the
|
||||
BASS built-in functions. The BASS plugin system (see BASS_PluginLoad) is also
|
||||
supported.
|
||||
|
||||
SF2 and SFZ soundfonts are used to provide the sounds. There are several
|
||||
soundfonts available on the internet, including a couple on the BASS webpage.
|
||||
On Windows, the Creative 28MB (28MBGM.SF2), 8MB (CT8MGM.SF2), 4MB (CT4MGM.SF2),
|
||||
or 2MB (CT2MGM.SF2) soundfont will be used by default when present in the
|
||||
Windows system directory.
|
||||
|
||||
The usage information in the BASS.TXT file (from the BASS package) is also
|
||||
applicable to BASSMIDI and other add-ons.
|
||||
|
||||
TIP: The BASSMIDI.CHM file should be put in the same directory as the BASS.CHM
|
||||
file, so that the BASSMIDI documentation can be accessed from within the
|
||||
BASS documentation.
|
||||
|
||||
iOS version
|
||||
-----------
|
||||
The CoreMIDI framework is required for MIDI input, so that should be added to
|
||||
the "Link Binary With Libraries" build phase in Xcode.
|
||||
|
||||
|
||||
Latest Version
|
||||
==============
|
||||
The latest versions of BASSMIDI & BASS can be found at the BASS website:
|
||||
|
||||
www.un4seen.com
|
||||
|
||||
|
||||
Licence
|
||||
=======
|
||||
BASSMIDI is free to use with BASS.
|
||||
|
||||
TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, BASSMIDI IS PROVIDED
|
||||
"AS IS", WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
AND/OR FITNESS FOR A PARTICULAR PURPOSE. THE AUTHORS SHALL NOT BE HELD
|
||||
LIABLE FOR ANY DAMAGE THAT MAY RESULT FROM THE USE OF BASSMIDI. YOU USE
|
||||
BASSMIDI ENTIRELY AT YOUR OWN RISK.
|
||||
|
||||
Usage of BASSMIDI indicates that you agree to the above conditions.
|
||||
|
||||
All trademarks and other registered names contained in the BASSMIDI
|
||||
package are the property of their respective owners.
|
||||
|
||||
|
||||
History
|
||||
=======
|
||||
These are the major (and not so major) changes in each release, along with the
|
||||
functions/options that are introduced/affected by them. There are other little
|
||||
tweaks and fixes made along the way too.
|
||||
|
||||
2.4.15 - 9/10/2024
|
||||
------------------
|
||||
* Support for Key On Velocity to attackModEnv/decayModEnv/releaseModEnv and
|
||||
Key Number to startAddrsOffset SF2 modulators
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for fileg_vel2attack/fileg_vel2decay/fileg_vel2release/pitcheg_vel2attack/
|
||||
pitcheg_vel2decay/pitcheg_vel2release SFZ opcodes
|
||||
BASS_MIDI_FontInit/User
|
||||
* Improved SFZ variable parsing compatibility (uses the shortest match)
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for high-pass filter in fil_type SFZ opcode
|
||||
BASS_MIDI_FontInit/User
|
||||
* SoundBlaster hardware limit emulation is disabled by default for modern SF2 soundfonts
|
||||
BASS_MIDI_FONT_SBLIMITS/NOSBLIMITS (BASS_MIDI_FontInit/User flags)
|
||||
* Extended filter cutoff range when SB limits are disabled
|
||||
BASS_MIDI_FONT_NOSBLIMITS (BASS_MIDI_FontInit/User flag)
|
||||
* Improved single note releasing when there are overlapping instances of the same note
|
||||
BASS_MIDI_NOTEOFF1 (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
* Ports above 7 are mapped to lower ports (modulo 8)
|
||||
BASS_MIDI_StreamCreateFile
|
||||
* Higher ports are shifted to lower channels when lower ports are unused
|
||||
BASS_MIDI_StreamCreateFile
|
||||
* Default per-drum USERFX levels to 127 instead of 0 in all modes
|
||||
BASS_MIDI_NODRUMPARAMUSER (BASS_MIDI_StreamCreate/Events/File/User/URL flag)
|
||||
* Per-drum key settings may be applied to all keys at once
|
||||
MIDI_EVENT_DRUM_xxx (BASS_MIDI_StreamEvent/s)
|
||||
* System mode/reset events are ignored from additional ports
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
BASS_MIDI_StreamEvents
|
||||
* Sequencer specific meta-event retrieval
|
||||
BASS_MIDI_MARK_SEQSPEC (BASS_MIDI_StreamGetMark type)
|
||||
* Queued event buffer preallocation
|
||||
BASS_ATTRIB_MIDI_QUEUE_TICK/BYTE/ASYNC (BASS_ChannelSetAttribute options)
|
||||
* Faster SFZ info retrieval
|
||||
BASS_MIDI_FontGetInfo
|
||||
* Support for SF2 soundfonts embedded in RMID files
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
* RIFF/RMID "INFO" tag support
|
||||
BASS_TAG_RIFF_INFO (BASS_ChannelGetTags type)
|
||||
* MIDI filename retrieval
|
||||
BASS_CHANNELINFO (filename member)
|
||||
* Approximate support for AWE32 filter NRPN (7f15/7f16)
|
||||
MIDI_EVENT_CUTOFF/RESONANCE
|
||||
* Maximum voices is practically unlimited (~14 million)
|
||||
BASS_CONFIG_MIDI_VOICES (BASS_SetConfig option)
|
||||
BASS_ATTRIB_MIDI_VOICES (BASS_ChannelSetAttribute option)
|
||||
|
||||
2.4.14 - 3/5/2022
|
||||
-----------------
|
||||
* Support for Key On Velocity to startAddrsOffset/modEnvToFilterFc and CC21-24 to initialFilterFc/
|
||||
initialAttenuation/attackVolEnv/decayVolEnv/releaseVolEnv/releaseModEnv/modEnvToFilterFc SF2 modulators
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for all Key On Velocity to initialAttenuation SF2 modulator curve types
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for SF3 (compressed SF2) soundfonts
|
||||
BASS_MIDI_FontInit/User
|
||||
* Soundfont flag setting/retrieval
|
||||
BASS_MIDI_FontFlags
|
||||
* Retrieval of currently loading samples
|
||||
BASS_CONFIG_MIDI_SAMPLELOADING (BASS_GetConfig option)
|
||||
* Channel-specific soundfont configuration
|
||||
BASS_MIDI_FONT_EX2 (BASS_MIDI_StreamSetFonts/GetFonts flag)
|
||||
BASS_MIDI_FONTEX2 structure
|
||||
* MIDI port meta-event support (for more than 16 channels)
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
BASS_MIDI_StreamEvents
|
||||
BASS_MIDI_ConvertEvents
|
||||
* Asynchronous processing of live events
|
||||
BASS_MIDI_ASYNC (BASS_MIDI_StreamCreate/Events/File/User/URL flag)
|
||||
BASS_MIDI_EVENTS_ASYNC (BASS_MIDI_StreamEvents flag)
|
||||
BASS_MIDI_EVENTS_FLUSH (BASS_MIDI_StreamEvents flag)
|
||||
SYNTH example updated
|
||||
* Filtering of live events
|
||||
BASS_MIDI_EVENTS_FILTER (BASS_MIDI_StreamEvents flag)
|
||||
* Improved reverb effect
|
||||
* Reverb/chorus levels raised (closer to Roland/Yamaha levels)
|
||||
* Current reverb/chorus type retrieval
|
||||
MIDI_EVENT_REVERB_MACRO (BASS_MIDI_StreamGetEvent)
|
||||
MIDI_EVENT_CHORUS_MACRO (BASS_MIDI_StreamGetEvent)
|
||||
* Treat soundfont reverb/chorus levels as minimums
|
||||
BASS_MIDI_FONT_MINFX (BASS_MIDI_FontInit/User/Flags flag)
|
||||
* Default per-drum reverb/chorus levels now apply in all modes and can be disabled
|
||||
BASS_MIDI_NODRUMPARAM (BASS_MIDI_StreamCreate/Events/File/User/URL flag)
|
||||
* Default drum channel configuration
|
||||
BASS_EVENT_DEFDRUMS (BASS_MIDI_StreamEvent/s and BASS_MIDI_StreamCreateEvents)
|
||||
* Support for master tuning
|
||||
MIDI_EVENT_MASTER_FINETUNE/COARSETUNE (BASS_MIDI_StreamEvent/s)
|
||||
* Omni-on/off (CC124/125) are treated as all-notes-off (CC123)
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
BASS_MIDI_StreamEvents
|
||||
BASS_MIDI_ConvertEvents
|
||||
* 16 point sinc interpolation support on ARM platforms with NEON
|
||||
BASS_ATTRIB_MIDI_SRC (BASS_ChannelSetAttribute option)
|
||||
* Version number retrieval
|
||||
BASS_MIDI_GetVersion
|
||||
* BASS_CONFIG_MIDI_SFZHEAD value changed (was same as BASS_CONFIG_MIDI_SAMPLEREAD)
|
||||
BASS_CONFIG_MIDI_SFZHEAD (BASS_SetConfigPtr option)
|
||||
* MIDI implementation chart added to documentation
|
||||
|
||||
2.4.13 - 16/9/2020
|
||||
------------------
|
||||
* Vibrato rate/depth/delay adjustment
|
||||
MIDI_EVENT_VIBRATO_RATE/DEPTH/DELAY (BASS_MIDI_StreamEvent/s)
|
||||
* Support for Key Number to initialAttenuation/initialFilterFc/pan and Key On Velocity
|
||||
to decayVolEnv/releaseVolEnv SF2 modulators
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for amp_keycenter/amp_keytrack/ampeg_vel2release/delay_beats/fil_keycenter/
|
||||
fil_keytrack/locc67/hicc67/pan_keycenter/pan_keytrack/sw_default/sw_last/sw_lokey/
|
||||
sw_lolast/sw_hikey/sw_hilast SFZ opcodes
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for global and master headers and #define directive in SFZ files
|
||||
BASS_MIDI_FontInit/User
|
||||
* SFZ files share memory for common sample files
|
||||
BASS_MIDI_FontInit/User
|
||||
* Partial sample loading and unloading
|
||||
BASS_MIDI_FontLoadEx
|
||||
SYNTH example updated
|
||||
* Non-interpolated resampling option
|
||||
BASS_ATTRIB_MIDI_SRC (BASS_ChannelSetAttribute option)
|
||||
* Tempo modification attribute
|
||||
BASS_ATTRIB_MIDI_SPEED (BASS_ChannelSetAttribute option)
|
||||
MIDITEST example updated
|
||||
* Mix level control
|
||||
BASS_ATTRIB_MIDI_VOL (BASS_ChannelSetAttribute option)
|
||||
* Reverb level modification
|
||||
BASS_ATTRIB_MIDI_REVERB (BASS_ChannelSetAttribute option)
|
||||
* Global SFZ headers
|
||||
BASS_CONFIG_MIDI_SFZHEAD (BASS_SetConfigPtr option)
|
||||
* Linear volume envelopes option
|
||||
BASS_MIDI_FONT_LINDECVOL (BASS_MIDI_FontInit/User flag)
|
||||
* Disabling of sample ramping-in
|
||||
BASS_MIDI_FONT_NORAMPIN (BASS_MIDI_FontInit/User flag)
|
||||
* Disabling of Creative/SoundBlaster hardware limit emulation
|
||||
BASS_MIDI_FONT_NOLIMITS (BASS_MIDI_FontInit flag)
|
||||
* Duplicate soundfonts will be reloaded instead of shared if modified in the meantime
|
||||
BASS_MIDI_FontInit
|
||||
* Memory-mapped support for default soundfont option
|
||||
BASS_CONFIG_MIDI_DEFFONT
|
||||
* Retrieval of total memory usage for sample data
|
||||
BASS_CONFIG_MIDI_SAMPLEMEM (BASS_GetConfig option)
|
||||
* Total sample data size available for SFZ files
|
||||
BASS_MIDI_FontGetInfo
|
||||
* Adjustable asynchronous sample loading chunks
|
||||
BASS_CONFIG_MIDI_SAMPLEREAD (BASS_SetConfig option)
|
||||
* CPU usage limiting is enabled by default during playback
|
||||
BASS_MIDI_StreamCreate/Events/File/User/URL
|
||||
BASS_ATTRIB_MIDI_CPU (BASS_ChannelSetAttribute option)
|
||||
* Option to limit sample loading waiting without killing voices
|
||||
BASS_ATTRIB_MIDI_CPU (BASS_ChannelSetAttribute option)
|
||||
* Tick-based timing for realtime event streams
|
||||
BASS_MIDI_StreamCreate
|
||||
BASS_MIDI_StreamEvents
|
||||
BASS_ATTRIB_MIDI_PPQN (BASS_ChannelSetAttribute option)
|
||||
* 48000 Hz soundfont data encoding option
|
||||
BASS_MIDI_PACK_48KHZ (BASS_MIDI_FontPack flag)
|
||||
* macOS examples rewritten in Objective-C/Cocoa
|
||||
|
||||
2.4.12 - 9/11/2018
|
||||
------------------
|
||||
* Support for more than 16 MIDI channels in custom event sequences
|
||||
BASS_MIDI_StreamCreateEvents
|
||||
* Absolute timing option for custom events
|
||||
BASS_MIDI_EVENTS_ABSTIME (BASS_MIDI_StreamEvents flag)
|
||||
* Retrieval of note-on events
|
||||
MIDI_EVENT_NOTES (BASS_MIDI_StreamGetEvents/Ex filter)
|
||||
* Soundfont config can be modified without stopping currently playing notes
|
||||
BASS_MIDI_StreamSetFonts
|
||||
* Memory-mapped soundfonts can be preloaded/mapped
|
||||
BASS_MIDI_FontLoad
|
||||
* Support for Key On Velocity to initialAttenuation SF2 modulators
|
||||
BASS_MIDI_FontInit/User
|
||||
* Linear attack phase option for SF2 modulation envelopes
|
||||
BASS_MIDI_FONT_LINATTMOD (BASS_MIDI_FontInit/User flag)
|
||||
* The attack phase of SFZ pitch/filter envelopes is now linear instead of convex
|
||||
* Support for trigger/rt_decay/delay/amplfo_fade/fillfo_fade/pitchlfo_fade/pitch_random/
|
||||
xfin_lokey/xfin_hikey/xfout_lokey/xfout_hikey/xf_keycurve/xfin_lovel/xfin_hivel/
|
||||
xfout_lovel/xfout_hivel/xf_velcurve SFZ opcodes
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for separate amplifier/filter/pitch LFOs in SFZ
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for UTF-8 sample SFZ opcodes on Windows (already on other platforms)
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for #include directive in SFZ files
|
||||
BASS_MIDI_FontInit
|
||||
* SFZ files are no longer kept open/locked after being loaded
|
||||
BASS_MIDI_FontInit
|
||||
* Samples given more time to load asynchronously when CPU usage is low
|
||||
BASS_ATTRIB_MIDI_CPU (BASS_ChannelSetAttribute option)
|
||||
* BASS_MIDI_SINCINTER flag deprecated in favour of BASS_ATTRIB_MIDI_SRC attribute
|
||||
BASS_MIDI_StreamCreate/Events/File/User/URL
|
||||
* Smoother low-pass filter activation and deactivation
|
||||
* Fix for transpose/tune SFZ opcodes with encoded samples
|
||||
|
||||
2.4.11 - 30/3/2017
|
||||
------------------
|
||||
* Event modification/filtering
|
||||
BASS_MIDI_StreamSetFilter
|
||||
MIDIFILTERPROC
|
||||
* Simpler tempo modification
|
||||
MIDI_EVENT_SPEED (BASS_MIDI_StreamEvent)
|
||||
MIDITEST example updated
|
||||
* Checking whether individual notes are playing
|
||||
MIDI_EVENT_NOTE (BASS_MIDI_StreamGetEvent)
|
||||
* Retrieval of total number of notes playing in a channel
|
||||
MIDI_EVENT_NOTES (BASS_MIDI_StreamGetEvent)
|
||||
* Retrieval of currently active voices in a channel
|
||||
MIDI_EVENT_VOICES (BASS_MIDI_StreamGetEvent)
|
||||
* Retrieval of currently in use presets
|
||||
BASS_MIDI_StreamGetPreset
|
||||
* SFZ filenames are used as preset names
|
||||
BASS_MIDI_FontGetPreset
|
||||
* Support for loop info in FLAC samples used with SFZ (requires BASSFLAC 2.4.3)
|
||||
* Faster loading of very large MIDI files
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
* Faster unfiltered event counting
|
||||
BASS_MIDI_StreamGetEvents/Ex
|
||||
BASS_MIDI_ConvertEvents
|
||||
* 24-bit paramater passed to MIDI_EVENT_TEMPO event sync callbacks
|
||||
BASS_SYNC_MIDI_EVENT (BASS_ChannelSetSync type)
|
||||
* When getting the number of events, only those in the specified range are counted
|
||||
BASS_MIDI_StreamGetEventsEx
|
||||
* Invalid event types in custom sequences will give an error instead of being ignored
|
||||
BASS_MIDI_StreamCreateEvents
|
||||
|
||||
2.4.10 - 8/12/2016
|
||||
------------------
|
||||
* 16 point sinc interpolation option
|
||||
BASS_ATTRIB_MIDI_SRC (BASS_ChannelSetAttribute option)
|
||||
* Support for lorand/hirand/locc1/hicc1/locc64/hicc64/off_mode/default_path SFZ opcodes
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for Key On Velocity to initialFilterFc/attackVolEnv SF2 modulators
|
||||
BASS_MIDI_FontInit/User
|
||||
* Conversion of raw MIDI data to BASS_MIDI_EVENT
|
||||
BASS_MIDI_ConvertEvents
|
||||
* Modulation (CC1) destination control
|
||||
MIDI_EVENT_MOD_VIBRATO/PITCH/FILTER/VOLUME (BASS_MIDI_StreamEvent/s)
|
||||
MIDI_EVENT_MODRANGE superseded by MIDI_EVENT_MOD_VIBRATO
|
||||
* Sostenuto
|
||||
MIDI_EVENT_SOSTENUTO (BASS_MIDI_StreamEvent/s)
|
||||
* Legato channel mode
|
||||
MIDI_EVENT_MODE (BASS_MIDI_StreamEvent)
|
||||
* Partial retrieval of events
|
||||
BASS_MIDI_StreamGetEventsEx
|
||||
* Bulk MIDI state retrieval/setting
|
||||
BASS_ATTRIB_MIDI_STATE (BASS_ChannelGet/SetAttributeEx option)
|
||||
* Support for delaying custom events, including delta-time info in raw MIDI data
|
||||
BASS_MIDI_EVENTS_TIME (BASS_MIDI_StreamEvents flag)
|
||||
* Cancellation of pending custom events
|
||||
BASS_MIDI_EVENTS_CANCEL (BASS_MIDI_StreamEvents flag)
|
||||
* Marker for the start of each track in SMF2 files
|
||||
BASS_MIDI_MARK_TRACKSTART (BASS_MIDI_StreamGetMark type)
|
||||
* Ignoring of soundfont effect levels
|
||||
BASS_MIDI_FONT_NOFX (BASS_MIDI_FontInit/Ex flag)
|
||||
* Maximum voice limit increased to 100000
|
||||
BASS_CONFIG_MIDI_VOICES (BASS_SetConfig option)
|
||||
BASS_ATTRIB_MIDI_VOICES (BASS_ChannelSetAttribute option)
|
||||
* Unicode support for default soundfont option on Windows
|
||||
BASS_CONFIG_MIDI_DEFFONT
|
||||
* BASS_CONFIG_UNICODE option support for input device names
|
||||
BASS_MIDI_InGetDeviceInfo
|
||||
* Improved seeking with MIDI files that have events for a channel in multiple tracks
|
||||
BASS_ChannelSetPosition
|
||||
* Fix for 2GB size limit when unpacking a soundfont on Windows
|
||||
BASS_MIDI_FontUnpack
|
||||
|
||||
2.4.9 - 4/12/2014
|
||||
-----------------
|
||||
* SFZ soundfont support
|
||||
BASS_MIDI_FontInit/User
|
||||
* Support for XG drums in bank 127 of SF2 soundfonts
|
||||
BASS_MIDI_FONT_XGDRUMS (BASS_MIDI_FontInit/Ex flag)
|
||||
* Key pressure/aftertouch support
|
||||
MIDI_EVENT_KEYPRES (BASS_MIDI_StreamEvent/s)
|
||||
MIDI_EVENT_KEYPRES_VIBRATO/PITCH/FILTER/VOLUME (BASS_MIDI_StreamEvent/s)
|
||||
* 3rd effect path for custom processing
|
||||
BASS_MIDI_CHAN_USERFX (BASS_MIDI_StreamGetChannel option)
|
||||
MIDI_EVENT_USERFX (BASS_MIDI_StreamEvent/s)
|
||||
MIDI_EVENT_USERFX_LEVEL (BASS_MIDI_StreamEvent/s)
|
||||
MIDI_EVENT_USERFX_REVERB (BASS_MIDI_StreamEvent/s)
|
||||
MIDI_EVENT_USERFX_CHORUS (BASS_MIDI_StreamEvent/s)
|
||||
* Custom reverb/chorus effect processing
|
||||
BASS_MIDI_CHAN_CHORUS/REVERB (BASS_MIDI_StreamGetChannel options)
|
||||
* Custom channel processing output routed to reverb/chorus/custom effects
|
||||
BASS_MIDI_StreamGetChannel
|
||||
* Default drum reverb/chorus levels set to XG spec in XG mode (GS/GM modes too)
|
||||
MIDI_EVENT_DRUM_REVERB/CHORUS (BASS_MIDI_StreamEvent/s)
|
||||
* Decay time event
|
||||
MIDI_EVENT_DECAY (BASS_MIDI_StreamEvent/s)
|
||||
* Support for up to 65536 presets per bank
|
||||
BASS_MIDI_StreamSetFonts
|
||||
MIDI_EVENT_PROGRAM (BASS_MIDI_StreamEvent/s)
|
||||
* Input ports to receive MIDI data from other software on Linux
|
||||
BASS_MIDI_InInit
|
||||
BASS_CONFIG_MIDI_IN_PORTS (BASS_SetConfig option)
|
||||
SYNTH example updated
|
||||
* Single note releasing when there are overlapping instances of the same note
|
||||
BASS_MIDI_NOTEOFF1 (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
* Ignoring of system resets with unchanged mode
|
||||
BASS_MIDI_NOSYSRESET (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
MIDI_EVENT_SYSTEM (BASS_MIDI_StreamEvent/s)
|
||||
* Disabling of running status
|
||||
BASS_MIDI_EVENTS_NORSTATUS (BASS_MIDI_StreamEvents flag)
|
||||
* Maximum voice limit increased to 1000
|
||||
BASS_CONFIG_MIDI_VOICES (BASS_SetConfig option)
|
||||
BASS_ATTRIB_MIDI_VOICES (BASS_ChannelSetAttribute option)
|
||||
* Reduction of 24-bit data to 16-bit when packing soundfont samples
|
||||
BASS_MIDI_PACK_16BIT (BASS_MIDI_FontPack flag)
|
||||
* Support for remaining SF2 generators: fixed key, fixed velocity, key to vol/mod envelope hold/decay
|
||||
* Fix for multi-track custom event sequence stream creation
|
||||
BASS_MIDI_StreamCreateEvents
|
||||
|
||||
2.4.8 - 2/5/2013
|
||||
----------------
|
||||
* User file soundfont loading
|
||||
BASS_MIDI_FontInitUser
|
||||
* Retrieval of all of a soundfont's preset numbers
|
||||
BASS_MIDI_FontGetPresets
|
||||
* More flexible soundfont preset mapping
|
||||
BASS_MIDI_FONT_EX (BASS_MIDI_StreamSetFonts/GetFonts flag)
|
||||
BASS_MIDI_FONTEX structure
|
||||
* Bank LSB controller support
|
||||
MIDI_EVENT_BANK_LSB (BASS_MIDI_StreamEvent/s)
|
||||
BASS_MIDI_FONTEX structure
|
||||
* Modulation depth range control
|
||||
MIDI_EVENT_MODRANGE (BASS_MIDI_StreamEvent/s)
|
||||
* Channel pressure destination control
|
||||
MIDI_EVENT_CHANPRES_VIBRATO/PITCH/FILTER/VOLUME (BASS_MIDI_StreamEvent/s)
|
||||
* Unhandled controller event
|
||||
MIDI_EVENT_CONTROL (BASS_MIDI_StreamEvent/s)
|
||||
* Reverb send level default changed to 40 (was 0)
|
||||
MIDI_EVENT_REVERB (BASS_MIDI_StreamEvent/s)
|
||||
* Retrieval of events from all tracks at once
|
||||
BASS_MIDI_StreamGetEvents
|
||||
* Copyright/instrument/track name markers
|
||||
BASS_MIDI_MARK_COPY (BASS_MIDI_StreamGetMark type)
|
||||
BASS_MIDI_MARK_INST (BASS_MIDI_StreamGetMark type)
|
||||
BASS_MIDI_MARK_TRACK (BASS_MIDI_StreamGetMark type)
|
||||
* Retrieval of all markers at once
|
||||
BASS_MIDI_StreamGetMarks
|
||||
* New sync type that supports all marker types
|
||||
BASS_SYNC_MIDI_MARK (BASS_ChannelSetSync type)
|
||||
* Non-removal of empty space at the end of a MIDI file
|
||||
BASS_MIDI_NOCROP (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
* Omission of a WAVE header when packing soundfont samples
|
||||
BASS_MIDI_PACK_NOHEAD (BASS_MIDI_FontPack flag)
|
||||
* Streams created via the plugin system use the output device's sample rate
|
||||
BASS_StreamCreateFile/etc
|
||||
* Automatic BASS_UNICODE flag use in C++ and Delphi
|
||||
BASS_MIDI_StreamCreateFile/URL
|
||||
BASS_MIDI_FontInit/Pack/Unpack
|
||||
|
||||
2.4.7 - 29/6/2012
|
||||
-----------------
|
||||
* Custom event sequence streams
|
||||
BASS_MIDI_StreamCreateEvents
|
||||
* Sinc interpolated sample mixing
|
||||
BASS_MIDI_SINCINTER (BASS_MIDI_StreamCreate/Events/File/User/URL flag)
|
||||
* Asynchronous sample loading
|
||||
BASS_ATTRIB_MIDI_CPU (BASS_ChannelSetAttribute option)
|
||||
* Preset unloading
|
||||
BASS_MIDI_FontUnload
|
||||
* Note stopping without sustain/decay
|
||||
BASS_EVENT_NOTE (BASS_MIDI_StreamEvent/s)
|
||||
* Syncing on all event types
|
||||
BASS_SYNC_MIDI_EVENT (BASS_ChannelSetSync type)
|
||||
* Marker tick position retrieval
|
||||
BASS_MIDI_MARK_TICK (BASS_MIDI_StreamGetMark flag)
|
||||
* Maximum voice limit increased to 500
|
||||
BASS_CONFIG_MIDI_VOICES (BASS_SetConfig option)
|
||||
BASS_ATTRIB_MIDI_VOICES (BASS_ChannelSetAttribute option)
|
||||
* Default voice limit raised to 40 on Android/iOS
|
||||
BASS_CONFIG_MIDI_VOICES (BASS_SetConfig option)
|
||||
* Active voice count retrieval
|
||||
BASS_ATTRIB_MIDI_VOICES_ACTIVE (BASS_ChannelGetAttribute option)
|
||||
* Use of the device's current output rate
|
||||
BASS_MIDI_StreamCreate/Events/File/User/URL
|
||||
* Memory-mapped soundfont loading
|
||||
BASS_MIDI_FONT_MMAP (BASS_MIDI_FontInit flag)
|
||||
* Fix for applying multiple events in BASS_MIDI_EVENTS_STRUCT mode
|
||||
BASS_MIDI_StreamEvents
|
||||
* Marker sync compatibility (with mixer/splitter/tempo/reverse streams) fix
|
||||
BASS_SYNC_MIDI_MARKER/CUE/LYRIC (BASS_ChannelSetSync types)
|
||||
* MIDI sysex input compatibility fix for some drivers on Windows
|
||||
MIDIINPROC
|
||||
|
||||
2.4.6 - 30/3/2011
|
||||
-----------------
|
||||
* MIDI input device support
|
||||
BASS_MIDI_InGetDeviceInfo
|
||||
BASS_MIDI_InInit
|
||||
BASS_MIDI_InFree
|
||||
BASS_MIDI_InStart
|
||||
BASS_MIDI_InStop
|
||||
MIDIINPROC
|
||||
SYNTH example updated
|
||||
* Multiple event processing including support for raw MIDI data
|
||||
BASS_MIDI_StreamEvents
|
||||
* CPU usage limiting
|
||||
BASS_ATTRIB_MIDI_CPU (BASS_ChannelSetAttribute option)
|
||||
* Scale/octave tuning
|
||||
MIDI_EVENT_SCALETUNING (BASS_MIDI_StreamEvent/s)
|
||||
* Soft pedal event
|
||||
MIDI_EVENT_SOFT (BASS_MIDI_StreamEvent/s)
|
||||
* Random panning
|
||||
MIDI_EVENT_PAN (BASS_MIDI_StreamEvent/s)
|
||||
* System reset event
|
||||
MIDI_EVENT_SYSTEM/EX (BASS_MIDI_StreamEvent/s)
|
||||
* Resetting of overridden drum key pan/reverb/chorus back to normal
|
||||
MIDI_EVENT_DRUM_PAN/REVERB/CHORUS (BASS_MIDI_StreamEvent)
|
||||
* Retrieval of drum key event values
|
||||
BASS_MIDI_StreamGetEvent
|
||||
* All events initialized to a MIDI file's 1st tick values
|
||||
BASS_MIDI_StreamGetEvent
|
||||
* Adjustable MIDI channel count
|
||||
BASS_ATTRIB_MIDI_CHANS (BASS_ChannelSetAttribute option)
|
||||
* Adjustable voice limit
|
||||
BASS_ATTRIB_MIDI_VOICES (BASS_ChannelSetAttribute option)
|
||||
* Preloaded presets are not automatically compacted
|
||||
BASS_MIDI_FontLoad
|
||||
BASS_CONFIG_MIDI_COMPACT (BASS_SetConfig option)
|
||||
* Multiple instances of a soundfont
|
||||
BASS_MIDI_FontInit
|
||||
* Xcode examples project added for OSX
|
||||
|
||||
2.4.5 - 8/2/2010
|
||||
----------------
|
||||
* Key signature retrieval
|
||||
BASS_MIDI_MARK_KEYSIG (BASS_MIDI_StreamGetMark type)
|
||||
BASS_SYNC_MIDI_KEYSIG (BASS_ChannelSetSync type)
|
||||
* Tempo event initialized to MIDI file's 1st tick value
|
||||
MIDI_EVENT_TEMPO (BASS_MIDI_StreamGetEvent)
|
||||
* UTF-16 support on OSX
|
||||
BASS_UNICODE (BASS_MIDI_StreamCreateFile/BASS_MIDI_FontInit/Pack/Unpack flag)
|
||||
|
||||
2.4.4 - 24/8/2009
|
||||
-----------------
|
||||
* Attack & release time events
|
||||
MIDI_EVENT_ATTACK/RELEASE (BASS_MIDI_StreamEvent)
|
||||
* Drum key level NRPN event
|
||||
MIDI_EVENT_DRUM_LEVEL (BASS_MIDI_StreamEvent)
|
||||
* MIDI file event retrieval
|
||||
BASS_MIDI_StreamGetEvents
|
||||
* Time signature retrieval
|
||||
BASS_MIDI_MARK_TIMESIG (BASS_MIDI_StreamGetMark type)
|
||||
BASS_SYNC_MIDI_TIMESIG (BASS_ChannelSetSync type)
|
||||
* Default soundfont configuration
|
||||
BASS_CONFIG_MIDI_DEFFONT (BASS_SetConfig option)
|
||||
|
||||
2.4.3 - 19/3/2009
|
||||
-----------------
|
||||
* Possibility of applying DSP/FX to individual MIDI channels
|
||||
BASS_MIDI_StreamGetChannel
|
||||
* Per-track volume control
|
||||
BASS_ATTRIB_MIDI_TRACK_VOL (BASS_ChannelSetAttribute option)
|
||||
* Support for all tracks in format 2 MIDI files
|
||||
BASS_MIDI_StreamCreateFile/User/URL
|
||||
|
||||
2.4.2 - 28/10/2008
|
||||
------------------
|
||||
* Decaying of old sound when seeking
|
||||
BASS_MIDI_DECAYSEEK (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
MIDITEST example updated (C version)
|
||||
* End decaying now also applies when looping
|
||||
BASS_MIDI_DECAYEND (BASS_MIDI_StreamCreateFile/User/URL flag)
|
||||
* Support for 28MBGM.SF2 and CT8MGM.SF2 as default soundfonts
|
||||
|
||||
2.4.1 - 9/7/2008
|
||||
----------------
|
||||
* Ticks-per-beat retrieval
|
||||
BASS_ATTRIB_MIDI_PPQN (BASS_ChannelGetAttribute option)
|
||||
|
||||
2.4 - 2/4/2008
|
||||
--------------
|
||||
* Tick-based positioning
|
||||
BASS_POS_MIDI_TICK (BASS_ChannelGetLength/GetPosition/SetPosition mode)
|
||||
BASS_SYNC_MIDI_TICK (BASS_ChannelSetSync type)
|
||||
* Preset name retrieval
|
||||
BASS_MIDI_FontGetPreset
|
||||
* Text markers
|
||||
BASS_MIDI_MARK_TEXT (BASS_MIDI_StreamGetMark type)
|
||||
BASS_SYNC_MIDI_TEXT (BASS_ChannelSetSync type)
|
||||
* Individual marker retrieval
|
||||
BASS_MIDI_StreamGetMark
|
||||
BASS_MIDI_StreamGetMarks *removed*
|
||||
* Marker index passed to marker sync callbacks
|
||||
BASS_SYNC_MIDI_MARKER/CUE/LYRIC
|
||||
* Use of BASS_Init sample rate
|
||||
BASS_MIDI_StreamCreate/File/User/URL
|
||||
* Support for updated user file stream system
|
||||
BASS_MIDI_StreamCreateFileUser
|
||||
* 64-bit file positioning
|
||||
BASS_MIDI_StreamCreateFile
|
||||
* Callback "user" parameters changed to pointers
|
||||
BASS_MIDI_StreamCreateURL
|
||||
BASS_MIDI_StreamCreateFileUser
|
||||
|
||||
2.3.0.3 - 10/7/2007
|
||||
-------------------
|
||||
* Syncing on events
|
||||
BASS_SYNC_MIDI_EVENT (BASS_ChannelSetSync type)
|
||||
|
||||
2.3.0.2 - 26/2/2007
|
||||
-------------------
|
||||
* Reverb and chorus
|
||||
MIDI_EVENT_REVERB/CHORUS (BASS_MIDI_StreamEvent)
|
||||
MIDI_EVENT_REVERB_TIME/DELAY/LOCUTOFF/HICUTOFF/LEVEL (BASS_MIDI_StreamEvent)
|
||||
MIDI_EVENT_CHORUS_DELAY/DEPTH/RATE/FEEDBACK/LEVEL/REVERB (BASS_MIDI_StreamEvent)
|
||||
BASS_MIDI_NOFX (BASS_MIDI_StreamCreate/File/User/URL flag)
|
||||
* Resonant low-pass filters
|
||||
MIDI_EVENT_CUTOFF/RESONANCE (BASS_MIDI_StreamEvent)
|
||||
* Portamento
|
||||
MIDI_EVENT_PORTAMENTO/TIME/NOTE (BASS_MIDI_StreamEvent)
|
||||
* Fine-tuning
|
||||
MIDI_EVENT_FINETUNE/COARSETUNE (BASS_MIDI_StreamEvent)
|
||||
* Drum key specific parameters
|
||||
MIDI_EVENT_DRUM_FINETUNE/COARSETUNE/PAN/REVERB/CHORUS/CUTOFF/RESONANCE (BASS_MIDI_StreamEvent)
|
||||
* Support for mono channel mode
|
||||
MIDI_EVENT_MODE (BASS_MIDI_StreamEvent)
|
||||
* Support for master volume
|
||||
MIDI_EVENT_MASTERVOL (BASS_MIDI_StreamEvent)
|
||||
* Channel level control
|
||||
MIDI_EVENT_MIXLEVEL (BASS_MIDI_StreamEvent)
|
||||
* Channel transposing
|
||||
MIDI_EVENT_TRANSPOSE (BASS_MIDI_StreamEvent)
|
||||
* Retrieval of current event values
|
||||
BASS_MIDI_StreamGetEvent
|
||||
* Soundfont volume control
|
||||
BASS_MIDI_FontSetVolume/GetVolume
|
||||
* Track number added to markers and syncs
|
||||
BASS_MIDI_MARK (track member)
|
||||
BASS_SYNC_MIDI_MARKER/CUE/LYRIC
|
||||
|
||||
2.3.0.1 - 1/12/2006
|
||||
-------------------
|
||||
* Optionally apply matching soundfonts to all banks
|
||||
BASS_CONFIG_MIDI_AUTOFONT (BASS_SetConfig option)
|
||||
* Support for 0 length notes
|
||||
|
||||
2.3 - 14/11/2006
|
||||
----------------
|
||||
* First release
|
||||
|
||||
|
||||
Bug reports, Suggestions, Comments, Enquiries, etc
|
||||
==================================================
|
||||
If you have any of the aforementioned please visit the BASS forum at the
|
||||
website.
|
||||
|
1149
bass/inc/bass.h
Normal file
442
bass/inc/bassmidi.h
Normal file
@ -0,0 +1,442 @@
|
||||
/*
|
||||
BASSMIDI 2.4 C/C++ header file
|
||||
Copyright (c) 2006-2024 Un4seen Developments Ltd.
|
||||
|
||||
See the BASSMIDI.CHM file for more detailed documentation
|
||||
*/
|
||||
|
||||
#ifndef BASSMIDI_H
|
||||
#define BASSMIDI_H
|
||||
|
||||
#include "bass.h"
|
||||
|
||||
#if BASSVERSION!=0x204
|
||||
#error conflicting BASS and BASSMIDI versions
|
||||
#endif
|
||||
|
||||
#ifdef __OBJC__
|
||||
typedef int BOOL32;
|
||||
#define BOOL BOOL32 // override objc's BOOL
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef BASSMIDIDEF
|
||||
#define BASSMIDIDEF(f) WINAPI f
|
||||
#else
|
||||
#define NOBASSMIDIOVERLOADS
|
||||
#endif
|
||||
|
||||
typedef DWORD HSOUNDFONT; // soundfont handle
|
||||
|
||||
// Additional error codes returned by BASS_ErrorGetCode
|
||||
#define BASS_ERROR_MIDI_INCLUDE 7000 // SFZ include file could not be opened
|
||||
|
||||
// Additional BASS_SetConfig options
|
||||
#define BASS_CONFIG_MIDI_COMPACT 0x10400
|
||||
#define BASS_CONFIG_MIDI_VOICES 0x10401
|
||||
#define BASS_CONFIG_MIDI_AUTOFONT 0x10402
|
||||
#define BASS_CONFIG_MIDI_IN_PORTS 0x10404
|
||||
#define BASS_CONFIG_MIDI_SAMPLETHREADS 0x10406
|
||||
#define BASS_CONFIG_MIDI_SAMPLEMEM 0x10407
|
||||
#define BASS_CONFIG_MIDI_SAMPLEREAD 0x10408
|
||||
#define BASS_CONFIG_MIDI_SAMPLELOADING 0x1040a
|
||||
|
||||
// Additional BASS_SetConfigPtr options
|
||||
#define BASS_CONFIG_MIDI_DEFFONT 0x10403
|
||||
#define BASS_CONFIG_MIDI_SFZHEAD 0x10409
|
||||
|
||||
// Additional sync types
|
||||
#define BASS_SYNC_MIDI_MARK 0x10000
|
||||
#define BASS_SYNC_MIDI_MARKER 0x10000
|
||||
#define BASS_SYNC_MIDI_CUE 0x10001
|
||||
#define BASS_SYNC_MIDI_LYRIC 0x10002
|
||||
#define BASS_SYNC_MIDI_TEXT 0x10003
|
||||
#define BASS_SYNC_MIDI_EVENT 0x10004
|
||||
#define BASS_SYNC_MIDI_TICK 0x10005
|
||||
#define BASS_SYNC_MIDI_TIMESIG 0x10006
|
||||
#define BASS_SYNC_MIDI_KEYSIG 0x10007
|
||||
|
||||
// Additional BASS_MIDI_StreamCreateFile/etc flags
|
||||
#define BASS_MIDI_NODRUMPARAMUSER 0x200
|
||||
#define BASS_MIDI_NODRUMPARAM 0x400
|
||||
#define BASS_MIDI_NOSYSRESET 0x800
|
||||
#define BASS_MIDI_DECAYEND 0x1000
|
||||
#define BASS_MIDI_NOFX 0x2000
|
||||
#define BASS_MIDI_DECAYSEEK 0x4000
|
||||
#define BASS_MIDI_NOCROP 0x8000
|
||||
#define BASS_MIDI_NOTEOFF1 0x10000
|
||||
#define BASS_MIDI_ASYNC 0x400000
|
||||
#define BASS_MIDI_SINCINTER 0x800000
|
||||
|
||||
// BASS_MIDI_FontInit flags
|
||||
#define BASS_MIDI_FONT_MEM 0x10000
|
||||
#define BASS_MIDI_FONT_MMAP 0x20000
|
||||
#define BASS_MIDI_FONT_XGDRUMS 0x40000
|
||||
#define BASS_MIDI_FONT_NOFX 0x80000
|
||||
#define BASS_MIDI_FONT_LINATTMOD 0x100000
|
||||
#define BASS_MIDI_FONT_LINDECVOL 0x200000
|
||||
#define BASS_MIDI_FONT_NORAMPIN 0x400000
|
||||
#define BASS_MIDI_FONT_NOSBLIMITS 0x800000
|
||||
#define BASS_MIDI_FONT_NOLIMITS BASS_MIDI_FONT_NOSBLIMITS
|
||||
#define BASS_MIDI_FONT_MINFX 0x1000000
|
||||
#define BASS_MIDI_FONT_SBLIMITS 0x2000000
|
||||
|
||||
typedef struct {
|
||||
HSOUNDFONT font; // soundfont
|
||||
int preset; // preset number (-1=all)
|
||||
int bank;
|
||||
} BASS_MIDI_FONT;
|
||||
|
||||
typedef struct {
|
||||
HSOUNDFONT font; // soundfont
|
||||
int spreset; // source preset number
|
||||
int sbank; // source bank number
|
||||
int dpreset; // destination preset/program number
|
||||
int dbank; // destination bank number
|
||||
int dbanklsb; // destination bank number LSB
|
||||
} BASS_MIDI_FONTEX;
|
||||
|
||||
typedef struct {
|
||||
HSOUNDFONT font; // soundfont
|
||||
int spreset; // source preset number
|
||||
int sbank; // source bank number
|
||||
int dpreset; // destination preset/program number
|
||||
int dbank; // destination bank number
|
||||
int dbanklsb; // destination bank number LSB
|
||||
DWORD minchan; // minimum channel number
|
||||
DWORD numchan; // number of channels from minchan
|
||||
} BASS_MIDI_FONTEX2;
|
||||
|
||||
// BASS_MIDI_StreamSet/GetFonts flag
|
||||
#define BASS_MIDI_FONT_EX 0x1000000 // BASS_MIDI_FONTEX
|
||||
#define BASS_MIDI_FONT_EX2 0x2000000 // BASS_MIDI_FONTEX2
|
||||
|
||||
typedef struct {
|
||||
const char *name;
|
||||
const char *copyright;
|
||||
const char *comment;
|
||||
DWORD presets; // number of presets/instruments
|
||||
DWORD samsize; // total size (in bytes) of the sample data
|
||||
DWORD samload; // amount of sample data currently loaded
|
||||
DWORD samtype; // sample format (CTYPE) if packed
|
||||
} BASS_MIDI_FONTINFO;
|
||||
|
||||
typedef struct {
|
||||
DWORD track; // track containing marker
|
||||
DWORD pos; // marker position
|
||||
const char *text; // marker text
|
||||
} BASS_MIDI_MARK;
|
||||
|
||||
// Marker types
|
||||
#define BASS_MIDI_MARK_MARKER 0 // marker
|
||||
#define BASS_MIDI_MARK_CUE 1 // cue point
|
||||
#define BASS_MIDI_MARK_LYRIC 2 // lyric
|
||||
#define BASS_MIDI_MARK_TEXT 3 // text
|
||||
#define BASS_MIDI_MARK_TIMESIG 4 // time signature
|
||||
#define BASS_MIDI_MARK_KEYSIG 5 // key signature
|
||||
#define BASS_MIDI_MARK_COPY 6 // copyright notice
|
||||
#define BASS_MIDI_MARK_TRACK 7 // track name
|
||||
#define BASS_MIDI_MARK_INST 8 // instrument name
|
||||
#define BASS_MIDI_MARK_TRACKSTART 9 // track start (SMF2)
|
||||
#define BASS_MIDI_MARK_SEQSPEC 10 // sequencer-specific
|
||||
#define BASS_MIDI_MARK_TICK 0x10000 // flag: get position in ticks (otherwise bytes)
|
||||
|
||||
// MIDI events
|
||||
#define MIDI_EVENT_NOTE 1
|
||||
#define MIDI_EVENT_PROGRAM 2
|
||||
#define MIDI_EVENT_CHANPRES 3
|
||||
#define MIDI_EVENT_PITCH 4
|
||||
#define MIDI_EVENT_PITCHRANGE 5
|
||||
#define MIDI_EVENT_DRUMS 6
|
||||
#define MIDI_EVENT_FINETUNE 7
|
||||
#define MIDI_EVENT_COARSETUNE 8
|
||||
#define MIDI_EVENT_MASTERVOL 9
|
||||
#define MIDI_EVENT_BANK 10
|
||||
#define MIDI_EVENT_MODULATION 11
|
||||
#define MIDI_EVENT_VOLUME 12
|
||||
#define MIDI_EVENT_PAN 13
|
||||
#define MIDI_EVENT_EXPRESSION 14
|
||||
#define MIDI_EVENT_SUSTAIN 15
|
||||
#define MIDI_EVENT_SOUNDOFF 16
|
||||
#define MIDI_EVENT_RESET 17
|
||||
#define MIDI_EVENT_NOTESOFF 18
|
||||
#define MIDI_EVENT_PORTAMENTO 19
|
||||
#define MIDI_EVENT_PORTATIME 20
|
||||
#define MIDI_EVENT_PORTANOTE 21
|
||||
#define MIDI_EVENT_MODE 22
|
||||
#define MIDI_EVENT_REVERB 23
|
||||
#define MIDI_EVENT_CHORUS 24
|
||||
#define MIDI_EVENT_CUTOFF 25
|
||||
#define MIDI_EVENT_RESONANCE 26
|
||||
#define MIDI_EVENT_RELEASE 27
|
||||
#define MIDI_EVENT_ATTACK 28
|
||||
#define MIDI_EVENT_DECAY 29
|
||||
#define MIDI_EVENT_REVERB_MACRO 30
|
||||
#define MIDI_EVENT_CHORUS_MACRO 31
|
||||
#define MIDI_EVENT_REVERB_TIME 32
|
||||
#define MIDI_EVENT_REVERB_DELAY 33
|
||||
#define MIDI_EVENT_REVERB_LOCUTOFF 34
|
||||
#define MIDI_EVENT_REVERB_HICUTOFF 35
|
||||
#define MIDI_EVENT_REVERB_LEVEL 36
|
||||
#define MIDI_EVENT_CHORUS_DELAY 37
|
||||
#define MIDI_EVENT_CHORUS_DEPTH 38
|
||||
#define MIDI_EVENT_CHORUS_RATE 39
|
||||
#define MIDI_EVENT_CHORUS_FEEDBACK 40
|
||||
#define MIDI_EVENT_CHORUS_LEVEL 41
|
||||
#define MIDI_EVENT_CHORUS_REVERB 42
|
||||
#define MIDI_EVENT_USERFX 43
|
||||
#define MIDI_EVENT_USERFX_LEVEL 44
|
||||
#define MIDI_EVENT_USERFX_REVERB 45
|
||||
#define MIDI_EVENT_USERFX_CHORUS 46
|
||||
#define MIDI_EVENT_DRUM_FINETUNE 50
|
||||
#define MIDI_EVENT_DRUM_COARSETUNE 51
|
||||
#define MIDI_EVENT_DRUM_PAN 52
|
||||
#define MIDI_EVENT_DRUM_REVERB 53
|
||||
#define MIDI_EVENT_DRUM_CHORUS 54
|
||||
#define MIDI_EVENT_DRUM_CUTOFF 55
|
||||
#define MIDI_EVENT_DRUM_RESONANCE 56
|
||||
#define MIDI_EVENT_DRUM_LEVEL 57
|
||||
#define MIDI_EVENT_DRUM_USERFX 58
|
||||
#define MIDI_EVENT_SOFT 60
|
||||
#define MIDI_EVENT_SYSTEM 61
|
||||
#define MIDI_EVENT_TEMPO 62
|
||||
#define MIDI_EVENT_SCALETUNING 63
|
||||
#define MIDI_EVENT_CONTROL 64
|
||||
#define MIDI_EVENT_CHANPRES_VIBRATO 65
|
||||
#define MIDI_EVENT_CHANPRES_PITCH 66
|
||||
#define MIDI_EVENT_CHANPRES_FILTER 67
|
||||
#define MIDI_EVENT_CHANPRES_VOLUME 68
|
||||
#define MIDI_EVENT_MOD_VIBRATO 69
|
||||
#define MIDI_EVENT_MODRANGE 69
|
||||
#define MIDI_EVENT_BANK_LSB 70
|
||||
#define MIDI_EVENT_KEYPRES 71
|
||||
#define MIDI_EVENT_KEYPRES_VIBRATO 72
|
||||
#define MIDI_EVENT_KEYPRES_PITCH 73
|
||||
#define MIDI_EVENT_KEYPRES_FILTER 74
|
||||
#define MIDI_EVENT_KEYPRES_VOLUME 75
|
||||
#define MIDI_EVENT_SOSTENUTO 76
|
||||
#define MIDI_EVENT_MOD_PITCH 77
|
||||
#define MIDI_EVENT_MOD_FILTER 78
|
||||
#define MIDI_EVENT_MOD_VOLUME 79
|
||||
#define MIDI_EVENT_VIBRATO_RATE 80
|
||||
#define MIDI_EVENT_VIBRATO_DEPTH 81
|
||||
#define MIDI_EVENT_VIBRATO_DELAY 82
|
||||
#define MIDI_EVENT_MASTER_FINETUNE 83
|
||||
#define MIDI_EVENT_MASTER_COARSETUNE 84
|
||||
#define MIDI_EVENT_MIXLEVEL 0x10000
|
||||
#define MIDI_EVENT_TRANSPOSE 0x10001
|
||||
#define MIDI_EVENT_SYSTEMEX 0x10002
|
||||
#define MIDI_EVENT_SPEED 0x10004
|
||||
#define MIDI_EVENT_DEFDRUMS 0x10006
|
||||
|
||||
#define MIDI_EVENT_END 0
|
||||
#define MIDI_EVENT_END_TRACK 0x10003
|
||||
|
||||
#define MIDI_EVENT_NOTES 0x20000
|
||||
#define MIDI_EVENT_VOICES 0x20001
|
||||
|
||||
#define MIDI_SYSTEM_DEFAULT 0
|
||||
#define MIDI_SYSTEM_GM1 1
|
||||
#define MIDI_SYSTEM_GM2 2
|
||||
#define MIDI_SYSTEM_XG 3
|
||||
#define MIDI_SYSTEM_GS 4
|
||||
|
||||
typedef struct {
|
||||
DWORD event; // MIDI_EVENT_xxx
|
||||
DWORD param;
|
||||
DWORD chan;
|
||||
DWORD tick; // event position (ticks)
|
||||
DWORD pos; // event position (bytes)
|
||||
} BASS_MIDI_EVENT;
|
||||
|
||||
// BASS_MIDI_StreamEvents modes
|
||||
#define BASS_MIDI_EVENTS_STRUCT 0 // BASS_MIDI_EVENT structures
|
||||
#define BASS_MIDI_EVENTS_RAW 0x10000 // raw MIDI event data
|
||||
#define BASS_MIDI_EVENTS_SYNC 0x1000000 // flag: trigger event syncs
|
||||
#define BASS_MIDI_EVENTS_NORSTATUS 0x2000000 // flag: no running status
|
||||
#define BASS_MIDI_EVENTS_CANCEL 0x4000000 // flag: cancel pending events
|
||||
#define BASS_MIDI_EVENTS_TIME 0x8000000 // flag: delta-time info is present
|
||||
#define BASS_MIDI_EVENTS_ABSTIME 0x10000000 // flag: absolute time info is present
|
||||
#define BASS_MIDI_EVENTS_ASYNC 0x20000000 // flag: process asynchronously
|
||||
#define BASS_MIDI_EVENTS_FILTER 0x40000000 // flag: apply filtering
|
||||
#define BASS_MIDI_EVENTS_FLUSH 0x80000000 // flag: flush async events
|
||||
|
||||
// BASS_MIDI_StreamGetChannel special channels
|
||||
#define BASS_MIDI_CHAN_CHORUS (DWORD)-1
|
||||
#define BASS_MIDI_CHAN_REVERB (DWORD)-2
|
||||
#define BASS_MIDI_CHAN_USERFX (DWORD)-3
|
||||
|
||||
// BASS_CHANNELINFO type
|
||||
#define BASS_CTYPE_STREAM_MIDI 0x10d00
|
||||
|
||||
// Additional attributes
|
||||
#define BASS_ATTRIB_MIDI_PPQN 0x12000
|
||||
#define BASS_ATTRIB_MIDI_CPU 0x12001
|
||||
#define BASS_ATTRIB_MIDI_CHANS 0x12002
|
||||
#define BASS_ATTRIB_MIDI_VOICES 0x12003
|
||||
#define BASS_ATTRIB_MIDI_VOICES_ACTIVE 0x12004
|
||||
#define BASS_ATTRIB_MIDI_STATE 0x12005
|
||||
#define BASS_ATTRIB_MIDI_SRC 0x12006
|
||||
#define BASS_ATTRIB_MIDI_KILL 0x12007
|
||||
#define BASS_ATTRIB_MIDI_SPEED 0x12008
|
||||
#define BASS_ATTRIB_MIDI_REVERB 0x12009
|
||||
#define BASS_ATTRIB_MIDI_VOL 0x1200a
|
||||
#define BASS_ATTRIB_MIDI_QUEUE_TICK 0x1200b
|
||||
#define BASS_ATTRIB_MIDI_QUEUE_BYTE 0x1200c
|
||||
#define BASS_ATTRIB_MIDI_QUEUE_ASYNC 0x1200d
|
||||
#define BASS_ATTRIB_MIDI_TRACK_VOL 0x12100 // + track #
|
||||
|
||||
// Additional tag type
|
||||
#define BASS_TAG_MIDI_TRACK 0x11000 // + track #, track text : array of null-terminated ANSI strings
|
||||
|
||||
// BASS_ChannelGetLength/GetPosition/SetPosition mode
|
||||
#define BASS_POS_MIDI_TICK 2 // tick position
|
||||
|
||||
typedef BOOL (CALLBACK MIDIFILTERPROC)(HSTREAM handle, int track, BASS_MIDI_EVENT *event, BOOL seeking, void *user);
|
||||
/* Event filtering callback function.
|
||||
handle : MIDI stream handle
|
||||
track : Track containing the event
|
||||
event : The event
|
||||
seeking: TRUE = the event is being processed while seeking, FALSE = it is being played
|
||||
user : The 'user' parameter value given when calling BASS_MIDI_StreamSetFilter
|
||||
RETURN : TRUE = process the event, FALSE = drop the event */
|
||||
|
||||
// BASS_MIDI_FontLoadEx flags
|
||||
#define BASS_MIDI_FONTLOAD_NOWAIT 1 // don't want for the samples to load
|
||||
#define BASS_MIDI_FONTLOAD_COMPACT 2 // compact samples
|
||||
#define BASS_MIDI_FONTLOAD_NOLOAD 4 // don't load (only compact)
|
||||
#define BASS_MIDI_FONTLOAD_TIME 8 // length is in milliseconds
|
||||
#define BASS_MIDI_FONTLOAD_KEEPDEC 16 // keep decoders
|
||||
|
||||
// BASS_MIDI_FontPack flags
|
||||
#define BASS_MIDI_PACK_NOHEAD 1 // don't send a WAV header to the encoder
|
||||
#define BASS_MIDI_PACK_16BIT 2 // discard low 8 bits of 24-bit sample data
|
||||
#define BASS_MIDI_PACK_48KHZ 4 // set encoding rate to 48000 Hz (else 44100 Hz)
|
||||
|
||||
typedef struct {
|
||||
const char *name; // description
|
||||
DWORD id;
|
||||
DWORD flags;
|
||||
} BASS_MIDI_DEVICEINFO;
|
||||
|
||||
typedef void (CALLBACK MIDIINPROC)(DWORD device, double time, const BYTE *buffer, DWORD length, void *user);
|
||||
/* MIDI input callback function.
|
||||
device : MIDI input device
|
||||
time : Timestamp
|
||||
buffer : Buffer containing MIDI data
|
||||
length : Number of bytes of data
|
||||
user : The 'user' parameter value given when calling BASS_MIDI_InInit */
|
||||
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_GetVersion)(void);
|
||||
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamCreate)(DWORD channels, DWORD flags, DWORD freq);
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamCreateFile)(BOOL mem, const void *file, QWORD offset, QWORD length, DWORD flags, DWORD freq);
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamCreateURL)(const char *url, DWORD offset, DWORD flags, DOWNLOADPROC *proc, void *user, DWORD freq);
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamCreateFileUser)(DWORD system, DWORD flags, const BASS_FILEPROCS *procs, void *user, DWORD freq);
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamCreateEvents)(const BASS_MIDI_EVENT *events, DWORD ppqn, DWORD flags, DWORD freq);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamGetMark)(HSTREAM handle, DWORD type, DWORD index, BASS_MIDI_MARK *mark);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamGetMarks)(HSTREAM handle, int track, DWORD type, BASS_MIDI_MARK *marks);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamSetFonts)(HSTREAM handle, const void *fonts, DWORD count);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamGetFonts)(HSTREAM handle, void *fonts, DWORD count);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamLoadSamples)(HSTREAM handle);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamEvent)(HSTREAM handle, DWORD chan, DWORD event, DWORD param);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamEvents)(HSTREAM handle, DWORD mode, const void *events, DWORD length);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamGetEvent)(HSTREAM handle, DWORD chan, DWORD event);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamGetEvents)(HSTREAM handle, int track, DWORD filter, BASS_MIDI_EVENT *events);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_StreamGetEventsEx)(HSTREAM handle, int track, DWORD filter, BASS_MIDI_EVENT *events, DWORD start, DWORD count);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamGetPreset)(HSTREAM handle, DWORD chan, BASS_MIDI_FONT *font);
|
||||
HSTREAM BASSMIDIDEF(BASS_MIDI_StreamGetChannel)(HSTREAM handle, DWORD chan);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_StreamSetFilter)(HSTREAM handle, BOOL seeking, MIDIFILTERPROC *proc, void *user);
|
||||
|
||||
HSOUNDFONT BASSMIDIDEF(BASS_MIDI_FontInit)(const void *file, DWORD flags);
|
||||
HSOUNDFONT BASSMIDIDEF(BASS_MIDI_FontInitUser)(const BASS_FILEPROCS *procs, void *user, DWORD flags);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontFree)(HSOUNDFONT handle);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontGetInfo)(HSOUNDFONT handle, BASS_MIDI_FONTINFO *info);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontGetPresets)(HSOUNDFONT handle, DWORD *presets);
|
||||
const char *BASSMIDIDEF(BASS_MIDI_FontGetPreset)(HSOUNDFONT handle, int preset, int bank);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontLoad)(HSOUNDFONT handle, int preset, int bank);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontLoadEx)(HSOUNDFONT handle, int preset, int bank, DWORD length, DWORD flags);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontUnload)(HSOUNDFONT handle, int preset, int bank);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontCompact)(HSOUNDFONT handle);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontPack)(HSOUNDFONT handle, const void *outfile, const void *encoder, DWORD flags);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontUnpack)(HSOUNDFONT handle, const void *outfile, DWORD flags);
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_FontFlags)(HSOUNDFONT handle, DWORD flags, DWORD mask);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_FontSetVolume)(HSOUNDFONT handle, float volume);
|
||||
float BASSMIDIDEF(BASS_MIDI_FontGetVolume)(HSOUNDFONT handle);
|
||||
|
||||
DWORD BASSMIDIDEF(BASS_MIDI_ConvertEvents)(const BYTE *data, DWORD length, BASS_MIDI_EVENT *events, DWORD count, DWORD flags);
|
||||
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_InGetDeviceInfo)(DWORD device, BASS_MIDI_DEVICEINFO *info);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_InInit)(DWORD device, MIDIINPROC *proc, void *user);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_InFree)(DWORD device);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_InStart)(DWORD device);
|
||||
BOOL BASSMIDIDEF(BASS_MIDI_InStop)(DWORD device);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
#ifndef NOBASSMIDIOVERLOADS
|
||||
static inline BOOL BASS_MIDI_StreamSetFonts(HSTREAM handle, const BASS_MIDI_FONTEX *fonts, DWORD count)
|
||||
{
|
||||
return BASS_MIDI_StreamSetFonts(handle, (const void*)fonts, count | BASS_MIDI_FONT_EX);
|
||||
}
|
||||
|
||||
static inline BOOL BASS_MIDI_StreamSetFonts(HSTREAM handle, const BASS_MIDI_FONTEX2 *fonts, DWORD count)
|
||||
{
|
||||
return BASS_MIDI_StreamSetFonts(handle, (const void*)fonts, count | BASS_MIDI_FONT_EX2);
|
||||
}
|
||||
|
||||
static inline DWORD BASS_MIDI_StreamGetFonts(HSTREAM handle, BASS_MIDI_FONTEX *fonts, DWORD count)
|
||||
{
|
||||
return BASS_MIDI_StreamGetFonts(handle, (void*)fonts, count | BASS_MIDI_FONT_EX);
|
||||
}
|
||||
|
||||
static inline DWORD BASS_MIDI_StreamGetFonts(HSTREAM handle, BASS_MIDI_FONTEX2 *fonts, DWORD count)
|
||||
{
|
||||
return BASS_MIDI_StreamGetFonts(handle, (void*)fonts, count | BASS_MIDI_FONT_EX2);
|
||||
}
|
||||
|
||||
#if __cplusplus >= 200707 || _MSC_VER >= 1600
|
||||
static inline DWORD BASS_MIDI_StreamGetFonts(HSTREAM handle, decltype(nullptr) fonts, DWORD count)
|
||||
{
|
||||
return BASS_MIDI_StreamGetFonts(handle, (void*)fonts, count);
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
static inline HSTREAM BASS_MIDI_StreamCreateFile(BOOL mem, const WCHAR *file, QWORD offset, QWORD length, DWORD flags, DWORD freq)
|
||||
{
|
||||
return BASS_MIDI_StreamCreateFile(mem, (const void*)file, offset, length, flags | BASS_UNICODE, freq);
|
||||
}
|
||||
|
||||
static inline HSTREAM BASS_MIDI_StreamCreateURL(const WCHAR *url, DWORD offset, DWORD flags, DOWNLOADPROC *proc, void *user, DWORD freq)
|
||||
{
|
||||
return BASS_MIDI_StreamCreateURL((const char*)url, offset, flags | BASS_UNICODE, proc, user, freq);
|
||||
}
|
||||
|
||||
static inline HSOUNDFONT BASS_MIDI_FontInit(const WCHAR *file, DWORD flags)
|
||||
{
|
||||
return BASS_MIDI_FontInit((const void*)file, flags|BASS_UNICODE);
|
||||
}
|
||||
|
||||
static inline BOOL BASS_MIDI_FontPack(HSOUNDFONT handle, const WCHAR *outfile, const WCHAR *encoder, DWORD flags)
|
||||
{
|
||||
return BASS_MIDI_FontPack(handle, (const void*)outfile, (const void*)encoder, flags | BASS_UNICODE);
|
||||
}
|
||||
|
||||
static inline BOOL BASS_MIDI_FontUnpack(HSOUNDFONT handle, const WCHAR *outfile, DWORD flags)
|
||||
{
|
||||
return BASS_MIDI_FontUnpack(handle, (const void*)outfile, flags | BASS_UNICODE);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __OBJC__
|
||||
#undef BOOL
|
||||
#endif
|
||||
|
||||
#endif
|
BIN
bass/lib/bass.lib
Normal file
BIN
bass/lib/bassmidi.lib
Normal file
BIN
bass/x64/bass.lib
Normal file
BIN
bass/x64/bassmidi.lib
Normal file
1
dxsdk3
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 71f5b1cb34ae2a215190b3aec87c3fc9646eb1d3
|
29
msvc5/msvc5.dsw
Normal file
@ -0,0 +1,29 @@
|
||||
Microsoft Developer Studio Workspace File, Format Version 5.00
|
||||
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
|
||||
|
||||
###############################################################################
|
||||
|
||||
Project: "sb2decomp"=".\sb2decomp\sb2decomp.dsp" - Package Owner=<4>
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<4>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
||||
Global:
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<3>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
252
msvc5/sb2decomp/sb2decomp.dsp
Normal file
@ -0,0 +1,252 @@
|
||||
# Microsoft Developer Studio Project File - Name="sb2decomp" - Package Owner=<4>
|
||||
# Microsoft Developer Studio Generated Build File, Format Version 5.00
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Application" 0x0101
|
||||
|
||||
CFG=sb2decomp - Win32 Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "sb2decomp.mak".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "sb2decomp.mak" CFG="sb2decomp - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "sb2decomp - Win32 Release" (based on "Win32 (x86) Application")
|
||||
!MESSAGE "sb2decomp - Win32 Debug" (based on "Win32 (x86) Application")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
CPP=cl.exe
|
||||
MTL=midl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "sb2decomp - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
|
||||
# ADD CPP /nologo /W3 /Gi /GX /O2 /I "..\..\dxsdk3\sdk\inc" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_X86_" /D WINVER=0x0400 /YX /FD /c
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o NUL /win32
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o NUL /win32
|
||||
# ADD BASE RSC /l 0x409 /d "NDEBUG"
|
||||
# ADD RSC /l 0x409 /d "NDEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
|
||||
# ADD LINK32 winmm.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ddraw.lib dsound.lib dplayx.lib dxguid.lib /nologo /subsystem:windows /machine:I386 /libpath:"..\..\dxsdk3\sdk\lib" /FORCE:MULTIPLE
|
||||
# SUBTRACT LINK32 /pdb:none
|
||||
|
||||
!ELSEIF "$(CFG)" == "sb2decomp - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
|
||||
# ADD CPP /nologo /W3 /Gm /Gi /GX /Zi /Od /I "..\..\dxsdk3\sdk\inc" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_X86_" /D WINVER=0x0400 /FR /YX /FD /c
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o NUL /win32
|
||||
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o NUL /win32
|
||||
# ADD BASE RSC /l 0x409 /d "_DEBUG"
|
||||
# ADD RSC /l 0x409 /d "_DEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept
|
||||
# ADD LINK32 winmm.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ddraw.lib dsound.lib dplayx.lib dxguid.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept /libpath:"..\..\dxsdk3\sdk\lib" /FORCE:MULTIPLE
|
||||
# SUBTRACT LINK32 /pdb:none
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "sb2decomp - Win32 Release"
|
||||
# Name "sb2decomp - Win32 Debug"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\blupi.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\button.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\button.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\ddutil.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\ddutil.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decblock.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decblupi.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decdesign.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decio.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decmove.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decnet.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decor.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\decor.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\dectables.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\def.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\event.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\event.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\jauge.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\jauge.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\menu.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\menu.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\misc.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\misc.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\movie.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\movie.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\network.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\network.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\obstacle.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\pixmap.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\pixmap.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\pixtables.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\resource.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\resource1.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\sound.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\sound.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\text.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\text.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\texttables.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\wave.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\src\wave.h
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
BIN
resource/Eggbert2.aps
Normal file
BIN
resource/Eggbert2.rc
Normal file
BIN
resource/IDC_ARROW.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWD.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWDL.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWDR.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWL.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWR.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWU.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWUL.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_ARROWUR.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_EMPTY.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_FILL.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_MAP.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_POINTER.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDC_WAIT.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/IDR_MAINFRAME.ico
Normal file
After Width: | Height: | Size: 766 B |
BIN
resource/RCa07276
Normal file
BIN
resource/RCa07552
Normal file
BIN
resource/RCa19860
Normal file
BIN
resource/RCb07276
Normal file
BIN
resource/RCb19860
Normal file
BIN
resource/RCc07276
Normal file
BIN
resource/RCc19860
Normal file
BIN
resource/RCd19860
Normal file
BIN
resource/Resource.aps
Normal file
BIN
resource/arrow.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowdl.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowdow.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowdr.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowlef.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowrig.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowul.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowup.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/arrowur.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/blupi-d.aps
Normal file
489
resource/blupi-d.rc
Normal file
@ -0,0 +1,489 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// French (Switzerland) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRS)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_FRENCH, SUBLANG_FRENCH_SWISS
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Icon
|
||||
//
|
||||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
IDR_MAINFRAME ICON DISCARDABLE "blupi.ico"
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 0,4,0,0
|
||||
PRODUCTVERSION 0,4,0,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x40004L
|
||||
FILETYPE 0x1L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "100c04b0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "EPSITEC\0"
|
||||
VALUE "FileDescription", "Blupi\0"
|
||||
VALUE "FileVersion", "0, 4, 0, 0\0"
|
||||
VALUE "InternalName", "Planet Blupi\0"
|
||||
VALUE "LegalCopyright", "Copyright © 1997\0"
|
||||
VALUE "OriginalFilename", "Blupi.exe\0"
|
||||
VALUE "ProductName", "EPSITEC Planet Blupi\0"
|
||||
VALUE "ProductVersion", "0, 4, 0, 0\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x100c, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Cursor
|
||||
//
|
||||
|
||||
IDC_POINTER CURSOR DISCARDABLE "cursor1.cur"
|
||||
IDC_MAP CURSOR DISCARDABLE "map.cur"
|
||||
IDC_ARROWU CURSOR DISCARDABLE "arrowup.cur"
|
||||
IDC_ARROWD CURSOR DISCARDABLE "arrowdow.cur"
|
||||
IDC_ARROWL CURSOR DISCARDABLE "arrowlef.cur"
|
||||
IDC_ARROWR CURSOR DISCARDABLE "arrowrig.cur"
|
||||
IDC_ARROWUL CURSOR DISCARDABLE "arrowul.cur"
|
||||
IDC_ARROWUR CURSOR DISCARDABLE "arrowur.cur"
|
||||
IDC_ARROWDR CURSOR DISCARDABLE "arrowdr.cur"
|
||||
IDC_ARROWDL CURSOR DISCARDABLE "arrowdl.cur"
|
||||
IDC_WAIT CURSOR DISCARDABLE "wait.cur"
|
||||
IDC_EMPTY CURSOR DISCARDABLE "empty.cur"
|
||||
IDC_FILL CURSOR DISCARDABLE "fill.cur"
|
||||
IDC_ARROW CURSOR DISCARDABLE "arrow.cur"
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// String Table
|
||||
//
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_GO "Gehen"
|
||||
TX_ACTION_STOP "Halt"
|
||||
TX_ACTION_MANGE "Essen"
|
||||
TX_ACTION_CARRY "Nehmen"
|
||||
TX_ACTION_DEPOSE "Hinlegen"
|
||||
TX_ACTION_ABAT "Baum fällen"
|
||||
TX_ACTION_ROC "Stein bearbeiten"
|
||||
TX_ACTION_CULTIVE "Garten anlegen"
|
||||
TX_ACTION_BUILD1 "Gartenhäuschen"
|
||||
TX_ACTION_BUILD2 "Brutplatz"
|
||||
TX_ACTION_BUILD3 "Labor"
|
||||
TX_ACTION_BUILD4 "Bergwerk"
|
||||
TX_ACTION_BUILD5 "Werkstatt"
|
||||
TX_ACTION_BUILD6 "Beamgerät"
|
||||
TX_ACTION_MUR "Mauer"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_PALIS "Palisade"
|
||||
TX_ACTION_ABATn "Bäume fällen"
|
||||
TX_ACTION_ROCn "Steine bearbeiten"
|
||||
TX_ACTION_PONT "Brücke"
|
||||
TX_ACTION_TOUR "Wachturm"
|
||||
TX_ACTION_BOIT "Trinken"
|
||||
TX_ACTION_LABO "Verarbeiten"
|
||||
TX_ACTION_FLEUR "Blumenstrauss machen"
|
||||
TX_ACTION_FLEURn "Blumensträusse machen"
|
||||
TX_ACTION_DYNAMITE "Zünden"
|
||||
TX_ACTION_BATEAU "Boot"
|
||||
TX_ACTION_DJEEP "Aussteigen"
|
||||
TX_ACTION_DRAPEAU "Eisen suchen"
|
||||
TX_ACTION_EXTRAIT "Eisen abbauen"
|
||||
TX_ACTION_FABJEEP "Jeep bauen"
|
||||
TX_ACTION_FABMINE "Zeitbombe bauen"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ERROR_MISC "Hier nicht möglich"
|
||||
TX_ERROR_GROUND "Untergrund nicht geeignet"
|
||||
TX_ERROR_FREE "Untergrund schon besetzt"
|
||||
TX_ERROR_PONTOP "Anderes Ufer nicht OK"
|
||||
TX_ERROR_PONTTERM "Brücke schon fertig"
|
||||
TX_ERROR_TOURISOL "(Alleinstehender Wachturm)"
|
||||
TX_ERROR_TOUREAU "Zu nahe am Wasser"
|
||||
TX_ERROR_TELE2 "Es gibt schon 2 Beammaschinen"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_IONAMEEX "Training %d, Zeit %d"
|
||||
TX_IOFREE "frei"
|
||||
TX_TERMMIN "Verloren sobald weniger als %d Blupis"
|
||||
TX_TERMMAX "Gewinnen unmöglich wenn weniger als %d Blupis"
|
||||
TX_BUTTON_JOUER "Missionen"
|
||||
TX_BUTTON_APPRENDRE "Training"
|
||||
TX_BUTTON_QUITTER "BLUPI beenden"
|
||||
TX_BUTTON_PREVP "Vorhergehende Mission"
|
||||
TX_BUTTON_NEXTP "Nächste Mission"
|
||||
TX_BUTTON_PLAYP "Diese Mission spielen"
|
||||
TX_BUTTON_BUILDP "Diese Mission konstruieren"
|
||||
TX_BUTTON_TERM "Beenden"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_READP "Gespeicherte Mission öffnen"
|
||||
TX_BUTTON_WRITEP "Mission speichern"
|
||||
TX_BUTTON_CANCELP "Mission aufgeben"
|
||||
TX_BUTTON_CONTP "Mission weiterspielen"
|
||||
TX_BUTTON_REPEAT "Neu Anfangen"
|
||||
TX_BUTTON_BUTTON "Zur Verfügung stehende Knöpfe"
|
||||
TX_BUTTON_CTERM "Bedingungen für Ende der Mission"
|
||||
TX_BUTTON_TERMC "Konstruktion beenden"
|
||||
TX_BUTTON_TERMHBLUPI "Blupi auf gestreiften Quadraten"
|
||||
TX_BUTTON_TERMHPLANCHE "Bretter auf gestreiften Quadraten"
|
||||
TX_BUTTON_TERMFIRE "Feuer ausgegangen"
|
||||
TX_BUTTON_TERMDEC "(-)"
|
||||
TX_BUTTON_TERMINC "(+)"
|
||||
TX_PAUSE "Pause"
|
||||
TX_JAUGE1 "Blupis Energie"
|
||||
TX_JAUGE2 "Arbeitsfortschritt"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP "Einstellungen"
|
||||
TX_BUTTON_MUSIC "Auswahl der Musik"
|
||||
TX_BUTTON_SETUP1 "Langsamer"
|
||||
TX_BUTTON_SETUP2 "Schneller"
|
||||
TX_BUTTON_SETUP3 "Leiser"
|
||||
TX_BUTTON_SETUP4 "Lauter"
|
||||
TX_BUTTON_MUSIC1 "Keine Musik"
|
||||
TX_BUTTON_MUSIC2 "Musik Nummer 1"
|
||||
TX_BUTTON_MUSIC3 "Musik Nummer 2"
|
||||
TX_BUTTON_MUSIC4 "Musik Nummer 3"
|
||||
TX_BUTTON_MUSIC5 "Musik Nummer 4"
|
||||
TX_BUTTON_MUSIC6 "Musik Nummer 5"
|
||||
TX_BUTTON_MUSIC7 "Musik Nummer 6"
|
||||
TX_BUTTON_MUSIC8 "Musik Nummer 7"
|
||||
TX_BUTTON_MUSIC9 "Musik Nummer 8"
|
||||
TX_BUTTON_MUSIC10 "Musik Nummer 9"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION "Auswahl der Umgebung"
|
||||
TX_BUTTON_TERMMBLUPI "Blupi im Haus"
|
||||
TX_BUTTON_TERMKILL "Keine Feinde mehr"
|
||||
TX_TERM "Bedingungen für\ndas Ende der Mission"
|
||||
TX_BUTTON "Zur Verfügung\nstehende Knöpfe"
|
||||
TX_MUSIC "Auswahl der Musik"
|
||||
TX_SCHOOL "Training Nummer"
|
||||
TX_MISSION "Mission Nummer"
|
||||
TX_IONAMEMI "Mission %d, Zeit %d"
|
||||
TX_BUTTON_TERMHTOMATE "Tomaten auf gestreiften Quadraten"
|
||||
TX_BUTTON_SETUP5 "Leiser"
|
||||
TX_BUTTON_SETUP6 "Lauter"
|
||||
TX_BUTTON_SETUP7 "Keine Videosequenzen"
|
||||
TX_BUTTON_SETUP8 "Zeigt die Videosequenzen"
|
||||
TX_OUI "Ja"
|
||||
TX_NON "Nein"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_BLUPIm "Kranker Blupi"
|
||||
TX_OBJ_BLUPIf "Erschöpfter Blupi"
|
||||
TX_OBJ_BLUPI "Blupi"
|
||||
TX_OBJ_BATEAU "Boot"
|
||||
TX_OBJ_JEEP "Jeep"
|
||||
TX_OBJ_PIEGE "Klebefalle"
|
||||
TX_OBJ_POISON "Gift"
|
||||
TX_OBJ_DYNAMITE "Dynamitstangen"
|
||||
TX_OBJ_MINE "Zeitbombe"
|
||||
TX_OBJ_TOMATE "Tomaten"
|
||||
TX_OBJ_POTION "Medikament"
|
||||
TX_OBJ_PLANCHE "Bretter"
|
||||
TX_OBJ_PIERRE "Steine"
|
||||
TX_OBJ_DRAPEAU "Wimpel"
|
||||
TX_OBJ_FER "Eisenerz"
|
||||
TX_OBJ_FLEUR1 "Blumen"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_FLEUR2 "Blumen"
|
||||
TX_OBJ_FLEUR3 "Blumen"
|
||||
TX_OBJ_CABANE "Gartenhäuschen"
|
||||
TX_OBJ_LABO "Labor"
|
||||
TX_OBJ_MINEFER "Bergwerk"
|
||||
TX_OBJ_USINE "Werkstatt"
|
||||
TX_OBJ_TOUR "Wachturm"
|
||||
TX_OBJ_FEU "Feuer"
|
||||
TX_OBJ_ROBOT "Roboterchef"
|
||||
TX_OBJ_TRACKS "Planierraupe"
|
||||
TX_OBJ_BOMBE "Springende Bombe"
|
||||
TX_OBJ_ARAIGNEE "Spinne"
|
||||
TX_OBJ_VIRUS "Virus"
|
||||
TX_OBJ_ELECTRO "Elektrisiermaschine"
|
||||
TX_OBJ_ARBRE "Bäume"
|
||||
TX_OBJ_MUR "Mauer"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_ARBREb "Baumstämme"
|
||||
TX_OBJ_ROC "Felsen"
|
||||
TX_OBJ_OEUF "Eier"
|
||||
TX_OBJ_PALISSADE "Palisade"
|
||||
TX_OBJ_ENNEMIp "Verklebter Feind"
|
||||
TX_OBJ_ENNEMI "Feindliche Einrichtung"
|
||||
TX_OBJ_HERBE "Normaler Untergrund"
|
||||
TX_OBJ_MOUSSE "Brennbarer Untergrund"
|
||||
TX_OBJ_TERRE "Karger Untergrund"
|
||||
TX_OBJ_EAU "Wasser"
|
||||
TX_OBJ_RIVE "Ufer"
|
||||
TX_OBJ_MIXTE "Gemischter Untergrund"
|
||||
TX_OBJ_PONT "Brücke"
|
||||
TX_OBJ_COUVEUSE "Brutplatz"
|
||||
TX_OBJ_GLACE "Eis"
|
||||
TX_OBJ_MAISON "Blupis Haus"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_HACHURE "Gestreifte Quadrate"
|
||||
TX_OBJ_MOUSSEb "Verbrannter Untergrund"
|
||||
TX_OBJ_BOUQUET1 "Blumenstrauss"
|
||||
TX_OBJ_BOUQUET2 "Blumenstrauss"
|
||||
TX_OBJ_BOUQUET3 "Blumenstrauss"
|
||||
TX_OBJ_DALLE "Platten"
|
||||
TX_OBJ_ENNEMIs "Feindesgrund"
|
||||
TX_OBJ_DISCIPLE "Hilfsroboter"
|
||||
TX_OBJ_METAL "Platinium"
|
||||
TX_OBJ_FUSEE "Feindliche Rakete"
|
||||
TX_OBJ_TELEPORTE "Beammaschine"
|
||||
TX_OBJ_ARMURE "Rüstung"
|
||||
TX_OBJ_DALLESPEC "Spezialplatten"
|
||||
TX_OBJ_COUVTELE "Brutplatz oder Beammaschine"
|
||||
TX_OBJ_BATIMENT "Gebäude"
|
||||
TX_OBJ_BATENNEMIS "Feindliches Gebäude"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_WIN1 "Toll, Du hast es geschafft"
|
||||
TX_WIN2 "Ja, super"
|
||||
TX_WIN3 "Sehr gut"
|
||||
TX_WIN4 "Ausgezeichnet"
|
||||
TX_WIN5 "Auftrag erfüllt"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST1 "Das war nichts, probier es noch einmal !"
|
||||
TX_LOST2 "Nein, so geht das leider nicht !"
|
||||
TX_LOST3 "Das war mal wieder nichts !"
|
||||
TX_LOST4 "Das war leider nicht die richtige Lösung !"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST5 "Aber nein, doch nicht so..."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LASTWIN1 "Du kannst jetzt mit den Missionen beginnen."
|
||||
TX_LASTWIN2 "Bravo, das Spiel ist beendet !"
|
||||
TX_LASTWIN3 "Letzte konstruierte Mission beendet."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP9 "Langsamer"
|
||||
TX_BUTTON_SETUP10 "Schneller"
|
||||
TX_INFO_SETUP1 "Globale\nGeschwindigkeit\ndes Spiels"
|
||||
TX_INFO_SETUP2 "Lautstärke der\nGeräuscheffekte"
|
||||
TX_INFO_SETUP3 "Lautstärke\nder Musik"
|
||||
TX_INFO_SETUP4 "Videosequenzen"
|
||||
TX_INFO_SETUP5 "Geschwindigkeit\nder Bildschirm-\nverschiebungen\nmit der Maus"
|
||||
TX_INFO_NOSCROLL "Keine"
|
||||
TX_BUTTON_REGION1 "Wiese"
|
||||
TX_BUTTON_REGION2 "Wüste"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION3 "Verschneiter Wald"
|
||||
TX_BUTTON_REGION4 "Wald"
|
||||
TX_REGION "Auswahl\nder Umgebung"
|
||||
TX_BUTTON_PLAY_STOP "Halt"
|
||||
TX_BUTTON_PLAY_SETUP "Einstellungen"
|
||||
TX_BUTTON_PLAY_WRITE "Speichern"
|
||||
TX_INSERT "Füge die Planet Blupi CD-Rom in das Laufwerk ein und warte einige Sekunden ..."
|
||||
TX_BUTTON_PREVH "Vorhergehende Seite"
|
||||
TX_BUTTON_NEXTH "Nächste Seite"
|
||||
TX_BUTTON_TERMHMETAL "Platinium auf gestreiften Quadraten"
|
||||
TX_BUTTON_HELP "Hilfe"
|
||||
TX_HELP "Hilfe Nummer"
|
||||
TX_BUTTON_PRIVE "Konstruktion"
|
||||
TX_PRIVATE "Konstruktion Nummer"
|
||||
TX_IONAMEPR "Konstruktion %d, Zeit %d"
|
||||
TX_PRIVATE_HACHBLUPI "1|Auf die gestreiften Quadrate gehen."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_FABDISC "Roboter bauen"
|
||||
TX_ACTION_REPEAT "Wiederholen"
|
||||
TX_ACTION_QARMURE "Aussteigen"
|
||||
TX_ACTION_FABARMURE "Rüstung bauen"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_HACHPLANCHE "1|Bretter auf die\n1|gestreiften Quadrate legen."
|
||||
TX_PRIVATE_HACHTOMATE "1|Tomaten auf die\n1|gestreiften Quadrate legen."
|
||||
TX_PRIVATE_HACHMETAL "1|Platinium auf die\n1|gestreiften Quadrate legen."
|
||||
TX_PRIVATE_STOPFIRE "1|Solange überleben bis\n1|das Feuer ausgegangen ist."
|
||||
TX_PRIVATE_HOMEBLUPI "1|Jeder Blupi\n1|in seinem Haus."
|
||||
TX_PRIVATE_KILLROBOTS "1|Alle Feinde\n1|zerstören !"
|
||||
TX_BUTTON_UNDO "Letzten Befehl rückgängig machen"
|
||||
TX_DEMO_END1 "Sie haben soeben mit der DEMO Version von Planet Blupi gespielt."
|
||||
TX_DEMO_END2 "Hoffentlich hatten Sie genau soviel Spass beim Spielen wie wir beim herstellen des Spiels !"
|
||||
TX_DEMO_END3 "Dieses Spiel wurde entwickelt von Epsitec SA, CH-1092 Belmont"
|
||||
TX_DEMO_END4 "http://www.blupi.com blupi@epsitec.ch"
|
||||
TX_FULL_END1 "Sie haben soeben mit PLANET BLUPI gespielt."
|
||||
TX_FULL_END2 "Hoffentlich hatten Sie genau soviel Spass beim Spielen wie wir beim herstellen des Spiels !"
|
||||
TX_FULL_END3 "Herausgegeben von WG Verlag & Lizenzen AG"
|
||||
TX_FULL_END4 "Entwickelt von EPSITEC SA"
|
||||
TX_PRIVATE_OBJECTIF "1|Ziel :"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_NBBLUPI "1|Die Blupibevölkerung muss mindestens %d Blupi(s) betragen."
|
||||
TX_BUTTON_SKILL "Schwierigkeitsgrad"
|
||||
TX_SKILL1 "Leicht"
|
||||
TX_SKILL2 "Schwer"
|
||||
TX_BUTTON_DEMO "Demo"
|
||||
TX_DEMOREC "REC"
|
||||
TX_DEMOPLAY "Demo"
|
||||
TX_BUTTON_TERMHROBOT "Roboter auf gestreiften Quadraten"
|
||||
TX_PRIVATE_HACHROBOT "1|Der Roboter muss die\n1|gestreiften Quadrate erreichen."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_REPEAT_CULTIVE "1: Tomaten anbauen...\n2: Essen"
|
||||
TX_REPEAT_FLEUR "1: Blumenstrauss binden\n2: Verarbeiten"
|
||||
TX_REPEAT_FLEURQ "1: Nehmen\n2: Verarbeiten"
|
||||
TX_REPEAT_FABMINE "1: Eisen abbauen\n2: Zeitbombe bauen"
|
||||
TX_REPEAT_FABJEEP "1: Eisen abbauen\n2: Jeep bauen"
|
||||
TX_REPEAT_PALIS "1: Baum fällen\n2: Palissade bauen"
|
||||
TX_REPEAT_PALISQ "1: Nehmen\n2: Palissade bauen"
|
||||
TX_REPEAT_PONT "1: Baum fällen\n2: Brücke bauen"
|
||||
TX_REPEAT_PONTQ "1: Nehmen\n2: Brücke bauen"
|
||||
TX_REPEAT_BATEAU "1: Baum fällen\n2: Boot bauen"
|
||||
TX_REPEAT_BATEAUQ "1: Bretter nehmen\n2: Boot bauen"
|
||||
TX_REPEAT_FABARMURE "1: Eisen abbauen\n2: Rüstung bauen"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_MURPAL "Mauer oder Palissade"
|
||||
TX_OBJ_OBJET "Gegenstände"
|
||||
TX_OBJ_ARME "Waffen"
|
||||
TX_OBJ_VEHICULE "Transportmittel"
|
||||
TX_OBJ_STARTFEU "Feuer"
|
||||
TX_OBJ_DELOBJ "Gegenstand löschen"
|
||||
TX_OBJ_DELPERSO "Figur löschen"
|
||||
TX_OBJ_DELFEU "Feuer löschen"
|
||||
TX_OBJ_PLANTE "Pflanzen"
|
||||
TX_OBJ_BARENNEMIS "Feindlicher Zaun"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_DIRECT_N "N"
|
||||
TX_DIRECT_S "S"
|
||||
TX_DIRECT_E "O"
|
||||
TX_DIRECT_O "W"
|
||||
END
|
||||
|
||||
#endif // French (Switzerland) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
BIN
resource/blupi-e.aps
Normal file
489
resource/blupi-e.rc
Normal file
@ -0,0 +1,489 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// French (Switzerland) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRS)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_FRENCH, SUBLANG_FRENCH_SWISS
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Icon
|
||||
//
|
||||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
IDR_MAINFRAME ICON DISCARDABLE "blupi.ico"
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 0,4,0,0
|
||||
PRODUCTVERSION 0,4,0,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x40004L
|
||||
FILETYPE 0x1L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "100c04b0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "EPSITEC\0"
|
||||
VALUE "FileDescription", "Blupi\0"
|
||||
VALUE "FileVersion", "0, 4, 0, 0\0"
|
||||
VALUE "InternalName", "Planet Blupi\0"
|
||||
VALUE "LegalCopyright", "Copyright © 1997\0"
|
||||
VALUE "OriginalFilename", "Blupi.exe\0"
|
||||
VALUE "ProductName", "EPSITEC Planet Blupi\0"
|
||||
VALUE "ProductVersion", "0, 4, 0, 0\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x100c, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Cursor
|
||||
//
|
||||
|
||||
IDC_POINTER CURSOR DISCARDABLE "cursor1.cur"
|
||||
IDC_MAP CURSOR DISCARDABLE "map.cur"
|
||||
IDC_ARROWU CURSOR DISCARDABLE "arrowup.cur"
|
||||
IDC_ARROWD CURSOR DISCARDABLE "arrowdow.cur"
|
||||
IDC_ARROWL CURSOR DISCARDABLE "arrowlef.cur"
|
||||
IDC_ARROWR CURSOR DISCARDABLE "arrowrig.cur"
|
||||
IDC_ARROWUL CURSOR DISCARDABLE "arrowul.cur"
|
||||
IDC_ARROWUR CURSOR DISCARDABLE "arrowur.cur"
|
||||
IDC_ARROWDR CURSOR DISCARDABLE "arrowdr.cur"
|
||||
IDC_ARROWDL CURSOR DISCARDABLE "arrowdl.cur"
|
||||
IDC_WAIT CURSOR DISCARDABLE "wait.cur"
|
||||
IDC_EMPTY CURSOR DISCARDABLE "empty.cur"
|
||||
IDC_FILL CURSOR DISCARDABLE "fill.cur"
|
||||
IDC_ARROW CURSOR DISCARDABLE "arrow.cur"
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// String Table
|
||||
//
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_GO "Go"
|
||||
TX_ACTION_STOP "Stop"
|
||||
TX_ACTION_MANGE "Eat"
|
||||
TX_ACTION_CARRY "Take"
|
||||
TX_ACTION_DEPOSE "Drop"
|
||||
TX_ACTION_ABAT "Cut down a tree"
|
||||
TX_ACTION_ROC "Carve a rock"
|
||||
TX_ACTION_CULTIVE "Grow tomatoes"
|
||||
TX_ACTION_BUILD1 "Garden shed"
|
||||
TX_ACTION_BUILD2 "Incubator"
|
||||
TX_ACTION_BUILD3 "Laboratory"
|
||||
TX_ACTION_BUILD4 "Mine"
|
||||
TX_ACTION_BUILD5 "Workshop"
|
||||
TX_ACTION_BUILD6 "Teleporter"
|
||||
TX_ACTION_MUR "Wall"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_PALIS "Palisade"
|
||||
TX_ACTION_ABATn "Cut down trees"
|
||||
TX_ACTION_ROCn "Carve rocks"
|
||||
TX_ACTION_PONT "Bridge"
|
||||
TX_ACTION_TOUR "Protection tower"
|
||||
TX_ACTION_BOIT "Drink"
|
||||
TX_ACTION_LABO "Transform"
|
||||
TX_ACTION_FLEUR "Make bunch of flowers"
|
||||
TX_ACTION_FLEURn "Make bunches of flowers"
|
||||
TX_ACTION_DYNAMITE "Blow up"
|
||||
TX_ACTION_BATEAU "Boat"
|
||||
TX_ACTION_DJEEP "Leave Jeep"
|
||||
TX_ACTION_DRAPEAU "Prospect for iron"
|
||||
TX_ACTION_EXTRAIT "Extract iron"
|
||||
TX_ACTION_FABJEEP "Make a Jeep"
|
||||
TX_ACTION_FABMINE "Make a time bomb"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ERROR_MISC "Impossible"
|
||||
TX_ERROR_GROUND "Inadequate ground"
|
||||
TX_ERROR_FREE "Occupied ground"
|
||||
TX_ERROR_PONTOP "Opposite bank no good"
|
||||
TX_ERROR_PONTTERM "Bridge finished"
|
||||
TX_ERROR_TOURISOL "(isolated tower)"
|
||||
TX_ERROR_TOUREAU "Too close to water"
|
||||
TX_ERROR_TELE2 "Already two teleporters"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_IONAMEEX "training %d, time %d"
|
||||
TX_IOFREE "free slot"
|
||||
TX_TERMMIN "Lost if less than %d Blupis"
|
||||
TX_TERMMAX "Impossible to win if less than %d Blupis"
|
||||
TX_BUTTON_JOUER "Missions"
|
||||
TX_BUTTON_APPRENDRE "Training"
|
||||
TX_BUTTON_QUITTER "Quit BLUPI"
|
||||
TX_BUTTON_PREVP "Previous game"
|
||||
TX_BUTTON_NEXTP "Next game"
|
||||
TX_BUTTON_PLAYP "Play this game"
|
||||
TX_BUTTON_BUILDP "Construct this game"
|
||||
TX_BUTTON_TERM "Finish"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_READP "Open another game "
|
||||
TX_BUTTON_WRITEP "Save this game"
|
||||
TX_BUTTON_CANCELP "Quit this game"
|
||||
TX_BUTTON_CONTP "Continue this game"
|
||||
TX_BUTTON_REPEAT "Restart this game"
|
||||
TX_BUTTON_BUTTON "Available buttons"
|
||||
TX_BUTTON_CTERM "Ending conditions"
|
||||
TX_BUTTON_TERMC "Quit construction"
|
||||
TX_BUTTON_TERMHBLUPI "Blupi on striped paving stones"
|
||||
TX_BUTTON_TERMHPLANCHE "Planks on striped paving stones"
|
||||
TX_BUTTON_TERMFIRE "Fire out"
|
||||
TX_BUTTON_TERMDEC "(-)"
|
||||
TX_BUTTON_TERMINC "(+)"
|
||||
TX_PAUSE "Game paused"
|
||||
TX_JAUGE1 "Blupi's energy"
|
||||
TX_JAUGE2 "Work done"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP "Settings"
|
||||
TX_BUTTON_MUSIC "Music choice"
|
||||
TX_BUTTON_SETUP1 "Slower"
|
||||
TX_BUTTON_SETUP2 "Faster"
|
||||
TX_BUTTON_SETUP3 "Reduce volume"
|
||||
TX_BUTTON_SETUP4 "Increase volume"
|
||||
TX_BUTTON_MUSIC1 "No music"
|
||||
TX_BUTTON_MUSIC2 "Music number 1"
|
||||
TX_BUTTON_MUSIC3 "Music number 2"
|
||||
TX_BUTTON_MUSIC4 "Music number 3"
|
||||
TX_BUTTON_MUSIC5 "Music number 4"
|
||||
TX_BUTTON_MUSIC6 "Music number 5"
|
||||
TX_BUTTON_MUSIC7 "Music number 6"
|
||||
TX_BUTTON_MUSIC8 "Music number 7"
|
||||
TX_BUTTON_MUSIC9 "Music number 8"
|
||||
TX_BUTTON_MUSIC10 "Music number 9"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION "Scenery choice"
|
||||
TX_BUTTON_TERMMBLUPI "Blupi in house"
|
||||
TX_BUTTON_TERMKILL "No more enemies"
|
||||
TX_TERM "Ending conditions"
|
||||
TX_BUTTON "Available buttons"
|
||||
TX_MUSIC "Music choice"
|
||||
TX_SCHOOL "Training number"
|
||||
TX_MISSION "Mission number"
|
||||
TX_IONAMEMI "mission %d, time %d"
|
||||
TX_BUTTON_TERMHTOMATE "Tomatoes on striped paving stones"
|
||||
TX_BUTTON_SETUP5 "Reduce volume"
|
||||
TX_BUTTON_SETUP6 "Increase volume"
|
||||
TX_BUTTON_SETUP7 "No video"
|
||||
TX_BUTTON_SETUP8 "Show videos"
|
||||
TX_OUI "Yes"
|
||||
TX_NON "No"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_BLUPIm "Sick Blupi"
|
||||
TX_OBJ_BLUPIf "Tired Blupi"
|
||||
TX_OBJ_BLUPI "Blupi"
|
||||
TX_OBJ_BATEAU "Boat"
|
||||
TX_OBJ_JEEP "Jeep"
|
||||
TX_OBJ_PIEGE "Sticky trap"
|
||||
TX_OBJ_POISON "Poison"
|
||||
TX_OBJ_DYNAMITE "Dynamite"
|
||||
TX_OBJ_MINE "Time bomb"
|
||||
TX_OBJ_TOMATE "Tomatoes"
|
||||
TX_OBJ_POTION "Medical potion"
|
||||
TX_OBJ_PLANCHE "Planks"
|
||||
TX_OBJ_PIERRE "Stones"
|
||||
TX_OBJ_DRAPEAU "Flag"
|
||||
TX_OBJ_FER "Iron"
|
||||
TX_OBJ_FLEUR1 "Flowers"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_FLEUR2 "Flowers"
|
||||
TX_OBJ_FLEUR3 "Flowers"
|
||||
TX_OBJ_CABANE "Garden shed"
|
||||
TX_OBJ_LABO "Laboratory"
|
||||
TX_OBJ_MINEFER "Mine"
|
||||
TX_OBJ_USINE "Workshop"
|
||||
TX_OBJ_TOUR "Protection tower"
|
||||
TX_OBJ_FEU "Fire"
|
||||
TX_OBJ_ROBOT "Master robot"
|
||||
TX_OBJ_TRACKS "Bulldozer"
|
||||
TX_OBJ_BOMBE "Bouncing bomb"
|
||||
TX_OBJ_ARAIGNEE "Spider"
|
||||
TX_OBJ_VIRUS "Virus"
|
||||
TX_OBJ_ELECTRO "Electrocutor"
|
||||
TX_OBJ_ARBRE "Tree"
|
||||
TX_OBJ_MUR "Wall"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_ARBREb "Tree trunks"
|
||||
TX_OBJ_ROC "Rocks"
|
||||
TX_OBJ_OEUF "Eggs"
|
||||
TX_OBJ_PALISSADE "Palisade"
|
||||
TX_OBJ_ENNEMIp "Trapped enemy"
|
||||
TX_OBJ_ENNEMI "Enemy construction"
|
||||
TX_OBJ_HERBE "Normal ground"
|
||||
TX_OBJ_MOUSSE "Inflammable ground"
|
||||
TX_OBJ_TERRE "Sterile ground"
|
||||
TX_OBJ_EAU "Water"
|
||||
TX_OBJ_RIVE "Bank"
|
||||
TX_OBJ_MIXTE "Miscellaneous ground"
|
||||
TX_OBJ_PONT "Bridge"
|
||||
TX_OBJ_COUVEUSE "Incubator"
|
||||
TX_OBJ_GLACE "Ice"
|
||||
TX_OBJ_MAISON "Blupi's house"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_HACHURE "Striped paving stones"
|
||||
TX_OBJ_MOUSSEb "Burnt ground"
|
||||
TX_OBJ_BOUQUET1 "Bunch of flowers"
|
||||
TX_OBJ_BOUQUET2 "Bunch of flowers"
|
||||
TX_OBJ_BOUQUET3 "Bunch of flowers"
|
||||
TX_OBJ_DALLE "Paving stones"
|
||||
TX_OBJ_ENNEMIs "Enemy ground "
|
||||
TX_OBJ_DISCIPLE "Helper robot"
|
||||
TX_OBJ_METAL "Platinium"
|
||||
TX_OBJ_FUSEE "Enemy rocket"
|
||||
TX_OBJ_TELEPORTE "Teleporter"
|
||||
TX_OBJ_ARMURE "Armour"
|
||||
TX_OBJ_DALLESPEC "Special pavings"
|
||||
TX_OBJ_COUVTELE "Incubator or teleporter"
|
||||
TX_OBJ_BATIMENT "Buildings"
|
||||
TX_OBJ_BATENNEMIS "Enemy buildings"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_WIN1 "Well done !"
|
||||
TX_WIN2 "Yes, great ..."
|
||||
TX_WIN3 "Very good."
|
||||
TX_WIN4 "Excellent..."
|
||||
TX_WIN5 "Mission over..."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST1 "You have failed, try again..."
|
||||
TX_LOST2 "No, wrong way ..."
|
||||
TX_LOST3 "Bang, failed again !"
|
||||
TX_LOST4 "Another mistake..."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST5 "No, not that way !"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LASTWIN1 "Now go on mission."
|
||||
TX_LASTWIN2 "Very good, success on all missions !"
|
||||
TX_LASTWIN3 "Last construction resolved !"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP9 "Slower"
|
||||
TX_BUTTON_SETUP10 "Faster"
|
||||
TX_INFO_SETUP1 "Global game\nspeed"
|
||||
TX_INFO_SETUP2 "Sound effect\nvolume"
|
||||
TX_INFO_SETUP3 "Music\nvolume"
|
||||
TX_INFO_SETUP4 "Video\nsequences"
|
||||
TX_INFO_SETUP5 "Scroll speed\nwith mouse"
|
||||
TX_INFO_NOSCROLL "None"
|
||||
TX_BUTTON_REGION1 "Prairie"
|
||||
TX_BUTTON_REGION2 "Desert"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION3 "Forest under snow"
|
||||
TX_BUTTON_REGION4 "Forest"
|
||||
TX_REGION "Scenery choice"
|
||||
TX_BUTTON_PLAY_STOP "Interrupt"
|
||||
TX_BUTTON_PLAY_SETUP "Settings"
|
||||
TX_BUTTON_PLAY_WRITE "Save"
|
||||
TX_INSERT "Insert CD-Rom Planet Blupi and wait a few seconds..."
|
||||
TX_BUTTON_PREVH "Previous page"
|
||||
TX_BUTTON_NEXTH "Next page"
|
||||
TX_BUTTON_TERMHMETAL "Platinium on striped paving stones"
|
||||
TX_BUTTON_HELP "Help"
|
||||
TX_HELP "Help number"
|
||||
TX_BUTTON_PRIVE "Construction"
|
||||
TX_PRIVATE "Construction number"
|
||||
TX_IONAMEPR "Construction %d, time %d"
|
||||
TX_PRIVATE_HACHBLUPI "1|Go on striped\n1| paving stones."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_FABDISC "Make a helper robot"
|
||||
TX_ACTION_REPEAT "Repeat"
|
||||
TX_ACTION_QARMURE "Quit"
|
||||
TX_ACTION_FABARMURE "Make armour"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_HACHPLANCHE "1|Drop planks on striped \n1|paving stones."
|
||||
TX_PRIVATE_HACHTOMATE "1|Drop tomatoes on striped \n1|paving stones."
|
||||
TX_PRIVATE_HACHMETAL "1|Drop platinium on striped \n1|paving stones."
|
||||
TX_PRIVATE_STOPFIRE "1|Resist until\n1|fire extinction ..."
|
||||
TX_PRIVATE_HOMEBLUPI "1|Each Blupi in\n1|his house."
|
||||
TX_PRIVATE_KILLROBOTS "1|Kill all\n1|enemies !"
|
||||
TX_BUTTON_UNDO "Cancel last operation"
|
||||
TX_DEMO_END1 "You have played the DEMO version of Planet Blupi."
|
||||
TX_DEMO_END2 "We hope you have had as much fun playing the game as we had making it !"
|
||||
TX_DEMO_END3 "This game is an original creation of EPSITEC SA, CH-1092 Belmont"
|
||||
TX_DEMO_END4 "http://www.blupi.com blupi@epsitec.ch"
|
||||
TX_FULL_END1 "You have played Planet Blupi."
|
||||
TX_FULL_END2 "We hope you have had as much fun playing the game as we had making it !"
|
||||
TX_FULL_END3 "This game is an original creation of EPSITEC SA, CH-1092 Belmont"
|
||||
TX_FULL_END4 "http://www.blupi.com blupi@epsitec.ch"
|
||||
TX_PRIVATE_OBJECTIF "1|Goal :"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_NBBLUPI "1|The Blupi population must \n1|be of at least %d Blupis."
|
||||
TX_BUTTON_SKILL "Skill level"
|
||||
TX_SKILL1 "Easy"
|
||||
TX_SKILL2 "Difficult"
|
||||
TX_BUTTON_DEMO "Demo"
|
||||
TX_DEMOREC "REC"
|
||||
TX_DEMOPLAY "Demo"
|
||||
TX_BUTTON_TERMHROBOT "Robot on striped paving stones"
|
||||
TX_PRIVATE_HACHROBOT "1|The robot must reach\n1|the striped paving stones."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_REPEAT_CULTIVE "1: Grow tomatoes\n2: Eat"
|
||||
TX_REPEAT_FLEUR "1: Make a bunch\n2: Transform"
|
||||
TX_REPEAT_FLEURQ "1: Take\n2: Transform"
|
||||
TX_REPEAT_FABMINE "1: Extract iron\n2: Make a bomb"
|
||||
TX_REPEAT_FABJEEP "1: Extract iron\n2: Make a Jeep"
|
||||
TX_REPEAT_PALIS "1: Cut down a tree \n2: Make a palisade"
|
||||
TX_REPEAT_PALISQ "1: Take\n2: Build palisade"
|
||||
TX_REPEAT_PONT "1: Cut down a tree \n2: Build a bridge"
|
||||
TX_REPEAT_PONTQ "1: Take\n2: Build a bridge"
|
||||
TX_REPEAT_BATEAU "1: Cut down a tree \n2: Make a boat"
|
||||
TX_REPEAT_BATEAUQ "1: Take\n2: Make a boat"
|
||||
TX_REPEAT_FABARMURE "1: Extract iron\n2: Make an armour"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_MURPAL "Wall or palisade"
|
||||
TX_OBJ_OBJET "Items"
|
||||
TX_OBJ_ARME "Weapons"
|
||||
TX_OBJ_VEHICULE "Transport"
|
||||
TX_OBJ_STARTFEU "Starting fire"
|
||||
TX_OBJ_DELOBJ "Delete item"
|
||||
TX_OBJ_DELPERSO "Delete figure"
|
||||
TX_OBJ_DELFEU "Delete fire"
|
||||
TX_OBJ_PLANTE "Decorative plants"
|
||||
TX_OBJ_BARENNEMIS "Enemy barrier"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_DIRECT_N "N"
|
||||
TX_DIRECT_S "S"
|
||||
TX_DIRECT_E "E"
|
||||
TX_DIRECT_O "W"
|
||||
END
|
||||
|
||||
#endif // French (Switzerland) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
BIN
resource/blupi-f.aps
Normal file
489
resource/blupi-f.rc
Normal file
@ -0,0 +1,489 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// French (Switzerland) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRS)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_FRENCH, SUBLANG_FRENCH_SWISS
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Icon
|
||||
//
|
||||
|
||||
// Icon with lowest ID value placed first to ensure application icon
|
||||
// remains consistent on all systems.
|
||||
IDR_MAINFRAME ICON DISCARDABLE "blupi.ico"
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 0,4,0,0
|
||||
PRODUCTVERSION 0,4,0,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x40004L
|
||||
FILETYPE 0x1L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "100c04b0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "EPSITEC\0"
|
||||
VALUE "FileDescription", "Blupi\0"
|
||||
VALUE "FileVersion", "0, 4, 0, 0\0"
|
||||
VALUE "InternalName", "Planet Blupi\0"
|
||||
VALUE "LegalCopyright", "Copyright © 1997\0"
|
||||
VALUE "OriginalFilename", "Blupi.exe\0"
|
||||
VALUE "ProductName", "EPSITEC Planet Blupi\0"
|
||||
VALUE "ProductVersion", "0, 4, 0, 0\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x100c, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Cursor
|
||||
//
|
||||
|
||||
IDC_POINTER CURSOR DISCARDABLE "cursor1.cur"
|
||||
IDC_MAP CURSOR DISCARDABLE "map.cur"
|
||||
IDC_ARROWU CURSOR DISCARDABLE "arrowup.cur"
|
||||
IDC_ARROWD CURSOR DISCARDABLE "arrowdow.cur"
|
||||
IDC_ARROWL CURSOR DISCARDABLE "arrowlef.cur"
|
||||
IDC_ARROWR CURSOR DISCARDABLE "arrowrig.cur"
|
||||
IDC_ARROWUL CURSOR DISCARDABLE "arrowul.cur"
|
||||
IDC_ARROWUR CURSOR DISCARDABLE "arrowur.cur"
|
||||
IDC_ARROWDR CURSOR DISCARDABLE "arrowdr.cur"
|
||||
IDC_ARROWDL CURSOR DISCARDABLE "arrowdl.cur"
|
||||
IDC_WAIT CURSOR DISCARDABLE "wait.cur"
|
||||
IDC_EMPTY CURSOR DISCARDABLE "empty.cur"
|
||||
IDC_FILL CURSOR DISCARDABLE "fill.cur"
|
||||
IDC_ARROW CURSOR DISCARDABLE "arrow.cur"
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// String Table
|
||||
//
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_GO "Va"
|
||||
TX_ACTION_STOP "Stoppe"
|
||||
TX_ACTION_MANGE "Mange"
|
||||
TX_ACTION_CARRY "Prend"
|
||||
TX_ACTION_DEPOSE "Dépose"
|
||||
TX_ACTION_ABAT "Abat un arbre"
|
||||
TX_ACTION_ROC "Taille un rocher"
|
||||
TX_ACTION_CULTIVE "Cultive un jardin"
|
||||
TX_ACTION_BUILD1 "Cabane de jardin"
|
||||
TX_ACTION_BUILD2 "Couveuse"
|
||||
TX_ACTION_BUILD3 "Laboratoire"
|
||||
TX_ACTION_BUILD4 "Mine de fer"
|
||||
TX_ACTION_BUILD5 "Usine"
|
||||
TX_ACTION_BUILD6 "Téléporteur"
|
||||
TX_ACTION_MUR "Mur anti-feu"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_PALIS "Palissade"
|
||||
TX_ACTION_ABATn "Abat des arbres"
|
||||
TX_ACTION_ROCn "Taille des rochers"
|
||||
TX_ACTION_PONT "Pont"
|
||||
TX_ACTION_TOUR "Tour de protection"
|
||||
TX_ACTION_BOIT "Boit"
|
||||
TX_ACTION_LABO "Transforme"
|
||||
TX_ACTION_FLEUR "Fait un bouquet"
|
||||
TX_ACTION_FLEURn "Fait des bouquets"
|
||||
TX_ACTION_DYNAMITE "Explose"
|
||||
TX_ACTION_BATEAU "Bateau"
|
||||
TX_ACTION_DJEEP "Descend"
|
||||
TX_ACTION_DRAPEAU "Cherche du fer"
|
||||
TX_ACTION_EXTRAIT "Extrait du fer"
|
||||
TX_ACTION_FABJEEP "Farbique une jeep"
|
||||
TX_ACTION_FABMINE "Fabrique une bombe"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ERROR_MISC "Impossible ici"
|
||||
TX_ERROR_GROUND "Terrain pas adapté"
|
||||
TX_ERROR_FREE "Terrain occupé"
|
||||
TX_ERROR_PONTOP "Autre rive pas ok"
|
||||
TX_ERROR_PONTTERM "Pont terminé"
|
||||
TX_ERROR_TOURISOL "(tour isolée)"
|
||||
TX_ERROR_TOUREAU "Trop près de l'eau"
|
||||
TX_ERROR_TELE2 "Déjà 2 téléporteurs"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_IONAMEEX "entraînement %d, temps %d"
|
||||
TX_IOFREE "libre"
|
||||
TX_TERMMIN "Perdu si moins de %d blupi"
|
||||
TX_TERMMAX "Impossible de gagner si moins de %d blupi"
|
||||
TX_BUTTON_JOUER "Missions"
|
||||
TX_BUTTON_APPRENDRE "Entraînement"
|
||||
TX_BUTTON_QUITTER "Quitter BLUPI"
|
||||
TX_BUTTON_PREVP "Partie précédente"
|
||||
TX_BUTTON_NEXTP "Partie suivante"
|
||||
TX_BUTTON_PLAYP "Jouer cette partie"
|
||||
TX_BUTTON_BUILDP "Construire cette partie"
|
||||
TX_BUTTON_TERM "Terminer"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_READP "Ouvrir une autre partie"
|
||||
TX_BUTTON_WRITEP "Enregistrer la partie en cours"
|
||||
TX_BUTTON_CANCELP "Abandonner la partie"
|
||||
TX_BUTTON_CONTP "Continuer la partie"
|
||||
TX_BUTTON_REPEAT "Recommencer"
|
||||
TX_BUTTON_BUTTON "Boutons disponibles"
|
||||
TX_BUTTON_CTERM "Conditions de fin"
|
||||
TX_BUTTON_TERMC "Terminer la construction"
|
||||
TX_BUTTON_TERMHBLUPI "Blupi sur dalles hachurées"
|
||||
TX_BUTTON_TERMHPLANCHE "Planches sur dalles hachurées"
|
||||
TX_BUTTON_TERMFIRE "Feu stoppé"
|
||||
TX_BUTTON_TERMDEC "(-)"
|
||||
TX_BUTTON_TERMINC "(+)"
|
||||
TX_PAUSE "Partie interrompue"
|
||||
TX_JAUGE1 "Energie de Blupi"
|
||||
TX_JAUGE2 "Travail en cours"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP "Réglages"
|
||||
TX_BUTTON_MUSIC "Choix de la musique"
|
||||
TX_BUTTON_SETUP1 "Diminue la vitesse"
|
||||
TX_BUTTON_SETUP2 "Augmente la vitesse"
|
||||
TX_BUTTON_SETUP3 "Diminue le volume"
|
||||
TX_BUTTON_SETUP4 "Augmente le volume"
|
||||
TX_BUTTON_MUSIC1 "Pas de musique"
|
||||
TX_BUTTON_MUSIC2 "Musique numéro 1"
|
||||
TX_BUTTON_MUSIC3 "Musique numéro 2"
|
||||
TX_BUTTON_MUSIC4 "Musique numéro 3"
|
||||
TX_BUTTON_MUSIC5 "Musique numéro 4"
|
||||
TX_BUTTON_MUSIC6 "Musique numéro 5"
|
||||
TX_BUTTON_MUSIC7 "Musique numéro 6"
|
||||
TX_BUTTON_MUSIC8 "Musique numéro 7"
|
||||
TX_BUTTON_MUSIC9 "Musique numéro 8"
|
||||
TX_BUTTON_MUSIC10 "Musique numéro 9"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION "Choix des décors"
|
||||
TX_BUTTON_TERMMBLUPI "Blupi dans sa maison"
|
||||
TX_BUTTON_TERMKILL "Plus d'ennemis"
|
||||
TX_TERM "Conditions de fin"
|
||||
TX_BUTTON "Boutons disponibles"
|
||||
TX_MUSIC "Choix des musiques"
|
||||
TX_SCHOOL "Entraînement numéro"
|
||||
TX_MISSION "Mission numéro"
|
||||
TX_IONAMEMI "mission %d, temps %d"
|
||||
TX_BUTTON_TERMHTOMATE "Tomates sur dalles hachurées"
|
||||
TX_BUTTON_SETUP5 "Diminue le volume"
|
||||
TX_BUTTON_SETUP6 "Augmente le volume"
|
||||
TX_BUTTON_SETUP7 "Pas de vidéo"
|
||||
TX_BUTTON_SETUP8 "Montre les vidéos"
|
||||
TX_OUI "Oui"
|
||||
TX_NON "Non"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_BLUPIm "Blupi malade"
|
||||
TX_OBJ_BLUPIf "Blupi fatigué"
|
||||
TX_OBJ_BLUPI "Blupi"
|
||||
TX_OBJ_BATEAU "Bateau"
|
||||
TX_OBJ_JEEP "Jeep"
|
||||
TX_OBJ_PIEGE "Piège à glu"
|
||||
TX_OBJ_POISON "Poison"
|
||||
TX_OBJ_DYNAMITE "Dynamite"
|
||||
TX_OBJ_MINE "Bombe à retardement"
|
||||
TX_OBJ_TOMATE "Tomates"
|
||||
TX_OBJ_POTION "Potion"
|
||||
TX_OBJ_PLANCHE "Planches"
|
||||
TX_OBJ_PIERRE "Pierres"
|
||||
TX_OBJ_DRAPEAU "Drapeau"
|
||||
TX_OBJ_FER "Minerai de fer"
|
||||
TX_OBJ_FLEUR1 "Fleurs"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_FLEUR2 "Fleurs"
|
||||
TX_OBJ_FLEUR3 "Fleurs"
|
||||
TX_OBJ_CABANE "Cabane de jardin"
|
||||
TX_OBJ_LABO "Laboratoire"
|
||||
TX_OBJ_MINEFER "Mine de fer"
|
||||
TX_OBJ_USINE "Usine"
|
||||
TX_OBJ_TOUR "Tour de protection"
|
||||
TX_OBJ_FEU "Feu"
|
||||
TX_OBJ_ROBOT "Robot-maître"
|
||||
TX_OBJ_TRACKS "Bulldozer"
|
||||
TX_OBJ_BOMBE "Bombe sauteuse"
|
||||
TX_OBJ_ARAIGNEE "Araignée"
|
||||
TX_OBJ_VIRUS "Virus"
|
||||
TX_OBJ_ELECTRO "Electrocuteur"
|
||||
TX_OBJ_ARBRE "Arbres"
|
||||
TX_OBJ_MUR "Mur anti-feu"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_ARBREb "Troncs"
|
||||
TX_OBJ_ROC "Rochers"
|
||||
TX_OBJ_OEUF "Oeufs"
|
||||
TX_OBJ_PALISSADE "Palissade"
|
||||
TX_OBJ_ENNEMIp "Ennemi piégé"
|
||||
TX_OBJ_ENNEMI "Construction ennemie"
|
||||
TX_OBJ_HERBE "Sol normal"
|
||||
TX_OBJ_MOUSSE "Sol inflammable"
|
||||
TX_OBJ_TERRE "Sol improductif"
|
||||
TX_OBJ_EAU "Eau"
|
||||
TX_OBJ_RIVE "Rive"
|
||||
TX_OBJ_MIXTE "Sol mixte"
|
||||
TX_OBJ_PONT "Pont"
|
||||
TX_OBJ_COUVEUSE "Couveuse"
|
||||
TX_OBJ_GLACE "Glace"
|
||||
TX_OBJ_MAISON "Maison de blupi"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_HACHURE "Dalles hachurées"
|
||||
TX_OBJ_MOUSSEb "Mousse brûlée"
|
||||
TX_OBJ_BOUQUET1 "Bouquet de fleurs"
|
||||
TX_OBJ_BOUQUET2 "Bouquet de fleurs"
|
||||
TX_OBJ_BOUQUET3 "Bouquet de fleurs"
|
||||
TX_OBJ_DALLE "Dalles"
|
||||
TX_OBJ_ENNEMIs "Sol ennemi"
|
||||
TX_OBJ_DISCIPLE "Robot-aide"
|
||||
TX_OBJ_METAL "Platinium"
|
||||
TX_OBJ_FUSEE "Fusée ennemie"
|
||||
TX_OBJ_TELEPORTE "Téléporteur"
|
||||
TX_OBJ_ARMURE "Armure"
|
||||
TX_OBJ_DALLESPEC "Dalles spéciales"
|
||||
TX_OBJ_COUVTELE "Couveuse ou téléporteur"
|
||||
TX_OBJ_BATIMENT "Bâtiments"
|
||||
TX_OBJ_BATENNEMIS "Bâtiments ennemis"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_WIN1 "Bravo, c'est réussi !"
|
||||
TX_WIN2 "Oui, super ..."
|
||||
TX_WIN3 "Très bien."
|
||||
TX_WIN4 "Magnifique, excellent ..."
|
||||
TX_WIN5 "Mission accomplie."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST1 "C'est raté, essaie encore une fois"
|
||||
TX_LOST2 "Et non, ce n'est pas ça ..."
|
||||
TX_LOST3 "Paf, c'est raté !"
|
||||
TX_LOST4 "Caramba, encore raté ..."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LOST5 "Mais non, pas comme ça !"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_LASTWIN1 "Passe maintenant aux missions."
|
||||
TX_LASTWIN2 "Magnifique, le jeu est terminé !"
|
||||
TX_LASTWIN3 "Dernière construction résolue !"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_SETUP9 "Diminue la vitesse"
|
||||
TX_BUTTON_SETUP10 "Augmente la vitesse"
|
||||
TX_INFO_SETUP1 "Vitesse globale\ndu jeu"
|
||||
TX_INFO_SETUP2 "Volume\ndes bruitages"
|
||||
TX_INFO_SETUP3 "Volume\ndes musiques"
|
||||
TX_INFO_SETUP4 "Séquences\nvidéo"
|
||||
TX_INFO_SETUP5 "Vitesse\ndes décalages\navec la souris"
|
||||
TX_INFO_NOSCROLL "Aucun"
|
||||
TX_BUTTON_REGION1 "Prairie"
|
||||
TX_BUTTON_REGION2 "Désert"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_BUTTON_REGION3 "Forêt enneigée"
|
||||
TX_BUTTON_REGION4 "Forêt"
|
||||
TX_REGION "Choix de la région"
|
||||
TX_BUTTON_PLAY_STOP "Interrompre"
|
||||
TX_BUTTON_PLAY_SETUP "Réglages"
|
||||
TX_BUTTON_PLAY_WRITE "Enregistrer"
|
||||
TX_INSERT "Veuillez insérer le CD-Rom Planète Blupi, puis attendre quelques secondes ..."
|
||||
TX_BUTTON_PREVH "Page précédente"
|
||||
TX_BUTTON_NEXTH "Page suivante"
|
||||
TX_BUTTON_TERMHMETAL "Platinium sur dalles hachurées"
|
||||
TX_BUTTON_HELP "Aide"
|
||||
TX_HELP "Aide numéro"
|
||||
TX_BUTTON_PRIVE "Construction"
|
||||
TX_PRIVATE "Construction numéro"
|
||||
TX_IONAMEPR "construction %d, temps %d"
|
||||
TX_PRIVATE_HACHBLUPI "1|Aller sur les dalles\n1|hachurées."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_ACTION_FABDISC "Fabrique un robot"
|
||||
TX_ACTION_REPEAT "Répète"
|
||||
TX_ACTION_QARMURE "Quitte"
|
||||
TX_ACTION_FABARMURE "Fabrique une armure"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_HACHPLANCHE "1|Déposer des planches\n1|sur les dalles hachurées."
|
||||
TX_PRIVATE_HACHTOMATE "1|Déposer des tomates\n1|sur les dalles hachurées."
|
||||
TX_PRIVATE_HACHMETAL "1|Déposer du platinium\n1|sur les dalles hachurées."
|
||||
TX_PRIVATE_STOPFIRE "1|Résister jusqu'à\n1|l'extinction du feu ..."
|
||||
TX_PRIVATE_HOMEBLUPI "1|Chaque Blupi dans\n1|sa maison."
|
||||
TX_PRIVATE_KILLROBOTS "1|Supprimer tous les\n1|ennemis !"
|
||||
TX_BUTTON_UNDO "Annuler la dernière opération"
|
||||
TX_DEMO_END1 "Vous avez joué à la version DEMO de Planète Blupi."
|
||||
TX_DEMO_END2 "Nous espérons que vous avez eu autant de plaisir à y jouer que nous à le réaliser !"
|
||||
TX_DEMO_END3 "Ce jeu est une création originale d'EPSITEC SA, CH-1092 Belmont"
|
||||
TX_DEMO_END4 "http://www.blupi.com blupi@epsitec.ch"
|
||||
TX_FULL_END1 "Vous avez joué à Planète Blupi."
|
||||
TX_FULL_END2 "Nous espérons que vous avez eu autant de plaisir à y jouer que nous à le réaliser !"
|
||||
TX_FULL_END3 "Ce jeu est une création originale d'EPSITEC SA, CH-1092 Belmont"
|
||||
TX_FULL_END4 "http://www.blupi.com blupi@epsitec.ch"
|
||||
TX_PRIVATE_OBJECTIF "1|Objectif :"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_PRIVATE_NBBLUPI "1|La population doit être\n1|d'au moins %d Blupi."
|
||||
TX_BUTTON_SKILL "Niveau de difficulté"
|
||||
TX_SKILL1 "Facile"
|
||||
TX_SKILL2 "Difficile"
|
||||
TX_BUTTON_DEMO "Démo"
|
||||
TX_DEMOREC "REC"
|
||||
TX_DEMOPLAY "Démo"
|
||||
TX_BUTTON_TERMHROBOT "Robot sur dalles hachurées"
|
||||
TX_PRIVATE_HACHROBOT "1|Le robot doit atteindre\n1|les dalles hachurées."
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_REPEAT_CULTIVE "1: Cultive ...\n2: Mange"
|
||||
TX_REPEAT_FLEUR "1: Fait un bouquet\n2: Transforme"
|
||||
TX_REPEAT_FLEURQ "1: Prend\n2: Transforme"
|
||||
TX_REPEAT_FABMINE "1: Extrait du fer\n2: Fabrique bombe"
|
||||
TX_REPEAT_FABJEEP "1: Extrait du fer\n2: Fabrique jeep"
|
||||
TX_REPEAT_PALIS "1: Abat un arbre\n2: Construit palissade"
|
||||
TX_REPEAT_PALISQ "1: Prend\n2: Construit palissade"
|
||||
TX_REPEAT_PONT "1: Abat un arbre\n2: Construit pont"
|
||||
TX_REPEAT_PONTQ "1: Prend\n2: Construit pont"
|
||||
TX_REPEAT_BATEAU "1: Abat un arbre\n2: Construit bateau"
|
||||
TX_REPEAT_BATEAUQ "1: Prend\n2: Construit bateau"
|
||||
TX_REPEAT_FABARMURE "1: Extrait du fer\n2: Fabrique armure"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_OBJ_MURPAL "Mur ou palissade"
|
||||
TX_OBJ_OBJET "Objets"
|
||||
TX_OBJ_ARME "Armes"
|
||||
TX_OBJ_VEHICULE "Moyens de transport"
|
||||
TX_OBJ_STARTFEU "Début d'incendie"
|
||||
TX_OBJ_DELOBJ "Supprime objet"
|
||||
TX_OBJ_DELPERSO "Supprime personnage"
|
||||
TX_OBJ_DELFEU "Supprime feu"
|
||||
TX_OBJ_PLANTE "Plantes ornementales"
|
||||
TX_OBJ_BARENNEMIS "Barrière ennemie"
|
||||
END
|
||||
|
||||
STRINGTABLE DISCARDABLE
|
||||
BEGIN
|
||||
TX_DIRECT_N "N"
|
||||
TX_DIRECT_S "S"
|
||||
TX_DIRECT_E "E"
|
||||
TX_DIRECT_O "O"
|
||||
END
|
||||
|
||||
#endif // French (Switzerland) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
BIN
resource/blupi.ico
Normal file
After Width: | Height: | Size: 766 B |
BIN
resource/blupi.rct
Normal file
BIN
resource/cursor1.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/empty.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/fill.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
resource/map.cur
Normal file
After Width: | Height: | Size: 326 B |
561
resource/resource.h
Normal file
@ -0,0 +1,561 @@
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Visual C++ generated include file.
|
||||
// Used by Eggbert2.rc
|
||||
//
|
||||
#define TX_IONAMEEX 100
|
||||
#define TX_IOFREE 101
|
||||
#define TX_OWNMISSION 102
|
||||
#define TX_TESTMISSION 103
|
||||
#define TX_BUTTON_JOUER 104
|
||||
#define TX_BUTTON_APPRENDRE 105
|
||||
#define TX_BUTTON_QUITTER 106
|
||||
#define TX_BUTTON_PREVP 107
|
||||
#define TX_BUTTON_NEXTP 108
|
||||
#define TX_BUTTON_PLAYP 109
|
||||
#define TX_BUTTON_BUILDP 110
|
||||
#define TX_BUTTON_TERM 111
|
||||
#define TX_BUTTON_READP 112
|
||||
#define TX_BUTTON_WRITEP 113
|
||||
#define TX_BUTTON_CANCELP 114
|
||||
#define TX_BUTTON_CONTP 115
|
||||
#define TX_BUTTON_REPEAT 116
|
||||
#define TX_CHOOSEPLAYER 117
|
||||
#define TX_PLAYERSNAME 118
|
||||
#define TX_BUTTON_TERMC 119
|
||||
#define TX_CHOOSESIZE 120
|
||||
#define TX_BUTTON_HVSCROLL 121
|
||||
#define TX_BUTTON_ONLYHSCROLL 122
|
||||
#define TX_BUTTON_ONLYVSCROLL 123
|
||||
#define TX_BUTTON_TESTMISSION 124
|
||||
#define TX_PAUSE 125
|
||||
#define TX_TINY 126
|
||||
#define TX_CLEARPLAYER 127
|
||||
#define TX_SETTINGS 128
|
||||
#define TX_CHOOSEMUSIC 129
|
||||
#define TX_BUTTON_SETUP1 130
|
||||
#define TX_BUTTON_SETUP2 131
|
||||
#define TX_BUTTON_SETUP3 132
|
||||
#define TX_BUTTON_SETUP4 133
|
||||
#define TX_NOMUSIC 134
|
||||
#define TX_MUSIC1 135
|
||||
#define TX_MUSIC2 136
|
||||
#define TX_MUSIC3 137
|
||||
#define TX_MUSIC4 138
|
||||
#define TX_MUSIC5 139
|
||||
#define TX_MUSIC6 140
|
||||
#define TX_MUSIC7 141
|
||||
#define TX_MUSIC8 142
|
||||
#define TX_MUSIC9 143
|
||||
#define TX_BUTTON_REGION 144
|
||||
#define TX_CHOOSEBACK 144
|
||||
#define TX_DISCARDGAME 145
|
||||
#define TX_CONFIRMCLEARGAME 145
|
||||
#define TX_EGGBERT 146
|
||||
#define TX_BLUPI 146
|
||||
#define TX_DESIGNMISSION 147
|
||||
#define TX_DESIGNMISSIONS 147
|
||||
#define TX_CHOOSEGAMER 148
|
||||
#define TX_CHOOSEPLAYER2 148
|
||||
#define TX_MUSIC 149
|
||||
#define TX_CHOOSEMUSIC2 149
|
||||
#define TX_TRAININGNUM 150
|
||||
#define TX_MISSIONNUM 151
|
||||
#define TX_MISSIONTIME 152
|
||||
#define IDS_STRING152 152
|
||||
#define TX_SIZE 153
|
||||
#define IDS_STRING153 153
|
||||
#define TX_BUTTON_SETUP5 154
|
||||
#define IDS_STRING154 154
|
||||
#define TX_BUTTON_SETUP6 155
|
||||
#define IDS_STRING155 155
|
||||
#define TX_BUTTON_SETUP7 156
|
||||
#define IDS_STRING156 156
|
||||
#define TX_BUTTON_SETUP8 157
|
||||
#define IDS_STRING157 157
|
||||
#define TX_CONFYES 158
|
||||
#define IDS_STRING158 158
|
||||
#define TX_CONFNO 159
|
||||
#define IDS_STRING159 159
|
||||
#define TX_SETTING 160
|
||||
#define IDS_STRING160 160
|
||||
#define TX_SAVECURRENTMISS 161
|
||||
#define IDS_STRING161 161
|
||||
#define TX_SOUNDVOL 162
|
||||
#define IDS_STRING162 162
|
||||
#define TX_MUSICVOL 163
|
||||
#define IDS_STRING163 163
|
||||
#define TX_COLORDEP 164
|
||||
#define IDS_STRING164 164
|
||||
#define TX_INPUT 165
|
||||
#define IDS_STRING165 165
|
||||
#define TX_OPENMISS 166
|
||||
#define IDS_STRING166 166
|
||||
#define TX_READINFO 167
|
||||
#define IDS_STRING167 167
|
||||
#define TX_PLAYERFREE 168
|
||||
#define IDS_STRING168 168
|
||||
#define TX_NUMDOOROPEN 169
|
||||
#define IDS_STRING169 169
|
||||
#define TX_NUMDOORSOPEN 170
|
||||
#define IDS_STRING170 170
|
||||
#define TX_MUSIC10 171
|
||||
#define IDS_STRING171 171
|
||||
#define TX_WRITENAME 172
|
||||
#define IDS_STRING172 172
|
||||
#define TX_NONE 173
|
||||
#define IDS_STRING173 173
|
||||
#define TX_CONFIRM 174
|
||||
#define IDS_STRING174 174
|
||||
#define TX_CANCEL 175
|
||||
#define IDS_STRING175 175
|
||||
#define TX_YES 176
|
||||
#define IDS_STRING176 176
|
||||
#define TX_NO 177
|
||||
#define IDS_STRING177 177
|
||||
#define TX_REGION 178
|
||||
#define IDS_STRING178 178
|
||||
#define TX_SUS 179
|
||||
#define IDS_STRING179 179
|
||||
#define TX_BUTTON_SETUP 180
|
||||
#define IDS_STRING180 180
|
||||
#define TX_SAVES 181
|
||||
#define IDS_STRING181 181
|
||||
#define TX_INSERT 182
|
||||
#define IDS_STRING182 182
|
||||
#define TX_DELETEMISS 183
|
||||
#define IDS_STRING183 183
|
||||
#define TX_DELETEMISSION 184
|
||||
#define IDS_STRING184 184
|
||||
#define TX_NAMEOFMISS 185
|
||||
#define IDS_STRING185 185
|
||||
#define TX_NAMEOFMISSION 186
|
||||
#define IDS_STRING186 186
|
||||
#define TX_NONAME 187
|
||||
#define IDS_STRING187 187
|
||||
#define TX_DESIGN 188
|
||||
#define IDS_STRING188 188
|
||||
#define TX_MISSNUM 189
|
||||
#define IDS_STRING189 189
|
||||
#define TX_MISSTIME 190
|
||||
#define IDS_STRING190 190
|
||||
#define TX_MISSION2D 191
|
||||
#define IDS_STRING191 191
|
||||
#define TX_SHOWNEXT 192
|
||||
#define IDS_STRING192 192
|
||||
#define TX_SHOWPREV 193
|
||||
#define IDS_STRING193 193
|
||||
#define TX_CONTENT 194
|
||||
#define IDS_STRING194 194
|
||||
#define TX_SINGLEPLAYER 195
|
||||
#define IDS_STRING195 195
|
||||
#define TX_MUTLIPLAYER 196
|
||||
#define TX_MULTIPLAYER 196
|
||||
#define IDS_STRING196 196
|
||||
#define TX_GAMEPAUSE 197
|
||||
#define TX_CANCELLAST 198
|
||||
#define TX_PLAYDEMO 199
|
||||
#define IDS_STRING199 199
|
||||
#define TX_HADFUN 200
|
||||
#define IDS_STRING200 200
|
||||
#define TX_OGCREATION 201
|
||||
#define IDS_STRING201 201
|
||||
#define TX_WEBSITE 202
|
||||
#define IDS_STRING202 202
|
||||
#define TX_FULL_END1 203
|
||||
#define IDS_STRING203 203
|
||||
#define TX_FULL_END2 204
|
||||
#define IDS_STRING204 204
|
||||
#define TX_FULL_END3 205
|
||||
#define IDS_STRING205 205
|
||||
#define TX_FULL_END4 206
|
||||
#define IDS_STRING206 206
|
||||
#define TX_CHOOSECOLOR 207
|
||||
#define IDS_STRING207 207
|
||||
#define TX_CLICKREADY 208
|
||||
#define IDS_STRING208 208
|
||||
#define TX_BUTTON_SKILL 209
|
||||
#define IDS_STRING209 209
|
||||
#define TX_EASY 210
|
||||
#define IDS_STRING210 210
|
||||
#define TX_HARD 211
|
||||
#define IDS_STRING211 211
|
||||
#define TX_BUTTON_DEMO 212
|
||||
#define IDS_STRING212 212
|
||||
#define TX_DEMOREC 213
|
||||
#define TX_DEMOPLAY 214
|
||||
#define IDS_STRING215 215
|
||||
#define IDS_STRING216 216
|
||||
#define IDS_STRING217 217
|
||||
#define IDS_STRING218 218
|
||||
#define IDS_STRING219 219
|
||||
#define IDS_STRING220 220
|
||||
#define IDS_STRING221 221
|
||||
#define IDS_STRING222 222
|
||||
#define IDS_STRING223 223
|
||||
#define IDS_STRING224 224
|
||||
#define IDS_STRING225 225
|
||||
#define IDS_STRING226 226
|
||||
#define IDS_STRING227 227
|
||||
#define IDS_STRING228 228
|
||||
#define IDS_STRING229 229
|
||||
#define IDS_STRING230 230
|
||||
#define IDS_STRING231 231
|
||||
#define IDS_STRING232 232
|
||||
#define IDS_STRING233 233
|
||||
#define IDS_STRING234 234
|
||||
#define IDS_STRING235 235
|
||||
#define IDS_STRING236 236
|
||||
#define IDS_STRING237 237
|
||||
#define IDS_STRING238 238
|
||||
#define IDS_STRING239 239
|
||||
#define IDS_STRING240 240
|
||||
#define IDS_STRING241 241
|
||||
#define TX_SHOWCONNECTION 242
|
||||
#define IDS_STRING242 242
|
||||
#define IDS_STRING243 243
|
||||
#define IDS_STRING244 244
|
||||
#define IDS_STRING245 245
|
||||
#define IDS_STRING246 246
|
||||
#define TX_GAMEJOIN 247
|
||||
#define IDS_STRING247 247
|
||||
#define TX_CREATE_MULTIGAME 248
|
||||
#define IDS_STRING248 248
|
||||
#define TX_UPDATELIST 249
|
||||
#define IDS_STRING249 249
|
||||
#define TX_MULTI_CREATE 250
|
||||
#define TX_MULTI_GNAME 251
|
||||
#define IDS_STRING251 251
|
||||
#define IDS_STRING252 252
|
||||
#define IDS_STRING253 253
|
||||
#define IDS_STRING254 254
|
||||
#define IDS_STRING255 255
|
||||
#define IDS_STRING256 256
|
||||
#define IDS_STRING257 257
|
||||
#define IDS_STRING258 258
|
||||
#define IDS_STRING259 259
|
||||
#define IDS_STRING260 260
|
||||
#define IDS_STRING261 261
|
||||
#define IDS_STRING262 262
|
||||
#define IDS_STRING263 263
|
||||
#define TX_OPEN 264
|
||||
#define IDS_STRING264 264
|
||||
#define IDS_STRING265 265
|
||||
#define IDS_STRING266 266
|
||||
#define IDS_STRING267 267
|
||||
#define TX_HELP 268
|
||||
#define IDS_STRING268 268
|
||||
#define TX_LOAD_CGAME 269
|
||||
#define TX_SAVE_CGAME 270
|
||||
#define IDS_STRING271 271
|
||||
#define TX_MISSIONFREE 272
|
||||
#define IDS_STRING272 272
|
||||
#define IDS_STRING273 273
|
||||
#define IDS_STRING274 274
|
||||
#define IDS_STRING275 275
|
||||
#define IDS_STRING276 276
|
||||
#define IDS_STRING277 277
|
||||
#define IDS_STRING278 278
|
||||
#define IDS_STRING279 279
|
||||
#define IDS_STRING280 280
|
||||
#define IDS_STRING281 281
|
||||
#define IDS_STRING282 282
|
||||
#define IDS_STRING283 283
|
||||
#define IDS_STRING284 284
|
||||
#define IDS_STRING285 285
|
||||
#define IDS_STRING286 286
|
||||
#define IDS_STRING287 287
|
||||
#define TX_GAMESAVED 288
|
||||
#define IDS_STRING288 288
|
||||
#define TX_NOTINDEMO 289
|
||||
#define IDS_STRING289 289
|
||||
#define IDS_STRING290 290
|
||||
#define IDS_STRING291 291
|
||||
#define IDS_STRING292 292
|
||||
#define IDS_STRING293 293
|
||||
#define IDS_STRING294 294
|
||||
#define IDS_STRING295 295
|
||||
#define IDS_STRING296 296
|
||||
#define IDS_STRING297 297
|
||||
#define IDS_STRING298 298
|
||||
#define IDS_STRING299 299
|
||||
#define IDS_STRING300 300
|
||||
#define IDS_STRING301 301
|
||||
#define IDS_STRING302 302
|
||||
#define IDS_STRING303 303
|
||||
#define IDS_STRING304 304
|
||||
#define IDS_STRING305 305
|
||||
#define IDS_STRING306 306
|
||||
#define IDS_STRING400 400
|
||||
#define IDS_STRING401 401
|
||||
#define IDS_STRING402 402
|
||||
#define IDS_STRING403 403
|
||||
#define IDS_STRING404 404
|
||||
#define IDS_STRING405 405
|
||||
#define IDS_STRING406 406
|
||||
#define IDS_STRING407 407
|
||||
#define IDS_STRING408 408
|
||||
#define IDS_STRING409 409
|
||||
#define IDS_STRING410 410
|
||||
#define IDS_STRING411 411
|
||||
#define IDS_STRING412 412
|
||||
#define TX_REPEAT_CULTIVE 500
|
||||
#define IDS_STRING500 500
|
||||
#define TX_REPEAT_FLEUR 501
|
||||
#define IDS_STRING501 501
|
||||
#define TX_REPEAT_FLEURQ 502
|
||||
#define IDS_STRING502 502
|
||||
#define TX_REPEAT_FABMINE 503
|
||||
#define IDS_STRING503 503
|
||||
#define TX_REPEAT_FABJEEP 504
|
||||
#define IDS_STRING504 504
|
||||
#define TX_REPEAT_PALIS 505
|
||||
#define IDS_STRING505 505
|
||||
#define TX_REPEAT_PALISQ 506
|
||||
#define IDS_STRING506 506
|
||||
#define TX_REPEAT_PONT 507
|
||||
#define IDS_STRING507 507
|
||||
#define TX_REPEAT_PONTQ 508
|
||||
#define IDS_STRING508 508
|
||||
#define TX_REPEAT_BATEAU 509
|
||||
#define IDS_STRING509 509
|
||||
#define TX_REPEAT_BATEAUQ 510
|
||||
#define IDS_STRING510 510
|
||||
#define TX_REPEAT_FABARMURE 511
|
||||
#define IDS_STRING511 511
|
||||
#define TX_DIRECT_N 512
|
||||
#define IDS_STRING512 512
|
||||
#define TX_DIRECT_S 513
|
||||
#define TX_DIRECT_E 514
|
||||
#define TX_DIRECT_O 515
|
||||
#define IDS_STRING600 600
|
||||
#define IDS_STRING601 601
|
||||
#define IDS_STRING602 602
|
||||
#define IDS_STRING603 603
|
||||
#define IDS_STRING604 604
|
||||
#define IDS_STRING605 605
|
||||
#define IDS_STRING606 606
|
||||
#define IDS_STRING607 607
|
||||
#define IDS_STRING608 608
|
||||
#define IDS_STRING609 609
|
||||
#define IDS_STRING610 610
|
||||
#define IDS_STRING611 611
|
||||
#define IDS_STRING612 612
|
||||
#define IDS_STRING613 613
|
||||
#define IDS_STRING614 614
|
||||
#define IDS_STRING615 615
|
||||
#define IDS_STRING616 616
|
||||
#define IDS_STRING617 617
|
||||
#define IDS_STRING618 618
|
||||
#define IDS_STRING619 619
|
||||
#define IDS_STRING620 620
|
||||
#define IDS_STRING621 621
|
||||
#define IDS_STRING622 622
|
||||
#define IDS_STRING623 623
|
||||
#define IDR_WAVE_BOING 1000
|
||||
#define TX_ERROR_MISC 1000
|
||||
#define IDS_STRING1000 1000
|
||||
#define IDR_WAVE_BLOW 1001
|
||||
#define TX_ERROR_GROUND 1001
|
||||
#define IDS_STRING1001 1001
|
||||
#define TX_ERROR_FREE 1002
|
||||
#define IDS_STRING1002 1002
|
||||
#define TX_ERROR_PONTOP 1003
|
||||
#define IDS_STRING1003 1003
|
||||
#define TX_ERROR_PONTTERM 1004
|
||||
#define IDS_STRING1004 1004
|
||||
#define TX_ERROR_TOURISOL 1005
|
||||
#define IDS_STRING1005 1005
|
||||
#define TX_ERROR_TOUREAU 1006
|
||||
#define IDS_STRING1006 1006
|
||||
#define TX_ERROR_TELE2 1007
|
||||
#define IDS_STRING1007 1007
|
||||
#define IDS_STRING1008 1008
|
||||
#define IDS_STRING1009 1009
|
||||
#define IDS_STRING1010 1010
|
||||
#define IDS_STRING1011 1011
|
||||
#define IDS_STRING1012 1012
|
||||
#define IDS_STRING1013 1013
|
||||
#define IDS_STRING1014 1014
|
||||
#define IDS_STRING1015 1015
|
||||
#define IDS_STRING1016 1016
|
||||
#define IDS_STRING1017 1017
|
||||
#define IDS_STRING1018 1018
|
||||
#define IDS_STRING1019 1019
|
||||
#define IDS_STRING1020 1020
|
||||
#define IDS_STRING1021 1021
|
||||
#define IDS_STRING1022 1022
|
||||
#define IDS_STRING1023 1023
|
||||
#define IDS_STRING1024 1024
|
||||
#define IDS_STRING1025 1025
|
||||
#define IDS_STRING1026 1026
|
||||
#define IDS_STRING1027 1027
|
||||
#define IDS_STRING1028 1028
|
||||
#define IDS_STRING1029 1029
|
||||
#define IDS_STRING1030 1030
|
||||
#define IDS_STRING1031 1031
|
||||
#define IDS_STRING1032 1032
|
||||
#define IDS_STRING1033 1033
|
||||
#define IDS_STRING1034 1034
|
||||
#define IDS_STRING1035 1035
|
||||
#define IDS_STRING1036 1036
|
||||
#define IDS_STRING1037 1037
|
||||
#define IDS_STRING1038 1038
|
||||
#define IDS_STRING1039 1039
|
||||
#define IDS_STRING1040 1040
|
||||
#define IDS_STRING1041 1041
|
||||
#define IDS_STRING1042 1042
|
||||
#define IDS_STRING1043 1043
|
||||
#define IDS_STRING1044 1044
|
||||
#define IDS_STRING1045 1045
|
||||
#define IDS_STRING1046 1046
|
||||
#define IDS_STRING1047 1047
|
||||
#define IDS_STRING1048 1048
|
||||
#define IDS_STRING1049 1049
|
||||
#define IDS_STRING1050 1050
|
||||
#define IDS_STRING1051 1051
|
||||
#define IDS_STRING1052 1052
|
||||
#define IDS_STRING1053 1053
|
||||
#define IDS_STRING1054 1054
|
||||
#define IDS_STRING1055 1055
|
||||
#define IDS_STRING1056 1056
|
||||
#define IDS_STRING1057 1057
|
||||
#define IDS_STRING1058 1058
|
||||
#define IDS_STRING1059 1059
|
||||
#define IDS_STRING1060 1060
|
||||
#define IDS_STRING1061 1061
|
||||
#define IDS_STRING1062 1062
|
||||
#define IDS_STRING1063 1063
|
||||
#define IDS_STRING1064 1064
|
||||
#define IDS_STRING1065 1065
|
||||
#define IDS_STRING1066 1066
|
||||
#define IDS_STRING1067 1067
|
||||
#define IDS_STRING1068 1068
|
||||
#define IDS_STRING1069 1069
|
||||
#define IDS_STRING1070 1070
|
||||
#define IDS_STRING1071 1071
|
||||
#define IDS_STRING1072 1072
|
||||
#define IDS_STRING1073 1073
|
||||
#define IDS_STRING1074 1074
|
||||
#define IDS_STRING1075 1075
|
||||
#define IDS_STRING1076 1076
|
||||
#define IDS_STRING1077 1077
|
||||
#define IDS_STRING1078 1078
|
||||
#define IDS_STRING1079 1079
|
||||
#define IDS_STRING1080 1080
|
||||
#define IDS_STRING1081 1081
|
||||
#define IDS_STRING1082 1082
|
||||
#define IDS_STRING1083 1083
|
||||
#define IDS_STRING1084 1084
|
||||
#define TX_OBJ_BLUPIm 2000
|
||||
#define TX_OBJ_BLUPIf 2001
|
||||
#define TX_OBJ_BLUPI 2002
|
||||
#define TX_OBJ_BATEAU 2003
|
||||
#define TX_OBJ_JEEP 2004
|
||||
#define IDS_STRING2004 2004
|
||||
#define TX_OBJ_PIEGE 2005
|
||||
#define TX_OBJ_POISON 2006
|
||||
#define TX_OBJ_DYNAMITE 2007
|
||||
#define IDS_STRING2007 2007
|
||||
#define TX_OBJ_MINE 2008
|
||||
#define TX_OBJ_TOMATE 2009
|
||||
#define IDS_STRING2009 2009
|
||||
#define TX_OBJ_POTION 2010
|
||||
#define TX_OBJ_PLANCHE 2011
|
||||
#define TX_OBJ_PIERRE 2012
|
||||
#define TX_OBJ_DRAPEAU 2013
|
||||
#define TX_OBJ_FER 2014
|
||||
#define TX_OBJ_FLEUR1 2015
|
||||
#define TX_OBJ_FLEUR2 2016
|
||||
#define TX_OBJ_FLEUR3 2017
|
||||
#define TX_OBJ_CABANE 2018
|
||||
#define TX_OBJ_LABO 2019
|
||||
#define TX_OBJ_MINEFER 2020
|
||||
#define TX_OBJ_USINE 2021
|
||||
#define TX_OBJ_TOUR 2022
|
||||
#define TX_OBJ_FEU 2023
|
||||
#define TX_OBJ_ROBOT 2024
|
||||
#define TX_OBJ_TRACKS 2025
|
||||
#define TX_OBJ_BOMBE 2026
|
||||
#define TX_OBJ_ARAIGNEE 2027
|
||||
#define TX_OBJ_VIRUS 2028
|
||||
#define TX_OBJ_ELECTRO 2029
|
||||
#define TX_OBJ_ARBRE 2030
|
||||
#define IDS_STRING2030 2030
|
||||
#define TX_OBJ_MUR 2031
|
||||
#define TX_OBJ_ARBREb 2032
|
||||
#define TX_OBJ_ROC 2033
|
||||
#define IDS_STRING2033 2033
|
||||
#define TX_OBJ_OEUF 2034
|
||||
#define TX_OBJ_PALISSADE 2035
|
||||
#define TX_OBJ_ENNEMIp 2036
|
||||
#define TX_OBJ_ENNEMI 2037
|
||||
#define TX_OBJ_HERBE 2038
|
||||
#define IDS_STRING2038 2038
|
||||
#define TX_OBJ_MOUSSE 2039
|
||||
#define TX_OBJ_TERRE 2040
|
||||
#define TX_OBJ_EAU 2041
|
||||
#define IDS_STRING2041 2041
|
||||
#define TX_OBJ_RIVE 2042
|
||||
#define TX_OBJ_MIXTE 2043
|
||||
#define TX_OBJ_PONT 2044
|
||||
#define IDS_STRING2044 2044
|
||||
#define TX_OBJ_COUVEUSE 2045
|
||||
#define TX_OBJ_GLACE 2046
|
||||
#define TX_OBJ_MAISON 2047
|
||||
#define IDS_STRING2047 2047
|
||||
#define TX_OBJ_HACHURE 2048
|
||||
#define TX_OBJ_MOUSSEb 2049
|
||||
#define TX_OBJ_BOUQUET1 2050
|
||||
#define TX_OBJ_BOUQUET2 2051
|
||||
#define TX_OBJ_BOUQUET3 2052
|
||||
#define TX_OBJ_DALLE 2053
|
||||
#define TX_OBJ_ENNEMIs 2054
|
||||
#define TX_OBJ_DISCIPLE 2055
|
||||
#define TX_OBJ_METAL 2056
|
||||
#define TX_OBJ_FUSEE 2057
|
||||
#define TX_OBJ_TELEPORTE 2058
|
||||
#define TX_OBJ_ARMURE 2059
|
||||
#define TX_OBJ_DALLESPEC 2060
|
||||
#define TX_OBJ_COUVTELE 2061
|
||||
#define TX_OBJ_BATIMENT 2062
|
||||
#define TX_OBJ_BATENNEMIS 2063
|
||||
#define TX_OBJ_MURPAL 2064
|
||||
#define TX_OBJ_OBJET 2065
|
||||
#define TX_OBJ_ARME 2066
|
||||
#define TX_OBJ_VEHICULE 2067
|
||||
#define TX_OBJ_STARTFEU 2068
|
||||
#define TX_OBJ_DELOBJ 2069
|
||||
#define TX_OBJ_DELPERSO 2070
|
||||
#define TX_OBJ_DELFEU 2071
|
||||
#define TX_OBJ_PLANTE 2072
|
||||
#define IDS_STRING2072 2072
|
||||
#define TX_OBJ_BARENNEMIS 2073
|
||||
#define TX_WIN1 3000
|
||||
#define TX_WIN2 3001
|
||||
#define TX_WIN3 3002
|
||||
#define TX_WIN4 3003
|
||||
#define TX_WIN5 3004
|
||||
#define TX_LOST1 3100
|
||||
#define TX_LOST2 3101
|
||||
#define TX_LOST3 3102
|
||||
#define TX_LOST4 3103
|
||||
#define TX_LOST5 3104
|
||||
#define TX_LASTWIN1 3200
|
||||
#define IDS_STRING3200 3200
|
||||
#define TX_LASTWIN2 3201
|
||||
#define IDS_STRING3201 3201
|
||||
#define TX_LASTWIN3 3202
|
||||
#define IDS_STRING3202 3202
|
||||
#define TX_BUTTON_CREATE 6900
|
||||
#define IDM_EXIT 40001
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 195
|
||||
#define _APS_NEXT_COMMAND_VALUE 40001
|
||||
#define _APS_NEXT_CONTROL_VALUE 1000
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
88
resource/resource1.h
Normal file
@ -0,0 +1,88 @@
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Visual C++ generated include file.
|
||||
// Used by Eggbert2.rc
|
||||
//
|
||||
#pragma once
|
||||
#define IDS_STRING101 101
|
||||
#define IDS_STRING102 102
|
||||
#define IDC_CURSOR1 102
|
||||
#define IDS_STRING103 103
|
||||
#define IDC_CURSOR2 103
|
||||
#define IDS_STRING104 104
|
||||
#define IDC_CURSOR3 104
|
||||
#define IDS_STRING105 105
|
||||
#define IDC_CURSOR4 105
|
||||
#define IDS_STRING106 106
|
||||
#define IDC_CURSOR5 106
|
||||
#define IDS_STRING107 107
|
||||
#define IDC_CURSOR6 107
|
||||
#define IDS_STRING108 108
|
||||
#define IDC_CURSOR7 108
|
||||
#define IDS_STRING109 109
|
||||
#define IDC_CURSOR8 109
|
||||
#define IDS_STRING110 110
|
||||
#define IDC_CURSOR9 110
|
||||
#define IDS_STRING111 111
|
||||
#define IDC_CURSOR10 111
|
||||
#define IDS_STRING112 112
|
||||
#define IDC_CURSOR11 112
|
||||
#define IDS_STRING113 113
|
||||
#define IDC_CURSOR12 113
|
||||
#define IDS_STRING114 114
|
||||
#define IDC_CURSOR13 114
|
||||
#define IDS_STRING115 115
|
||||
#define IDC_CURSOR14 115
|
||||
#define IDS_STRING116 116
|
||||
#define IDC_CURSOR15 116
|
||||
#define IDS_STRING117 117
|
||||
#define IDI_ICON1 117
|
||||
#define IDS_STRING118 118
|
||||
#define IDD_DIALOG1 118
|
||||
#define IDS_STRING119 119
|
||||
#define IDS_STRING120 120
|
||||
#define IDS_STRING121 121
|
||||
#define IDS_STRING122 122
|
||||
#define IDS_STRING123 123
|
||||
#define IDS_STRING124 124
|
||||
#define IDS_STRING125 125
|
||||
#define IDS_STRING126 126
|
||||
#define IDS_STRING127 127
|
||||
#define IDS_STRING128 128
|
||||
#define IDS_STRING129 129
|
||||
#define IDS_STRING130 130
|
||||
#define IDS_STRING131 131
|
||||
#define IDS_STRING132 132
|
||||
#define IDS_STRING133 133
|
||||
#define IDS_STRING134 134
|
||||
#define IDS_STRING135 135
|
||||
#define IDS_STRING136 136
|
||||
#define IDS_STRING137 137
|
||||
#define IDS_STRING198 149
|
||||
#define IDS_STRING150 178
|
||||
#define IDS_STRING197 197
|
||||
#define IDS_STRING213 213
|
||||
#define IDS_STRING214 214
|
||||
#define IDS_STRING250 250
|
||||
#define IDS_STRING3005 269
|
||||
#define IDS_STRING270 270
|
||||
#define IDS_STRING3105 3000
|
||||
#define IDS_STRING3001 3001
|
||||
#define IDS_STRING3002 3002
|
||||
#define IDS_STRING3003 3003
|
||||
#define IDS_STRING3004 3004
|
||||
#define IDS_STRING138 3100
|
||||
#define IDS_STRING3101 3101
|
||||
#define IDS_STRING3102 3102
|
||||
#define IDS_STRING3103 3103
|
||||
#define IDS_STRING3104 3104
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 120
|
||||
#define _APS_NEXT_COMMAND_VALUE 40001
|
||||
#define _APS_NEXT_CONTROL_VALUE 1001
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
108
resource/resource2.h
Normal file
@ -0,0 +1,108 @@
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Visual C++ generated include file.
|
||||
// Used by Resource.rc
|
||||
//
|
||||
#define TX_IONAMEEX 100
|
||||
#define TX_IOFREE 101
|
||||
#define TX_OWNMISSION 102
|
||||
#define TX_TESTMISSION 103
|
||||
#define TX_BUTTON_JOUER 104
|
||||
#define TX_BUTTON_APPRENDRE 105
|
||||
#define TX_BUTTON_QUITTER 106
|
||||
#define TX_BUTTON_PREVP 107
|
||||
#define TX_BUTTON_NEXTP 108
|
||||
#define TX_BUTTON_PLAYP 109
|
||||
#define TX_BUTTON_BUILDP 110
|
||||
#define TX_BUTTON_TERM 111
|
||||
#define TX_BUTTON_READP 112
|
||||
#define TX_BUTTON_WRITEP 113
|
||||
#define TX_BUTTON_CANCELP 114
|
||||
#define TX_BUTTON_CONTP 115
|
||||
#define TX_BUTTON_REPEAT 116
|
||||
#define TX_CHOOSEPLAYER 117
|
||||
#define TX_PLAYERSNAME 118
|
||||
#define TX_BUTTON_TERMC 119
|
||||
#define TX_CHOOSESIZE 120
|
||||
#define TX_BUTTON_HVSCROLL 121
|
||||
#define TX_BUTTON_ONLYHSSCROLL 122
|
||||
#define TX_BUTTON_ONLYVSCROLL 123
|
||||
#define TX_BUTTON_TESTMISSION 124
|
||||
#define TX_PAUSE 125
|
||||
#define TX_TINY 126
|
||||
#define TX_CLEARPLAYER 127
|
||||
#define TX_SETTINGS 128
|
||||
#define TX_CHOOSEMUSIC 129
|
||||
#define TX_BUTTON_SETUP1 130
|
||||
#define TX_BUTTON_SETUP2 131
|
||||
#define TX_BUTTON_SETUP3 132
|
||||
#define TX_BUTTON_SETUP4 133
|
||||
#define TX_NOMUSIC 134
|
||||
#define TX_MUSIC1 135
|
||||
#define TX_MUSIC2 136
|
||||
#define TX_MUSIC3 137
|
||||
#define TX_MUSIC4 138
|
||||
#define TX_MUSIC5 139
|
||||
#define TX_MUSIC6 140
|
||||
#define TX_MUSIC7 141
|
||||
#define TX_MUSIC8 142
|
||||
#define TX_MUSIC9 143
|
||||
#define TX_BUTTON_REGION 144
|
||||
#define TX_DISCARDGAME 145
|
||||
#define TX_EGGBERT 146
|
||||
#define TX_DESIGNMISSION 147
|
||||
#define TX_CHOOSEGAMER 148
|
||||
#define TX_MUSIC 149
|
||||
#define TX_TRAININGNUM 150
|
||||
#define TX_MISSIONNUM 151
|
||||
#define TX_MISSIONTIME 152
|
||||
#define TX_SIZE 153
|
||||
#define TX_BUTTON_SETUP5 154
|
||||
#define TX_BUTTON_SETUP6 155
|
||||
#define TX_BUTTON_SETUP7 156
|
||||
#define TX_BUTTON_SETUP8 157
|
||||
#define TX_CONFYES 158
|
||||
#define TX_CONFNO 159
|
||||
#define TX_SETTING 160
|
||||
#define TX_SAVECURRENTMISS 161
|
||||
#define TX_SOUNDVOL 162
|
||||
#define TX_MUSICVOL 163
|
||||
#define TX_COLORDEP 164
|
||||
#define TX_INPUT 165
|
||||
#define TX_OPENMISS 166
|
||||
#define TX_READINFO 167
|
||||
#define TX_PLAYERFREE 168
|
||||
#define TX_NUMDOOROPEN 169
|
||||
#define TX_NUMDOORSOPEN 170
|
||||
#define TX_MUSIC10 171
|
||||
#define TX_WRITENAME 172
|
||||
#define TX_NONE 173
|
||||
#define TX_CONFIRM 174
|
||||
#define TX_CANCEL 175
|
||||
#define TX_YES 176
|
||||
#define TX_NO 177
|
||||
#define TX_REGION 178
|
||||
#define TX_SUS 179
|
||||
#define TX_BUTTON_SETUP 180
|
||||
#define TX_SAVES 181
|
||||
#define TX_INSERT 182
|
||||
#define TX_DELETEMISS 183
|
||||
#define TX_DELETEMISSION 184
|
||||
#define TX_NAMEOFMISS 185
|
||||
#define TX_NAMEOFMISSION 186
|
||||
#define TX_NONAME 187
|
||||
#define TX_DESIGN 188
|
||||
#define TX_MISSNUM 189
|
||||
#define TX_MISSTIME 190
|
||||
#define IDI_ICON1 190
|
||||
#define TX_MISSION2D 191
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 191
|
||||
#define _APS_NEXT_COMMAND_VALUE 40001
|
||||
#define _APS_NEXT_CONTROL_VALUE 1001
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
BIN
resource/rstemp.rct
Normal file
BIN
resource/speedy.aps
Normal file
63
resource/speedy.rc
Normal file
@ -0,0 +1,63 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "resource.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// English (U.S.) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"resource.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
#endif // English (U.S.) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
BIN
resource/speedyblupi.aps
Normal file
BIN
resource/speedyblupi.rc
Normal file
BIN
resource/wait.cur
Normal file
After Width: | Height: | Size: 326 B |
BIN
screenshot.png
Normal file
After Width: | Height: | Size: 122 KiB |
897
src/blupi.cpp
Normal file
@ -0,0 +1,897 @@
|
||||
// blupi.cpp
|
||||
//
|
||||
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
|
||||
#include <windows.h>
|
||||
#include <windowsx.h>
|
||||
#include <WTypes.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <mmsystem.h>
|
||||
#include <time.h>
|
||||
#include <sys/timeb.h>
|
||||
#include "def.h"
|
||||
#include "resource.h"
|
||||
#include "ddutil.h"
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
#include "decor.h"
|
||||
#include "movie.h"
|
||||
#include "button.h"
|
||||
#include "menu.h"
|
||||
#include "event.h"
|
||||
#include "network.h"
|
||||
#include "misc.h"
|
||||
|
||||
// Define Globals
|
||||
|
||||
#define NAME "Blupi"
|
||||
#ifdef _EGAMES
|
||||
#define TITLE "Eggbert"
|
||||
#else
|
||||
#define TITLE "Blupi"
|
||||
#endif
|
||||
|
||||
#define MMTIMER TRUE
|
||||
#define THREAD FALSE
|
||||
|
||||
// Variables Globals
|
||||
|
||||
HWND g_hWnd; // handle à la fenètre
|
||||
CEvent* g_pEvent = NULL;
|
||||
CPixmap* g_pPixmap = NULL; // pixmap principal
|
||||
CSound* g_pSound = NULL; // sound principal
|
||||
CMovie* g_pMovie = NULL; // movie principal
|
||||
CDecor* g_pDecor = NULL;
|
||||
CNetwork* g_pNetwork = NULL;
|
||||
char g_CDPath[MAX_PATH]; // chemin d'accès au CD-Rom
|
||||
BOOL g_bFullScreen = FALSE; // FALSE si mode de test
|
||||
int g_speedRate = 1;
|
||||
int g_timerInterval = 50; // inverval = 50ms
|
||||
int g_mouseType = MOUSETYPEGRA;
|
||||
int g_benchmark;
|
||||
BOOL g_bBenchmarkSuccess;
|
||||
BOOL g_bTrueColorBack;
|
||||
BOOL g_bTrueColorDecor;
|
||||
BOOL g_bCDAudio = FALSE;
|
||||
int g_something;
|
||||
MMRESULT g_updateTimer; // timer général
|
||||
BOOL g_bActive = TRUE; // is application active ?
|
||||
BOOL g_bTermInit = FALSE; // initialisation en cours
|
||||
int g_timer;
|
||||
|
||||
UINT g_lastPhase = 999;
|
||||
|
||||
// Lit un numéro décimal.
|
||||
|
||||
int GetNum(char *p)
|
||||
{
|
||||
int n = 0;
|
||||
|
||||
while ( *p >= '0' && *p <= '9' )
|
||||
{
|
||||
n *= 10;
|
||||
n += (*p++)-'0';
|
||||
}
|
||||
|
||||
return n;
|
||||
}
|
||||
|
||||
BOOL ReadConfig(LPSTR lpCmdLine)
|
||||
{
|
||||
FILE* file = NULL;
|
||||
char buffer[200];
|
||||
char* pText;
|
||||
int nb;
|
||||
int i;
|
||||
MEMORYSTATUS mem;
|
||||
|
||||
file = fopen("data\\config.def", "rb");
|
||||
if (file == NULL) return FALSE;
|
||||
nb = fread(buffer, sizeof(char), 200 - 1, file);
|
||||
buffer[nb] = 0;
|
||||
fclose(file);
|
||||
|
||||
|
||||
#if _CD
|
||||
pText = strstr(buffer, "CD-Rom=");
|
||||
if (pText == NULL)
|
||||
{
|
||||
#if _DEMO
|
||||
GetCurrentDirectory(MAX_PATH, g_CDPath);
|
||||
i = strlen(g_CDPath);
|
||||
if (i > 0 && g_CDPath[i - 1] != '\\')
|
||||
{
|
||||
g_CDPath[i++] = '\\';
|
||||
g_CDPath[i] = 0;
|
||||
}
|
||||
#else
|
||||
return FALSE;
|
||||
#endif // _DEMO
|
||||
}
|
||||
else
|
||||
{
|
||||
pText += 7;
|
||||
i = 0;
|
||||
while (pText[i] != 0 && pText[i] != '\n' && pText[i] != '\r')
|
||||
{
|
||||
g_CDPath[i] = pText[i];
|
||||
i++;
|
||||
}
|
||||
if (i > 0 && g_CDPath[i - 1] != '\\')
|
||||
{
|
||||
g_CDPath[i++] = '\\';
|
||||
}
|
||||
g_CDPath[i] = 0; // met le terminateur
|
||||
}
|
||||
|
||||
#if !_DEMO && !_EGAMES
|
||||
if (strstr(lpCmdLine, "-nocd") == NULL)
|
||||
{
|
||||
char drive[10];
|
||||
|
||||
drive[0] = g_CDPath[0];
|
||||
drive[1] = ':';
|
||||
drive[2] = '\\';
|
||||
drive[3] = 0;
|
||||
nb = GetDriveType(drive);
|
||||
if (nb != DRIVE_CDROM) return FALSE;
|
||||
}
|
||||
#endif // !_DEMO && !_EGAMES
|
||||
#endif // _CD
|
||||
|
||||
pText = strstr(buffer, "SpeedRate=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
g_speedRate = GetNum(pText + 10);
|
||||
if (g_speedRate < 1) g_speedRate = 1;
|
||||
if (g_speedRate > 2) g_speedRate = 2;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "Timer=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
g_timerInterval = GetNum(pText + 6);
|
||||
if (g_timerInterval < 10) g_timerInterval = 10;
|
||||
if (g_timerInterval > 1000) g_timerInterval = 1000;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "FullScreen=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
g_bFullScreen = GetNum(pText + 11);
|
||||
if (g_bFullScreen != 0) g_bFullScreen = 1;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "MouseType=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
g_mouseType = GetNum(pText + 10);
|
||||
if (g_mouseType < 1) g_mouseType = 1;
|
||||
if (g_mouseType > 9) g_mouseType = 9;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "Benchmark=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
g_benchmark = GetNum(pText + 10);
|
||||
if (g_benchmark < 0) g_benchmark = 0;
|
||||
if (g_benchmark > 100000) g_benchmark = 100000;
|
||||
if (g_benchmark > 3099)
|
||||
{
|
||||
g_bBenchmarkSuccess = TRUE;
|
||||
g_bTrueColorBack = TRUE;
|
||||
g_bTrueColorDecor = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "TrueColor=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
i = GetNum(pText + 10);
|
||||
if (i == 8) g_bTrueColorBack = FALSE;
|
||||
if (i == 16) g_bTrueColorBack = TRUE;
|
||||
g_bTrueColorDecor = g_bTrueColorBack;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "TrueColorBack=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
i = GetNum(pText + 14);
|
||||
if (i == 8) g_bTrueColorBack = FALSE;
|
||||
if (i == 16) g_bTrueColorBack = TRUE;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "TrueColorDecor=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
i = GetNum(pText + 15);
|
||||
if (i == 8) g_bTrueColorDecor = FALSE;
|
||||
if (i == 16) g_bTrueColorDecor = TRUE;
|
||||
}
|
||||
|
||||
pText = strstr(buffer, "CDAudio=");
|
||||
if (pText != NULL)
|
||||
{
|
||||
i = GetNum(pText + 8);
|
||||
g_bCDAudio = (i == TRUE);
|
||||
}
|
||||
|
||||
mem.dwLength = sizeof(MEMORYSTATUS);
|
||||
GlobalMemoryStatus(&mem);
|
||||
|
||||
if (mem.dwTotalPhys < 32000000) g_bBenchmarkSuccess = FALSE;
|
||||
|
||||
if (!g_bBenchmarkSuccess)
|
||||
{
|
||||
g_bTrueColorBack = FALSE;
|
||||
g_bTrueColorDecor = FALSE;
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// Mise à jour principale.
|
||||
|
||||
void UpdateFrame(void)
|
||||
{
|
||||
int phase, term, speed;
|
||||
|
||||
g_pEvent->ReadInput();
|
||||
phase = g_pEvent->GetPhase();
|
||||
|
||||
if (phase == WM_PHASE_INTRO1 ||
|
||||
phase == WM_PHASE_INTRO2)
|
||||
{
|
||||
g_pEvent->IntroStep();
|
||||
}
|
||||
|
||||
if (phase == WM_PHASE_PLAY || phase == WM_PHASE_PLAYTEST || phase == WM_PHASE_BUILD)
|
||||
{
|
||||
if (!g_pDecor->GetPause())
|
||||
{
|
||||
speed = g_pEvent->GetSpeed() * g_speedRate;
|
||||
for (int i = 0; i < speed; i++)
|
||||
{
|
||||
g_pDecor->MoveStep();
|
||||
g_pEvent->DemoStep();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (phase == WM_PHASE_INIT)
|
||||
{
|
||||
g_pEvent->DemoStep(); // d?marre ?v. d?mo automatique
|
||||
}
|
||||
|
||||
if (phase == WM_PHASE_PLAYMOVIE ||
|
||||
phase == WM_PHASE_WINMOVIE ||
|
||||
phase == WM_PHASE_WINMOVIEDESIGN ||
|
||||
phase == WM_PHASE_WINMOVIEMULTI)
|
||||
{
|
||||
g_pEvent->MovieToStart();
|
||||
}
|
||||
|
||||
if (phase == WM_PHASE_INSERT)
|
||||
{
|
||||
g_pEvent->TryInsert();
|
||||
}
|
||||
|
||||
if (phase == WM_PHASE_PLAY)
|
||||
{
|
||||
term = g_pDecor->IsTerminated();
|
||||
|
||||
if (g_pEvent->IsPrivate())
|
||||
{
|
||||
if (term == -1)
|
||||
{
|
||||
g_pEvent->ChangePhase(WM_PHASE_LOSTDESIGN);
|
||||
return;
|
||||
}
|
||||
if (term != 0)
|
||||
{
|
||||
g_pEvent->ChangePhase(WM_PHASE_WINMOVIEDESIGN);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (g_pEvent->IsMulti())
|
||||
{
|
||||
if (term == -1)
|
||||
{
|
||||
g_pEvent->ChangePhase(WM_PHASE_WINMULTI);
|
||||
return;
|
||||
}
|
||||
if (term != 0)
|
||||
{
|
||||
g_pEvent->ChangePhase(WM_PHASE_WINMOVIEMULTI);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (term == -1)
|
||||
{
|
||||
g_pEvent->GetWorldGroup();
|
||||
g_pEvent->SetNbVies(g_pDecor->GetNbVies());
|
||||
g_pEvent->ChangePhase(WM_PHASE_LOST);
|
||||
}
|
||||
if (term == -2)
|
||||
{
|
||||
g_pEvent->SetNbVies(g_pDecor->GetNbVies());
|
||||
g_pEvent->ChangePhase(WM_PHASE_WINMOVIE);
|
||||
}
|
||||
if (term > 0)
|
||||
{
|
||||
g_pEvent->SetNbVies(g_pDecor->GetNbVies());
|
||||
g_pEvent->SetMission(term);
|
||||
g_pEvent->ChangePhase(WM_PHASE_PLAY);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void SetDecor()
|
||||
{
|
||||
RECT rect;
|
||||
UINT phase;
|
||||
POINT posMouse;
|
||||
char test[12];
|
||||
|
||||
g_pPixmap->MouseBackClear();
|
||||
posMouse = g_pEvent->GetLastMousePos();
|
||||
|
||||
phase = g_pEvent->GetPhase();
|
||||
|
||||
rect = RECT( 0, 0, LXIMAGE, LYIMAGE );
|
||||
|
||||
if (phase == WM_PHASE_PLAY || phase == WM_PHASE_PLAYTEST || phase == WM_PHASE_BUILD)
|
||||
{
|
||||
g_pDecor->Build(rect);
|
||||
}
|
||||
else {
|
||||
g_pPixmap->DrawImage(-1, 0, rect, 1);
|
||||
}
|
||||
|
||||
g_pEvent->DrawButtons();
|
||||
g_lastPhase = phase;
|
||||
g_pPixmap->MouseBackDraw();
|
||||
}
|
||||
|
||||
// Restitue le jeu après une activation en mode fullScreen.
|
||||
|
||||
BOOL RestoreGame()
|
||||
{
|
||||
if (g_pPixmap == NULL) return FALSE;
|
||||
|
||||
g_pEvent->RestoreGame();
|
||||
return g_pPixmap->Restore();
|
||||
}
|
||||
|
||||
// Libère le jeu avant une désactivation en mode fullScreen.
|
||||
|
||||
BOOL FlushGame()
|
||||
{
|
||||
if (g_pPixmap == NULL) return FALSE;
|
||||
|
||||
return g_pPixmap->Flush();
|
||||
}
|
||||
|
||||
// Finished with all objects we use; release them.
|
||||
|
||||
static void FinishObjects(void)
|
||||
{
|
||||
if ( g_pMovie != NULL )
|
||||
{
|
||||
g_pEvent->StopMovie();
|
||||
|
||||
delete g_pMovie;
|
||||
g_pMovie = NULL;
|
||||
}
|
||||
|
||||
if ( g_pEvent != NULL )
|
||||
{
|
||||
delete g_pEvent;
|
||||
g_pEvent = NULL;
|
||||
}
|
||||
|
||||
if ( g_pDecor != NULL )
|
||||
{
|
||||
delete g_pDecor;
|
||||
g_pDecor = NULL;
|
||||
}
|
||||
|
||||
if (g_pSound != NULL )
|
||||
{
|
||||
g_pSound->StopMusic();
|
||||
|
||||
delete g_pSound;
|
||||
g_pSound = NULL;
|
||||
}
|
||||
|
||||
if (g_pNetwork != NULL )
|
||||
{
|
||||
delete g_pNetwork;
|
||||
g_pNetwork = NULL;
|
||||
}
|
||||
|
||||
if ( g_pPixmap != NULL )
|
||||
{
|
||||
delete g_pPixmap;
|
||||
g_pPixmap = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
LRESULT CALLBACK WindowProc(HWND hWnd, UINT message,
|
||||
WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
static HINSTANCE hInstance;
|
||||
POINT mousePos, totalDim, iconDim;
|
||||
|
||||
#if 0
|
||||
if (message != WM_TIMER)
|
||||
{
|
||||
char s[100];
|
||||
sprintf(s, "message=%d,%d\n", message, wParam);
|
||||
OutputDebug(s);
|
||||
}
|
||||
#endif
|
||||
|
||||
// La touche F10 envoie un autre message pour activer
|
||||
// le menu dans les applications Windows standard !
|
||||
if (message == WM_SYSKEYDOWN && wParam == VK_F10)
|
||||
{
|
||||
message = WM_KEYDOWN;
|
||||
}
|
||||
if (message == WM_SYSKEYUP && wParam == VK_F10)
|
||||
{
|
||||
message = WM_KEYUP;
|
||||
}
|
||||
|
||||
if (g_pEvent != NULL &&
|
||||
g_pEvent->TreatEvent(message, wParam, lParam)) return 0;
|
||||
|
||||
switch (message)
|
||||
{
|
||||
case WM_TIMER:
|
||||
case WM_UPDATE:
|
||||
if (g_pEvent != NULL && !g_pEvent->IsMovie() && !g_pEvent->IsMouseRelease()) // pas de film en cours ?
|
||||
{
|
||||
g_pEvent->GetPhase(); // ?
|
||||
if (g_bActive)
|
||||
{
|
||||
UpdateFrame();
|
||||
SetDecor();
|
||||
}
|
||||
g_pPixmap->Display();
|
||||
}
|
||||
if (g_timer > 0) g_timer--;
|
||||
break;
|
||||
case WM_CREATE:
|
||||
hInstance = ((LPCREATESTRUCT)lParam)->hInstance;
|
||||
return 0;
|
||||
break;
|
||||
case WM_ACTIVATEAPP:
|
||||
g_bActive = (wParam != 0);
|
||||
if (g_pEvent != NULL)
|
||||
{
|
||||
g_pEvent->FlushInput();
|
||||
}
|
||||
if (g_bActive)
|
||||
{
|
||||
if (g_bFullScreen)
|
||||
{
|
||||
RestoreGame();
|
||||
g_lastPhase = 999;
|
||||
}
|
||||
if (!g_bFullScreen && g_bTermInit)
|
||||
{
|
||||
g_pPixmap->BackgroundCache(CHLITTLE, "little.blp", POINT( 256, 96 ), POINT( DIMLITTLEX , DIMLITTLEY ), TRUE);
|
||||
g_pPixmap->SetTransparent(CHLITTLE, RGB(0, 0, 255)); // bleu
|
||||
|
||||
g_pPixmap->SavePalette();
|
||||
g_pPixmap->InitSysPalette();
|
||||
}
|
||||
SetWindowText(hWnd, "Blupi");
|
||||
if (g_pSound != NULL) g_pSound->RestartMusic();
|
||||
}
|
||||
else // désactive ?
|
||||
{
|
||||
if (g_bFullScreen)
|
||||
{
|
||||
FlushGame();
|
||||
}
|
||||
SetWindowText(hWnd, "Blupi -- stop");
|
||||
if (g_pSound != NULL) g_pSound->SuspendMusic();
|
||||
}
|
||||
return 0;
|
||||
|
||||
case WM_SYSCOLORCHANGE:
|
||||
OutputDebug("Event WM_SYSCOLORCHANGE\n");
|
||||
break;
|
||||
|
||||
case WM_QUERYNEWPALETTE:
|
||||
OutputDebug("Event WM_QUERYNEWPALETTE\n");
|
||||
break;
|
||||
|
||||
case WM_PALETTECHANGED:
|
||||
OutputDebug("Event WM_PALLETECHANGED\n");
|
||||
break;
|
||||
|
||||
case WM_DISPLAYCHANGE:
|
||||
OutputDebug("Event WM_DISPLAYCHANGE\n");
|
||||
break;
|
||||
|
||||
case MM_MCINOTIFY:
|
||||
OutputDebug("Event MM_MCINOTIFY\n");
|
||||
if (g_pEvent->IsMovie()) // film en cours ?
|
||||
{
|
||||
if (wParam == MCI_NOTIFY_SUCCESSFUL)
|
||||
{
|
||||
g_pEvent->StopMovie();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// music over, play it again
|
||||
g_pSound->SuspendMusic();
|
||||
// if music finished, play it again. Otherwise assume that
|
||||
// it was aborted by the user or otherwise
|
||||
if (wParam == MCI_NOTIFY_SUCCESSFUL)
|
||||
{
|
||||
OutputDebug("Event MCI_NOTIFY_SUCCESSFUL\n");
|
||||
g_pSound->RestartMusic();
|
||||
}
|
||||
else
|
||||
{
|
||||
char s[50];
|
||||
sprintf(s, "wParam=%d\n", wParam);
|
||||
OutputDebug(s);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case WM_SETCURSOR:
|
||||
// ChangeSprite();
|
||||
// SetCursor(NULL); // pas de souris visible !
|
||||
return TRUE;
|
||||
|
||||
case WM_LBUTTONDOWN:
|
||||
//? Benchmark();
|
||||
GetCursorPos(&mousePos);
|
||||
ScreenToClient(hWnd, &mousePos);
|
||||
break;
|
||||
|
||||
case WM_RBUTTONDOWN:
|
||||
break;
|
||||
|
||||
case WM_MOUSEMOVE:
|
||||
break;
|
||||
|
||||
case WM_KEYDOWN:
|
||||
switch (wParam)
|
||||
{
|
||||
case VK_F5:
|
||||
g_pEvent->SetSpeed(1);
|
||||
break;
|
||||
case VK_F6:
|
||||
g_pEvent->SetSpeed(2);
|
||||
break;
|
||||
case VK_F7:
|
||||
g_pEvent->SetSpeed(4);
|
||||
break;
|
||||
case VK_F8:
|
||||
g_pEvent->SetSpeed(8);
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case WM_DESTROY:
|
||||
#if MMTIMER
|
||||
timeKillEvent((UINT)g_updateTimer);
|
||||
#else
|
||||
KillTimer(g_hWnd, 1);
|
||||
#endif
|
||||
FinishObjects();
|
||||
PostQuitMessage(0);
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
}
|
||||
|
||||
void CALLBACK TimerStep(UINT wTimerID, UINT msg,
|
||||
DWORD dwUser, DWORD dw1, DWORD dw2)
|
||||
{
|
||||
if (g_bActive && g_timer == 0)
|
||||
{
|
||||
g_timer = 1;
|
||||
PostMessage(g_hWnd, WM_UPDATE, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
// Erreur dans DoInit.
|
||||
|
||||
BOOL InitFail(const char *msg, BOOL bDirectX)
|
||||
{
|
||||
char buffer[100];
|
||||
|
||||
if ( bDirectX ) strcpy(buffer, "DirectX Init FAILED\n(while ");
|
||||
else strcpy(buffer, "Error (");
|
||||
strcat(buffer, msg);
|
||||
strcat(buffer, ")");
|
||||
MessageBoxA(g_hWnd, buffer, TITLE, MB_OK);
|
||||
|
||||
FinishObjects();
|
||||
DestroyWindow(g_hWnd);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
int Benchmark()
|
||||
{
|
||||
struct timeb tstruct;
|
||||
int i, j, t1, t2, time;
|
||||
RECT rect;
|
||||
POINT dest;
|
||||
_MEMORYSTATUS mem;
|
||||
|
||||
ftime(&tstruct);
|
||||
t1 = tstruct.millitm;
|
||||
|
||||
for (j = 0; j < 10; j++)
|
||||
{
|
||||
UpdateFrame();
|
||||
SetDecor();
|
||||
g_pPixmap->Display();
|
||||
}
|
||||
|
||||
ftime(&tstruct);
|
||||
t2 = tstruct.millitm;
|
||||
|
||||
if (t1 > t2) t2 += 1000;
|
||||
time = t2 - t1;
|
||||
|
||||
mem.dwLength = 32;
|
||||
GlobalMemoryStatus(&mem);
|
||||
FILE* file = NULL;
|
||||
char string[100];
|
||||
sprintf(string, "CheckTime = %d Memory = %d\r\n", time, mem.dwTotalPhys);
|
||||
file = fopen("data\\time.blp", "wb");
|
||||
if (file == NULL) return time;
|
||||
fwrite(string, strlen(string), 1, file);
|
||||
fclose(file);
|
||||
|
||||
return time;
|
||||
}
|
||||
|
||||
static BOOL DoInit(HINSTANCE hInstance, LPSTR lpCmdLine, int nCmdShow)
|
||||
{
|
||||
WNDCLASSA wc;
|
||||
POINT totalDim, iconDim;
|
||||
RECT rcRect;
|
||||
BOOL bOK;
|
||||
|
||||
bOK = ReadConfig(lpCmdLine); // lit le fichier config.def
|
||||
|
||||
InitHInstance(hInstance);
|
||||
|
||||
// Set up and register window class.
|
||||
wc.style = CS_HREDRAW | CS_VREDRAW;
|
||||
wc.lpfnWndProc = WindowProc;
|
||||
wc.cbClsExtra = 0;
|
||||
wc.cbWndExtra = 0;
|
||||
wc.hInstance = hInstance;
|
||||
//? wc.hIcon = LoadIcon(hInstance, IDI_APPLICATION);
|
||||
wc.hIcon = LoadIcon(hInstance, "IDR_MAINFRAME");
|
||||
wc.hCursor = LoadCursor(hInstance, "IDC_POINTER");
|
||||
wc.hbrBackground = GetStockBrush(BLACK_BRUSH);
|
||||
wc.lpszMenuName = NAME;
|
||||
wc.lpszClassName = NAME;
|
||||
RegisterClass(&wc);
|
||||
|
||||
// Create a window.
|
||||
if (g_bFullScreen)
|
||||
{
|
||||
g_hWnd = CreateWindowEx
|
||||
(
|
||||
WS_EX_TOPMOST,
|
||||
NAME,
|
||||
TITLE,
|
||||
WS_POPUP,
|
||||
0, 0,
|
||||
GetSystemMetrics(SM_CXSCREEN),
|
||||
GetSystemMetrics(SM_CYSCREEN),
|
||||
NULL,
|
||||
NULL,
|
||||
hInstance,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
int sx, sy;
|
||||
RECT WindowRect;
|
||||
|
||||
sx = GetSystemMetrics(SM_CXSCREEN);
|
||||
sy = GetSystemMetrics(SM_CYSCREEN);
|
||||
|
||||
SetRect(&WindowRect, (sx - LXIMAGE) / 2, (sy - LYIMAGE) / 2,
|
||||
(sx + LXIMAGE) / 2, (sy + LYIMAGE) / 2);
|
||||
|
||||
#if _LEGACY
|
||||
// Old behavior is semantically incorrect.
|
||||
// The game window becomes too short on modern versions of Windows.
|
||||
AdjustWindowRect(&WindowRect, WS_POPUPWINDOW | WS_CAPTION, TRUE);
|
||||
WindowRect.top += GetSystemMetrics(SM_CYCAPTION);
|
||||
#else
|
||||
AdjustWindowRect(&WindowRect, WS_POPUPWINDOW | WS_CAPTION, FALSE);
|
||||
#endif
|
||||
|
||||
g_hWnd = CreateWindow
|
||||
(
|
||||
NAME,
|
||||
TITLE,
|
||||
WS_POPUPWINDOW | WS_CAPTION | WS_VISIBLE,
|
||||
(sx - LXIMAGE) / 2, (sy - LYIMAGE) / 2,
|
||||
WindowRect.right - WindowRect.left,
|
||||
WindowRect.bottom - WindowRect.top,
|
||||
HWND_DESKTOP,
|
||||
NULL,
|
||||
hInstance,
|
||||
NULL
|
||||
);
|
||||
}
|
||||
if (!g_hWnd) return FALSE;
|
||||
|
||||
ShowWindow(g_hWnd, nCmdShow);
|
||||
UpdateWindow(g_hWnd);
|
||||
SetFocus(g_hWnd);
|
||||
|
||||
ChangeSprite(SPRITE_WAIT); // met le sablier maison
|
||||
|
||||
if (!bOK) // config.def pas correct ?
|
||||
{
|
||||
return InitFail("Game not correctly installed", FALSE);
|
||||
}
|
||||
|
||||
// Crée le pixmap principal.
|
||||
g_pPixmap = new CPixmap;
|
||||
if (g_pPixmap == NULL) return InitFail("New pixmap", TRUE);
|
||||
|
||||
totalDim.x = LXIMAGE;
|
||||
totalDim.y = LYIMAGE;
|
||||
if (!g_pPixmap->Create(g_hWnd, totalDim, g_bFullScreen, g_mouseType, g_bTrueColorBack, g_bTrueColorDecor))
|
||||
return InitFail("Create pixmap", TRUE);
|
||||
|
||||
OutputDebug("Image: init\n");
|
||||
totalDim.x = LXIMAGE;
|
||||
totalDim.y = LYIMAGE;
|
||||
iconDim.x = 0;
|
||||
iconDim.y = 0;
|
||||
|
||||
if (!g_pPixmap->CacheAll(TRUE, g_hWnd, g_bFullScreen, g_bTrueColorBack, g_bTrueColorDecor, g_mouseType, "init.blp", 0))
|
||||
return FALSE;
|
||||
OutputDebug("SavePalette\n");
|
||||
g_pPixmap->SavePalette();
|
||||
OutputDebug("InitSysPalette\n");
|
||||
g_pPixmap->InitSysPalette();
|
||||
|
||||
g_pSound = new CSound;
|
||||
if (g_pSound == NULL) return InitFail("New sound", TRUE);
|
||||
|
||||
g_pSound->Create(g_hWnd);
|
||||
g_pSound->CacheAll();
|
||||
g_pSound->SetState(TRUE);
|
||||
g_pSound->SetCDAudio(g_bCDAudio);
|
||||
|
||||
g_pNetwork = new CNetwork;
|
||||
if (g_pNetwork == NULL) return InitFail("New network", TRUE);
|
||||
|
||||
g_pNetwork->CreateProvider(0);
|
||||
|
||||
g_pMovie = new CMovie;
|
||||
if (g_pMovie == NULL) return InitFail("New movie", FALSE);
|
||||
|
||||
g_pMovie->Create();
|
||||
|
||||
g_pDecor = new CDecor;
|
||||
if (g_pDecor == NULL) return InitFail("New decor", FALSE);
|
||||
|
||||
g_pDecor->Create(g_hWnd, g_pSound, g_pPixmap, g_pNetwork);
|
||||
|
||||
g_pEvent = new CEvent;
|
||||
if (g_pEvent == NULL) return InitFail("New event", FALSE);
|
||||
|
||||
g_pEvent->Create(hInstance, g_hWnd, g_pPixmap, g_pDecor, g_pSound, g_pNetwork, g_pMovie);
|
||||
g_pEvent->SetFullScreen(g_bFullScreen);
|
||||
g_pEvent->SetMouseType(g_mouseType);
|
||||
|
||||
#if _INTRO
|
||||
g_pEvent->ChangePhase(WM_PHASE_INTRO1);
|
||||
#else
|
||||
g_pEvent->ChangePhase(WM_PHASE_INIT);
|
||||
#endif
|
||||
|
||||
g_bTermInit = TRUE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,
|
||||
LPSTR lpCmdLine, int nCmdShow)
|
||||
{
|
||||
MSG msg;
|
||||
LPTIMECALLBACK timeStep;
|
||||
|
||||
if ( !DoInit(hInstance, lpCmdLine, nCmdShow) )
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
Benchmark();
|
||||
|
||||
#if MMTIMER
|
||||
g_updateTimer = timeSetEvent(g_timerInterval, g_timerInterval / 4, TimerStep, NULL, TIME_PERIODIC);
|
||||
#else
|
||||
SetTimer(g_hWnd, 1, g_timerInterval, NULL);
|
||||
#endif
|
||||
|
||||
#if THREAD
|
||||
g_hScreenMutex = CreateMutex(NULL, FALSE, NULL);
|
||||
g_hRunMutex = CreateMutex(NULL, TRUE, NULL);
|
||||
g_threadNr = 0;
|
||||
|
||||
g_hThread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)ThreadDisplay, 0, DETACHED_PROCESS, &g_threadID);
|
||||
#endif
|
||||
|
||||
while ( TRUE )
|
||||
{
|
||||
if ( PeekMessage(&msg, NULL, 0,0, PM_NOREMOVE) )
|
||||
{
|
||||
if ( !GetMessage(&msg, NULL, 0, 0) )
|
||||
{
|
||||
return msg.wParam;
|
||||
}
|
||||
TranslateMessage(&msg);
|
||||
DispatchMessage(&msg);
|
||||
}
|
||||
else
|
||||
{
|
||||
// make sure we go to sleep if we have nothing else to do
|
||||
if ( !g_bActive ) WaitMessage();
|
||||
}
|
||||
}
|
||||
|
||||
return msg.wParam;
|
||||
}
|
||||
|
||||
#if THREAD
|
||||
// Thread d'affichage.
|
||||
|
||||
static void ThreadDisplay(char* MyID)
|
||||
{
|
||||
UINT phase;
|
||||
|
||||
do
|
||||
{
|
||||
phase = g_pEvent->GetPhase();
|
||||
if (phase == WM_PHASE_PLAY)
|
||||
{
|
||||
// Wait for display to be available, then lock it.
|
||||
WaitForSingleObject(g_hScreenMutex, INFINITE);
|
||||
|
||||
SetDecor();
|
||||
g_pPixmap->Display();
|
||||
|
||||
// Clear screen lock.
|
||||
ReleaseMutex(g_hScreenMutex);
|
||||
}
|
||||
}
|
||||
// Repeat while RunMutex is still taken.
|
||||
while (WaitForSingleObject(g_hRunMutex, 10L) == WAIT_TIMEOUT);
|
||||
}
|
||||
#endif
|
392
src/button.cpp
Normal file
@ -0,0 +1,392 @@
|
||||
// Button.cpp
|
||||
//
|
||||
|
||||
//#include <windows.h>
|
||||
//#include <stdlib.h>
|
||||
//#include <stdio.h>
|
||||
//#include <ddraw.h>
|
||||
|
||||
#ifndef POINT
|
||||
#include <windows.h>
|
||||
#endif
|
||||
|
||||
#include "button.h"
|
||||
#include "misc.h"
|
||||
#include "def.h"
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
|
||||
//////////////////////////////////////////////////////////
|
||||
|
||||
// Constructor
|
||||
|
||||
CButton::CButton()
|
||||
{
|
||||
m_type = 0;
|
||||
m_bEnable = TRUE;
|
||||
m_bHide = FALSE;
|
||||
m_bLocked = FALSE;
|
||||
m_state = 0;
|
||||
m_mouseState = 0;
|
||||
m_nbMenu = 0;
|
||||
m_nbToolTips = 0;
|
||||
m_selMenu = 0;
|
||||
m_bMouseDown = FALSE;
|
||||
m_bMinimizeRedraw = FALSE;
|
||||
m_bRedraw = FALSE;
|
||||
}
|
||||
|
||||
// Destructor
|
||||
|
||||
CButton::~CButton()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
// Create a new Button
|
||||
|
||||
BOOL CButton::Create(HWND hWnd, CPixmap *pPixmap, CSound *pSound,
|
||||
POINT pos, int type, BOOL bMinimizeRedraw, UINT message)
|
||||
{
|
||||
POINT iconDim;
|
||||
int i, icon;
|
||||
|
||||
static int ttypes[] =
|
||||
{
|
||||
DIMBUTTONX,DIMBUTTONY,
|
||||
};
|
||||
|
||||
if (type < 0 || type > 0) return FALSE;
|
||||
|
||||
|
||||
iconDim.x = ttypes[type * 2 + 0];
|
||||
iconDim.y = ttypes[type * 2 + 1];
|
||||
|
||||
m_hWnd = hWnd;
|
||||
m_pPixmap = pPixmap;
|
||||
m_pSound = pSound;
|
||||
m_type = type;
|
||||
m_bMinimizeRedraw = bMinimizeRedraw;
|
||||
m_bEnable = TRUE;
|
||||
m_bHide = FALSE;
|
||||
m_bLocked = FALSE;
|
||||
m_message = message;
|
||||
m_pos.x = pos.x;
|
||||
m_pos.y = pos.y;
|
||||
m_dim.x = iconDim.x;
|
||||
m_dim.y = iconDim.y;
|
||||
m_nbMenu = 0;
|
||||
m_nbToolTips = 0;
|
||||
m_selMenu = 0;
|
||||
m_state = 0;
|
||||
m_mouseState = 0;
|
||||
m_bMouseDown = FALSE;
|
||||
m_bRedraw = TRUE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void CButton::SetIconMenu(int* pIcons, int nbMenu)
|
||||
{
|
||||
for (int i = 0; i < nbMenu; i++)
|
||||
{
|
||||
m_iconMenu[i] = pIcons[i];
|
||||
}
|
||||
m_nbMenu = nbMenu;
|
||||
}
|
||||
|
||||
void CButton::SetToolTips(int* pToolTips, int nbToolTips)
|
||||
{
|
||||
for (int i = 0; i < nbToolTips; i++)
|
||||
{
|
||||
m_toolTips[i] = pToolTips[i];
|
||||
}
|
||||
m_nbToolTips = nbToolTips;
|
||||
}
|
||||
|
||||
// Draw a button in its state
|
||||
|
||||
void CButton::Draw()
|
||||
{
|
||||
int i;
|
||||
POINT pos;
|
||||
RECT rect;
|
||||
|
||||
if (m_bMinimizeRedraw && !m_bRedraw) return;
|
||||
m_bRedraw = FALSE;
|
||||
|
||||
if (m_bHide) // Hidden button
|
||||
{
|
||||
pos = m_pos;
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_bEnable)
|
||||
{
|
||||
m_pPixmap->DrawIcon(-1, CHBUTTON + m_type, m_mouseState, m_pos);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_pPixmap->DrawIcon(-1, CHBUTTON + m_type, m_bLocked ? 5 : 4, m_pos);
|
||||
}
|
||||
|
||||
if (m_nbMenu == 0) return;
|
||||
|
||||
pos = m_pos;
|
||||
if (m_nbMenu > 0)
|
||||
{
|
||||
m_pPixmap->DrawIcon(-1, CHBUTTON + m_type,
|
||||
m_iconMenu[m_selMenu] + 6, pos);
|
||||
}
|
||||
|
||||
if (m_nbMenu == 1 || !m_bEnable || !m_bMouseDown) return;
|
||||
|
||||
pos = m_pos;
|
||||
pos.x += m_dim.x + 2;
|
||||
for (i = 0; i<m_nbMenu; i++)
|
||||
{
|
||||
m_pPixmap->DrawIcon(-1, CHBUTTON + m_type, i == m_selMenu ? 1 : 0, pos);
|
||||
m_pPixmap->DrawIcon(-1, CHBUTTON + m_type, m_iconMenu[i] + 6, pos);
|
||||
pos.x += m_dim.x - 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/Needed Yet?
|
||||
//////////////////////////////////////////////
|
||||
void CButton::Redraw()
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
//////////////////////////////////////////////
|
||||
*/
|
||||
|
||||
int CButton::GetState()
|
||||
{
|
||||
return m_state;
|
||||
}
|
||||
|
||||
void CButton::SetState(int state)
|
||||
{
|
||||
if (m_state != state ||
|
||||
m_mouseState != state)
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_state = state;
|
||||
m_mouseState = state;
|
||||
}
|
||||
|
||||
int CButton::GetMenu()
|
||||
{
|
||||
return m_selMenu;
|
||||
}
|
||||
|
||||
void CButton::SetMenu(int menu)
|
||||
{
|
||||
if (m_selMenu != menu)
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_selMenu = menu;
|
||||
}
|
||||
|
||||
void CButton::SetEnable(BOOL bEnable)
|
||||
{
|
||||
if (m_bEnable != bEnable)
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_bEnable = bEnable;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
// Needed Yet?
|
||||
/////////////////////////////////////////
|
||||
BOOL CButton::GetHide()
|
||||
{
|
||||
return m_bHide;
|
||||
}
|
||||
/////////////////////////////////////////
|
||||
*/
|
||||
|
||||
|
||||
void CButton::SetHide(BOOL bHide)
|
||||
{
|
||||
if (m_bHide != bHide)
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_bHide = bHide;
|
||||
}
|
||||
|
||||
BOOL CButton::TreatEvent(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
POINT pos;
|
||||
|
||||
if (m_bHide || !m_bEnable) return FALSE;
|
||||
|
||||
pos = ConvLongToPos(lParam);
|
||||
|
||||
switch (message)
|
||||
{
|
||||
case WM_LBUTTONDOWN:
|
||||
case WM_RBUTTONDOWN:
|
||||
if (MouseDown(pos)) return TRUE;
|
||||
break;
|
||||
|
||||
case WM_MOUSEMOVE:
|
||||
if (MouseMove(pos)) return TRUE;
|
||||
break;
|
||||
|
||||
case WM_LBUTTONUP:
|
||||
case WM_RBUTTONUP:
|
||||
if (MouseUp(pos)) return FALSE;
|
||||
break;
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
// All buttons must receive the BUTTONUP event!
|
||||
|
||||
// Indicates whether the mouse is over this button.
|
||||
|
||||
BOOL CButton::MouseOnButton(POINT pos)
|
||||
{
|
||||
return Detect(pos);
|
||||
}
|
||||
|
||||
// Return the tooltips for a button, depending
|
||||
// on mouse position.
|
||||
|
||||
int CButton::GetToolTips(POINT pos)
|
||||
{
|
||||
int width = m_dim.x;
|
||||
int rank;
|
||||
|
||||
if (m_bHide || !m_bEnable) return -1;
|
||||
|
||||
if (m_nbMenu > 1 && m_bMouseDown) // Drop-down submenu?
|
||||
{
|
||||
width += 2 + (m_dim.x - 1)*m_nbMenu;
|
||||
}
|
||||
|
||||
if (pos.x < m_pos.x ||
|
||||
pos.x > m_pos.x + width ||
|
||||
pos.y < m_pos.y ||
|
||||
pos.y > m_pos.y + m_dim.y) return -1;
|
||||
|
||||
rank = (pos.x = -(m_pos.x + 2 + 1)) / (m_dim.x - 1);
|
||||
if (rank < 0) rank = 0;
|
||||
if (rank > m_nbToolTips) return -1;
|
||||
|
||||
if (m_nbMenu > 1)
|
||||
{
|
||||
if (m_bMouseDown && rank > 0)
|
||||
{
|
||||
rank--;
|
||||
}
|
||||
else
|
||||
{
|
||||
rank = m_selMenu;
|
||||
}
|
||||
}
|
||||
|
||||
return m_toolTips[rank];
|
||||
}
|
||||
|
||||
BOOL CButton::Detect(POINT pos)
|
||||
{
|
||||
int width = m_dim.x;
|
||||
|
||||
if (m_bHide || !m_bEnable) return FALSE;
|
||||
|
||||
if (m_nbMenu > 1 && m_bMouseDown)
|
||||
{
|
||||
width += 2 + (m_dim.x - 1)*m_nbMenu;
|
||||
}
|
||||
|
||||
if (pos.x < m_pos.x ||
|
||||
pos.x > m_pos.x + width ||
|
||||
pos.y < m_pos.y ||
|
||||
pos.y > m_pos.y + m_dim.y) return FALSE;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CButton::MouseMove(POINT pos)
|
||||
{
|
||||
int selMenu = m_selMenu;
|
||||
int mouseState;
|
||||
BOOL BVar3;
|
||||
int iVar4;
|
||||
int iVar5;
|
||||
BOOL BVar6;
|
||||
int iVar7;
|
||||
|
||||
mouseState = m_mouseState;
|
||||
BVar6 = Detect(pos);
|
||||
BVar3 = m_bMouseDown;
|
||||
if (!m_bMouseDown) {
|
||||
if (!Detect(pos)) {
|
||||
m_mouseState = m_state;
|
||||
}
|
||||
else {
|
||||
m_mouseState = m_state + 2;
|
||||
}
|
||||
}
|
||||
else if (Detect(pos)) {
|
||||
m_mouseState = 1;
|
||||
}
|
||||
else {
|
||||
m_mouseState = m_state;
|
||||
}
|
||||
if (m_nbMenu > 1 && m_bMouseDown) {
|
||||
if ((m_pos.x + m_dim.x + 2 < pos.x))
|
||||
{
|
||||
m_selMenu = (pos.x - m_pos.x - m_dim.x - 2) / (m_dim.x - 1);
|
||||
if (m_selMenu >= m_nbMenu) m_selMenu = m_nbMenu - 1;
|
||||
}
|
||||
}
|
||||
if (mouseState != m_mouseState || selMenu != m_selMenu) m_bRedraw = TRUE;
|
||||
return BVar3;
|
||||
}
|
||||
|
||||
|
||||
BOOL CButton::MouseDown(POINT pos)
|
||||
{
|
||||
if (!Detect(pos)) return FALSE;
|
||||
|
||||
m_mouseState = 1;
|
||||
m_bMouseDown = TRUE;
|
||||
m_bRedraw = TRUE;
|
||||
// PostMessage(m_hWnd, WM_UPDATE, 0, 0);
|
||||
|
||||
m_pSound->PlayImage(SOUND_CLICK, pos);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CButton::MouseUp(POINT pos)
|
||||
{
|
||||
BOOL bDetect;
|
||||
|
||||
bDetect = Detect(pos);
|
||||
|
||||
m_mouseState = m_state;
|
||||
m_bMouseDown = FALSE;
|
||||
m_bRedraw = TRUE;
|
||||
|
||||
if (!bDetect) return FALSE;
|
||||
|
||||
if (m_message != -1)
|
||||
{
|
||||
PostMessage(m_hWnd, m_message, 0, 0);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
70
src/button.h
Normal file
@ -0,0 +1,70 @@
|
||||
#ifndef BUTTON_H
|
||||
#define BUTTON_H
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
#include "decor.h"
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
|
||||
class CButton
|
||||
{
|
||||
public:
|
||||
CButton();
|
||||
~CButton();
|
||||
|
||||
BOOL Create(HWND hWnd, CPixmap *pPixmap, CSound *pSound,
|
||||
POINT pos, int type, BOOL bMinimizeRedraw, UINT message);
|
||||
void SetIconMenu(int* pIcons, int nbIcons);
|
||||
void SetToolTips(int* pToolTips, int nbTooltips);
|
||||
void Draw();
|
||||
void Redraw();
|
||||
|
||||
int GetState();
|
||||
void SetState(int state);
|
||||
|
||||
int GetMenu();
|
||||
void SetMenu(int menu);
|
||||
|
||||
BOOL GetEnable();
|
||||
void SetEnable(BOOL bEnable);
|
||||
|
||||
BOOL GetHide();
|
||||
void SetHide(BOOL bHide);
|
||||
|
||||
BOOL TreatEvent(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
BOOL MouseOnButton(POINT pos);
|
||||
int GetToolTips(POINT pos);
|
||||
|
||||
|
||||
protected:
|
||||
BOOL Detect(POINT pos);
|
||||
BOOL MouseDown(POINT pos);
|
||||
BOOL MouseMove(POINT pos);
|
||||
BOOL MouseUp(POINT pos);
|
||||
|
||||
protected:
|
||||
HWND m_hWnd;
|
||||
CPixmap* m_pPixmap;
|
||||
CDecor* m_pDecor;
|
||||
CSound* m_pSound;
|
||||
int m_type; // type de bouton
|
||||
BOOL m_bEnable; // TRUE si bouton actif
|
||||
int m_bLocked;
|
||||
BOOL m_bHide; // TRUE si bouton caché
|
||||
UINT m_message; // message envoyé si bouton actionné
|
||||
POINT m_pos; // coin sup/gauche
|
||||
POINT m_dim; // dimensions
|
||||
int m_state;
|
||||
int m_mouseState;
|
||||
int m_iconMenu[20]; // icônes du sous-menu
|
||||
int m_toolTips[20]; // info-bulles
|
||||
int m_nbMenu; // nb de case du sous-menu
|
||||
int m_nbToolTips; // nb d'info-bulles
|
||||
int m_selMenu;
|
||||
BOOL m_bMouseDown; // TRUE -> bouton souris pressé
|
||||
BOOL m_bMinimizeRedraw;
|
||||
BOOL m_bRedraw;
|
||||
};
|
||||
|
||||
#endif
|
342
src/ddutil.cpp
Normal file
@ -0,0 +1,342 @@
|
||||
/*==========================================================================
|
||||
*
|
||||
* Copyright (C) 1995-1997 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: ddutil.cpp
|
||||
* Content: Routines for loading bitmap and palettes from resources
|
||||
*
|
||||
***************************************************************************/
|
||||
#undef WIN32_LEAN_AND_MEAN
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <windows.h>
|
||||
#include <windowsx.h>
|
||||
#include <ddraw.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include "ddutil.h"
|
||||
#include "misc.h"
|
||||
|
||||
BOOL g_bDebug = TRUE;
|
||||
|
||||
void DDSetDebug(BOOL bDebug)
|
||||
{
|
||||
g_bDebug = bDebug;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* DDLoadBitmap
|
||||
*
|
||||
* create a DirectDrawSurface from a bitmap resource.
|
||||
*
|
||||
*/
|
||||
extern "C" IDirectDrawSurface * DDLoadBitmap(IDirectDraw *pdd, LPCSTR szBitmap, int dx, int dy)
|
||||
{
|
||||
HBITMAP hbm;
|
||||
BITMAP bm;
|
||||
DDSURFACEDESC ddsd;
|
||||
IDirectDrawSurface *pdds;
|
||||
|
||||
//
|
||||
// try to load the bitmap as a resource, if that fails, try it as a file
|
||||
//
|
||||
hbm = (HBITMAP)LoadImageA(GetModuleHandle(NULL), szBitmap, IMAGE_BITMAP, dx, dy, LR_CREATEDIBSECTION);
|
||||
|
||||
if (hbm == NULL)
|
||||
hbm = (HBITMAP)LoadImageA(NULL, szBitmap, IMAGE_BITMAP, dx, dy, LR_LOADFROMFILE|LR_CREATEDIBSECTION);
|
||||
|
||||
if (hbm == NULL)
|
||||
return NULL;
|
||||
|
||||
//
|
||||
// get size of the bitmap
|
||||
//
|
||||
GetObject(hbm, sizeof(bm), &bm); // get size of bitmap
|
||||
|
||||
//
|
||||
// create a DirectDrawSurface for this bitmap
|
||||
//
|
||||
ZeroMemory(&ddsd, sizeof(ddsd));
|
||||
ddsd.dwSize = sizeof(ddsd);
|
||||
ddsd.dwFlags = DDSD_CAPS | DDSD_HEIGHT |DDSD_WIDTH;
|
||||
ddsd.ddsCaps.dwCaps = DDSCAPS_OFFSCREENPLAIN;
|
||||
ddsd.dwWidth = bm.bmWidth;
|
||||
ddsd.dwHeight = bm.bmHeight;
|
||||
|
||||
if (pdd->CreateSurface(&ddsd, &pdds, NULL) != DD_OK)
|
||||
return NULL;
|
||||
|
||||
DDCopyBitmap(pdds, hbm, 0, 0, 0, 0);
|
||||
|
||||
DeleteObject(hbm);
|
||||
|
||||
return pdds;
|
||||
}
|
||||
|
||||
/*
|
||||
* DDReLoadBitmap
|
||||
*
|
||||
* load a bitmap from a file or resource into a directdraw surface.
|
||||
* normaly used to re-load a surface after a restore.
|
||||
*
|
||||
*/
|
||||
HRESULT DDReLoadBitmap(IDirectDrawSurface *pdds, LPCSTR szBitmap)
|
||||
{
|
||||
HBITMAP hbm;
|
||||
HRESULT hr;
|
||||
|
||||
//
|
||||
// try to load the bitmap as a resource, if that fails, try it as a file
|
||||
//
|
||||
hbm = (HBITMAP)LoadImageA(GetModuleHandle(NULL), szBitmap, IMAGE_BITMAP, 0, 0, LR_CREATEDIBSECTION);
|
||||
|
||||
if (hbm == NULL)
|
||||
hbm = (HBITMAP)LoadImageA(NULL, szBitmap, IMAGE_BITMAP, 0, 0, LR_LOADFROMFILE|LR_CREATEDIBSECTION);
|
||||
|
||||
if (hbm == NULL)
|
||||
{
|
||||
OutputDebugStringA("handle is null\n");
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
hr = DDCopyBitmap(pdds, hbm, 0, 0, 0, 0);
|
||||
if (hr != DD_OK)
|
||||
{
|
||||
OutputDebugStringA("ddcopybitmap failed\n");
|
||||
}
|
||||
|
||||
|
||||
DeleteObject(hbm);
|
||||
return hr;
|
||||
}
|
||||
|
||||
/*
|
||||
* DDCopyBitmap
|
||||
*
|
||||
* draw a bitmap into a DirectDrawSurface
|
||||
*
|
||||
*/
|
||||
extern "C" HRESULT DDCopyBitmap(IDirectDrawSurface *pdds, HBITMAP hbm, int x, int y, int dx, int dy)
|
||||
{
|
||||
HDC hdcImage;
|
||||
HDC hdc;
|
||||
BITMAP bm;
|
||||
DDSURFACEDESC ddsd;
|
||||
HRESULT hr;
|
||||
|
||||
if (hbm == NULL || pdds == NULL)
|
||||
return E_FAIL;
|
||||
|
||||
//
|
||||
// make sure this surface is restored.
|
||||
//
|
||||
pdds->Restore();
|
||||
|
||||
//
|
||||
// select bitmap into a memoryDC so we can use it.
|
||||
//
|
||||
hdcImage = CreateCompatibleDC(NULL);
|
||||
if (!hdcImage)
|
||||
OutputDebugStringA("createcompatible dc failed\n");
|
||||
SelectObject(hdcImage, hbm);
|
||||
|
||||
//
|
||||
// get size of the bitmap
|
||||
//
|
||||
GetObject(hbm, sizeof(bm), &bm); // get size of bitmap
|
||||
dx = dx == 0 ? bm.bmWidth : dx; // use the passed size, unless zero
|
||||
dy = dy == 0 ? bm.bmHeight : dy;
|
||||
|
||||
//
|
||||
// get size of surface.
|
||||
//
|
||||
ddsd.dwSize = sizeof(ddsd);
|
||||
ddsd.dwFlags = DDSD_HEIGHT | DDSD_WIDTH;
|
||||
pdds->GetSurfaceDesc(&ddsd);
|
||||
|
||||
if ((hr = pdds->GetDC(&hdc)) == DD_OK)
|
||||
{
|
||||
StretchBlt(hdc, 0, 0, ddsd.dwWidth, ddsd.dwHeight, hdcImage, x, y, dx, dy, SRCCOPY);
|
||||
pdds->ReleaseDC(hdc);
|
||||
}
|
||||
|
||||
DeleteDC(hdcImage);
|
||||
|
||||
return hr;
|
||||
}
|
||||
|
||||
//
|
||||
// DDLoadPalette
|
||||
//
|
||||
// Create a DirectDraw palette object from a bitmap resoure
|
||||
//
|
||||
// if the resource does not exist or NULL is passed create a
|
||||
// default 332 palette.
|
||||
//
|
||||
extern "C" IDirectDrawPalette * DDLoadPalette(IDirectDraw *pdd, LPCSTR szBitmap)
|
||||
{
|
||||
IDirectDrawPalette* ddpal;
|
||||
int i;
|
||||
int n;
|
||||
int fh;
|
||||
HRSRC h;
|
||||
LPBITMAPINFOHEADER lpbi;
|
||||
PALETTEENTRY ape[256];
|
||||
RGBQUAD * prgb;
|
||||
|
||||
//
|
||||
// build a 332 palette as the default.
|
||||
//
|
||||
for (i=0; i<256; i++)
|
||||
{
|
||||
ape[i].peRed = (BYTE)(((i >> 5) & 0x07) * 255 / 7);
|
||||
ape[i].peGreen = (BYTE)(((i >> 2) & 0x07) * 255 / 7);
|
||||
ape[i].peBlue = (BYTE)(((i >> 0) & 0x03) * 255 / 3);
|
||||
ape[i].peFlags = (BYTE)0;
|
||||
}
|
||||
|
||||
//
|
||||
// get a pointer to the bitmap resource.
|
||||
//
|
||||
if (szBitmap && (h = FindResourceA(NULL, szBitmap, (LPCSTR)RT_BITMAP)))
|
||||
{
|
||||
lpbi = (LPBITMAPINFOHEADER)LockResource(LoadResource(NULL, h));
|
||||
if (!lpbi)
|
||||
OutputDebugStringA("lock resource failed\n");
|
||||
prgb = (RGBQUAD*)((BYTE*)lpbi + lpbi->biSize);
|
||||
|
||||
if (lpbi == NULL || lpbi->biSize < sizeof(BITMAPINFOHEADER))
|
||||
n = 0;
|
||||
else if (lpbi->biBitCount > 8)
|
||||
n = 0;
|
||||
else if (lpbi->biClrUsed == 0)
|
||||
n = 1 << lpbi->biBitCount;
|
||||
else
|
||||
n = lpbi->biClrUsed;
|
||||
|
||||
//
|
||||
// a DIB color table has its colors stored BGR not RGB
|
||||
// so flip them around.
|
||||
//
|
||||
for(i=0; i<n; i++ )
|
||||
{
|
||||
ape[i].peRed = prgb[i].rgbRed;
|
||||
ape[i].peGreen = prgb[i].rgbGreen;
|
||||
ape[i].peBlue = prgb[i].rgbBlue;
|
||||
ape[i].peFlags = 0;
|
||||
}
|
||||
}
|
||||
else if (szBitmap && (fh = _lopen(szBitmap, OF_READ)) != -1)
|
||||
{
|
||||
BITMAPFILEHEADER bf;
|
||||
BITMAPINFOHEADER bi;
|
||||
|
||||
_lread(fh, &bf, sizeof(bf));
|
||||
_lread(fh, &bi, sizeof(bi));
|
||||
_lread(fh, ape, sizeof(ape));
|
||||
_lclose(fh);
|
||||
|
||||
if (bi.biSize != sizeof(BITMAPINFOHEADER))
|
||||
n = 0;
|
||||
else if (bi.biBitCount > 8)
|
||||
n = 0;
|
||||
else if (bi.biClrUsed == 0)
|
||||
n = 1 << bi.biBitCount;
|
||||
else
|
||||
n = bi.biClrUsed;
|
||||
|
||||
//
|
||||
// a DIB color table has its colors stored BGR not RGB
|
||||
// so flip them around.
|
||||
//
|
||||
for(i=0; i<n; i++ )
|
||||
{
|
||||
BYTE r = ape[i].peRed;
|
||||
ape[i].peRed = ape[i].peBlue;
|
||||
ape[i].peBlue = r;
|
||||
}
|
||||
}
|
||||
|
||||
pdd->CreatePalette(DDPCAPS_8BIT, ape, &ddpal, NULL);
|
||||
|
||||
return ddpal;
|
||||
}
|
||||
|
||||
/*
|
||||
* DDColorMatch
|
||||
*
|
||||
* convert a RGB color to a pysical color.
|
||||
*
|
||||
* we do this by leting GDI SetPixel() do the color matching
|
||||
* then we lock the memory and see what it got mapped to.
|
||||
*/
|
||||
extern "C" DWORD DDColorMatch(IDirectDrawSurface *pdds, COLORREF rgb)
|
||||
{
|
||||
COLORREF rgbT;
|
||||
HDC hdc;
|
||||
DWORD dw = CLR_INVALID;
|
||||
DDSURFACEDESC ddsd;
|
||||
HRESULT hres;
|
||||
|
||||
//
|
||||
// use GDI SetPixel to color match for us
|
||||
//
|
||||
if (rgb != CLR_INVALID && pdds->GetDC(&hdc) == DD_OK)
|
||||
{
|
||||
rgbT = GetPixel(hdc, 0, 0); // save current pixel value
|
||||
SetPixel(hdc, 0, 0, rgb); // set our value
|
||||
pdds->ReleaseDC(hdc);
|
||||
}
|
||||
|
||||
//
|
||||
// now lock the surface so we can read back the converted color
|
||||
//
|
||||
ddsd.dwSize = sizeof(ddsd);
|
||||
while ((hres = pdds->Lock(NULL, &ddsd, 0, NULL)) == DDERR_WASSTILLDRAWING)
|
||||
;
|
||||
|
||||
if (hres == DD_OK)
|
||||
{
|
||||
dw = *(DWORD *)ddsd.lpSurface; // get DWORD
|
||||
if(ddsd.ddpfPixelFormat.dwRGBBitCount < 32)
|
||||
dw &= (1 << ddsd.ddpfPixelFormat.dwRGBBitCount)-1; // mask it to bpp
|
||||
pdds->Unlock(NULL);
|
||||
}
|
||||
|
||||
//
|
||||
// now put the color that was there back.
|
||||
//
|
||||
if (rgb != CLR_INVALID && pdds->GetDC(&hdc) == DD_OK)
|
||||
{
|
||||
SetPixel(hdc, 0, 0, rgbT);
|
||||
pdds->ReleaseDC(hdc);
|
||||
}
|
||||
|
||||
return dw;
|
||||
}
|
||||
|
||||
/*
|
||||
* DDSetColorKey
|
||||
*
|
||||
* set a color key for a surface, given a RGB.
|
||||
* if you pass CLR_INVALID as the color key, the pixel
|
||||
* in the upper-left corner will be used.
|
||||
*/
|
||||
extern "C" HRESULT DDSetColorKey(IDirectDrawSurface *pdds, COLORREF rgb)
|
||||
{
|
||||
DDCOLORKEY ddck;
|
||||
|
||||
ddck.dwColorSpaceLowValue = DDColorMatch(pdds, rgb);
|
||||
ddck.dwColorSpaceHighValue = ddck.dwColorSpaceLowValue;
|
||||
return pdds->SetColorKey(DDCKEY_SRCBLT, &ddck);
|
||||
}
|
||||
|
||||
extern "C" HRESULT DDSetColorKey2(IDirectDrawSurface* pdds, COLORREF rgb1,
|
||||
COLORREF rgb2)
|
||||
{
|
||||
DDCOLORKEY ddck;
|
||||
|
||||
ddck.dwColorSpaceLowValue = DDColorMatch(pdds, rgb1);
|
||||
ddck.dwColorSpaceHighValue = DDColorMatch(pdds, rgb2);
|
||||
return pdds->SetColorKey(DDCKEY_SRCBLT, &ddck);
|
||||
}
|
33
src/ddutil.h
Normal file
@ -0,0 +1,33 @@
|
||||
#ifndef DDUTIL_H
|
||||
#define DDUTIL_H
|
||||
/*==========================================================================
|
||||
*
|
||||
* Copyright (C) 1995 Microsoft Corporation. All Rights Reserved.
|
||||
*
|
||||
* File: ddutil.cpp
|
||||
* Content: Routines for loading bitmap and palettes from resources
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
#define DIRECTDRAW_VERSION 0x0500
|
||||
|
||||
#include <ddraw.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" { /* Assume C declarations for C++ */
|
||||
#endif /* __cplusplus */
|
||||
|
||||
extern void DDSetDebug(BOOL bDebug);
|
||||
extern IDirectDrawPalette * DDLoadPalette(IDirectDraw *pdd, LPCSTR szBitmap);
|
||||
extern IDirectDrawSurface * DDLoadBitmap(IDirectDraw *pdd, LPCSTR szBitmap, int dx, int dy);
|
||||
extern HRESULT DDReLoadBitmap(IDirectDrawSurface *pdds, LPCSTR szBitmap);
|
||||
extern HRESULT DDCopyBitmap(IDirectDrawSurface *pdds, HBITMAP hbm, int x, int y, int dx, int dy);
|
||||
extern DWORD DDColorMatch(IDirectDrawSurface *pdds, COLORREF rgb);
|
||||
extern HRESULT DDSetColorKey(IDirectDrawSurface *pdds, COLORREF rgb);
|
||||
extern HRESULT DDSetColorKey2(IDirectDrawSurface* pdds, COLORREF rgb1, COLORREF rgb2);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif
|
802
src/decblock.cpp
Normal file
@ -0,0 +1,802 @@
|
||||
// DecBlock.cpp
|
||||
//
|
||||
|
||||
#include "def.h"
|
||||
#include "decor.h"
|
||||
#include "misc.h"
|
||||
#include "obstacle.h"
|
||||
#include "dectables.h"
|
||||
|
||||
BOOL CDecor::BlitzActif(POINT cel)
|
||||
{
|
||||
if (m_phase == WM_PHASE_BUILD) {
|
||||
//TODO: rewrite this like a human
|
||||
int foo = m_time >> 31;
|
||||
return 1 - (((m_time ^ foo) - foo & 1 ^ foo) == foo);
|
||||
}
|
||||
|
||||
POINT pos = { cel.x * DIMOBJX, cel.y * DIMOBJY };
|
||||
|
||||
int num = m_time % 100;
|
||||
|
||||
if (m_blupiPos.x >= pos.x - 80 && m_blupiPos.x <= pos.x + 80 &&
|
||||
m_blupiPos.y >= pos.y - 500 && m_blupiPos.y <= pos.y + 500)
|
||||
{
|
||||
if (m_time % 100 < 70 && cel.y > 0 && m_decor[cel.x][cel.y - 1].icon == 0x130)
|
||||
{
|
||||
PlaySound(SOUND_BLITZ, pos, 0);
|
||||
}
|
||||
|
||||
for (int i = 0; table_blitz[i] != -1; i++)
|
||||
{
|
||||
if (m_time % 100 == i) return TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
int CDecor::SoundEnviron(int sound, int obstacle)
|
||||
{
|
||||
if ((obstacle >= 32 && obstacle <= 34) || (obstacle >= 41 && obstacle <= 47) || (obstacle >= 139 && obstacle <= 143))
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 79;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 78;
|
||||
}
|
||||
}
|
||||
if ((obstacle >= 1 && obstacle <= 28) || (obstacle >= 78 && obstacle <= 90) || (obstacle >= 250 && obstacle <= 260) || (obstacle >= 311 && obstacle <= 316) || (obstacle >= 324 && obstacle <= 329))
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 81;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 80;
|
||||
}
|
||||
}
|
||||
if ((obstacle >= 284 && obstacle <= 303) || obstacle == 338)
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 83;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 82;
|
||||
}
|
||||
}
|
||||
if (obstacle >= 341 && obstacle <= 363)
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 85;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 84;
|
||||
}
|
||||
}
|
||||
if (obstacle >= 215 && obstacle <= 234)
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 87;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 86;
|
||||
}
|
||||
}
|
||||
if (obstacle >= 246 && obstacle <= 249)
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 89;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 88;
|
||||
}
|
||||
}
|
||||
if (obstacle >= 107 && obstacle <= 109)
|
||||
{
|
||||
if (sound == SOUND_JUMPTOC)
|
||||
{
|
||||
return 91;
|
||||
}
|
||||
if (sound == SOUND_JUMPEND)
|
||||
{
|
||||
return 90;
|
||||
}
|
||||
}
|
||||
return sound;
|
||||
}
|
||||
|
||||
|
||||
int CDecor::IsWorld(POINT pos)
|
||||
{
|
||||
pos.x += 30;
|
||||
pos.y += 30;
|
||||
if (pos.x < 0 || pos.x >= DIMOBJX * MAXCELX || pos.y < 0 || pos.y >= DIMOBJY * MAXCELY)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
int icon = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
if (icon >= Object::World_1 && icon <= Object::World_8)
|
||||
{
|
||||
return icon - Object::World_1 + 1;
|
||||
}
|
||||
if (icon >= Object::WorldDone_1 && icon <= Object::WorldDone_8)
|
||||
{
|
||||
return icon - Object::WorldDone_1 + 1;
|
||||
}
|
||||
if (icon == Object::World_9 || icon == Object::WorldDone_9)
|
||||
{
|
||||
return 9;
|
||||
}
|
||||
if (icon >= Object::World_10 && icon <= Object::World_14)
|
||||
{
|
||||
return icon - Object::World_10 + 10;
|
||||
}
|
||||
if (icon >= Object::WorldDone_10 && icon <= Object::WorldDone_14)
|
||||
{
|
||||
return icon - Object::WorldDone_10 + 10;
|
||||
}
|
||||
if (icon >= Object::Level_1 && icon <= Object::Level_8)
|
||||
{
|
||||
return icon - Object::Level_1 + 1;
|
||||
}
|
||||
if (icon == Object::WorldBack)
|
||||
{
|
||||
return 199;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
void CDecor::ActiveSwitch(BOOL bState, POINT cel)
|
||||
{
|
||||
POINT pos;
|
||||
pos.x = cel.x * DIMOBJX;
|
||||
pos.y = cel.y * DIMOBJY;
|
||||
ModifDecor(pos, bState ? 384 : 385);
|
||||
PlaySound(bState ? 77 : 76, pos);
|
||||
cel.x -= 20;
|
||||
for (int i = 0; i < 41; i++)
|
||||
{
|
||||
if (cel.x >= 0 && cel.x < 100 && m_decor[cel.x][cel.y].icon == (bState ? 379 : 378))
|
||||
{
|
||||
pos.x = cel.x * DIMOBJX;
|
||||
pos.y = cel.y * DIMOBJY;
|
||||
ModifDecor(pos, bState ? 378 : 379);
|
||||
}
|
||||
cel.x++;
|
||||
}
|
||||
}
|
||||
|
||||
int CDecor::GetTypeBarre(POINT pos)
|
||||
{
|
||||
POINT pos2 = pos;
|
||||
pos.x += 30;
|
||||
pos.y += 22;
|
||||
if (pos.y % 64 > 44)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if (pos.x < 0 || pos.x >= 6400 || pos.y < 0 || pos.y >= 6400)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
int icon = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
if (icon != 138 && icon != 202)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if (pos.y >= 6336)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
icon = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY + 1].icon;
|
||||
if (IsPassIcon(icon))
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
RECT rect = BlupiRect(pos2);
|
||||
rect.top = pos2.y + 60 - 2;
|
||||
rect.bottom = pos2.y + 60 - 1;
|
||||
if (DecorDetect(rect, TRUE))
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsLave(POINT pos)
|
||||
{
|
||||
pos.x += DIMBLUPIX / 2;
|
||||
return pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 68;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsPiege(POINT pos)
|
||||
{
|
||||
pos.x += DIMBLUPIX / 2;
|
||||
pos.y += DIMBLUPIY;
|
||||
return pos.x % 64 >= 15 && pos.x % 64 <= 49 && pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 373;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsGoutte(POINT pos, BOOL bAlways)
|
||||
{
|
||||
pos.x += DIMBLUPIX / 2;
|
||||
if (pos.x % 64 < 15 || pos.x % 64 > 49)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
if (pos.x < 0 || pos.x >= 6400 || pos.y < 0 || pos.y >= 6400)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
int icon = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
if (bAlways)
|
||||
{
|
||||
return icon == 404 || icon == 410;
|
||||
}
|
||||
return icon == 404;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsScie(POINT pos)
|
||||
{
|
||||
pos.x += DIMBLUPIX / 2;
|
||||
return pos.x % 64 >= 4 && pos.x % 64 <= 60 && pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 378;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsSwitch(POINT pos, POINT *outCelSwitch)
|
||||
{
|
||||
pos.x += DIMBLUPIX / 2;
|
||||
if (pos.x % DIMOBJX < 4 || pos.x % DIMOBJX > DIMOBJX - 4)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
if (pos.x < 0 || pos.x >= DIMOBJX * MAXCELX || pos.y < 0 || pos.y >= DIMOBJY * MAXCELY)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
outCelSwitch->x = pos.x / DIMOBJX;
|
||||
outCelSwitch->y = pos.y / DIMOBJY;
|
||||
return m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 384 || m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 385;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsEcraseur(POINT pos)
|
||||
{
|
||||
if (m_time / 3 % 10 > 2)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
pos.x += 30;
|
||||
return pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 317;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsBlitz(POINT pos, BOOL bAlways)
|
||||
{
|
||||
pos.x += 30;
|
||||
if (pos.x < 0 || pos.x >= 6400 || pos.y < 0 || pos.y >= 6400)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
POINT tinyPoint;
|
||||
tinyPoint.x = pos.x / DIMOBJX;
|
||||
tinyPoint.y = pos.y / DIMOBJY;
|
||||
return m_decor[tinyPoint.x][tinyPoint.y].icon == 305 && (bAlways || BlitzActif(tinyPoint));
|
||||
}
|
||||
|
||||
BOOL CDecor::IsRessort(POINT pos)
|
||||
{
|
||||
pos.x += 30;
|
||||
pos.y += 60;
|
||||
return pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 211;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsTemp(POINT pos)
|
||||
{
|
||||
pos.x += 30;
|
||||
pos.y += 60;
|
||||
return pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 324;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsBridge(POINT pos, POINT *outCelBridge)
|
||||
{
|
||||
pos.x += 30;
|
||||
pos.y += 60;
|
||||
if (pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 364)
|
||||
{
|
||||
outCelBridge->x = pos.x / DIMOBJX;
|
||||
outCelBridge->y = pos.y / DIMOBJY;
|
||||
return TRUE;
|
||||
}
|
||||
pos.y -= 60;
|
||||
if (pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon == 364)
|
||||
{
|
||||
outCelBridge->x = pos.x / DIMOBJX;
|
||||
outCelBridge->y = pos.y / DIMOBJY;
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
|
||||
}
|
||||
|
||||
int CDecor::IsDoor(POINT pos, POINT *outCelPorte)
|
||||
{
|
||||
int num;
|
||||
if (m_blupiDir == 1)
|
||||
{
|
||||
num = -60;
|
||||
}
|
||||
else
|
||||
{
|
||||
num = 60;
|
||||
}
|
||||
pos.x += 30;
|
||||
for (int i = 0; i < 2; i++)
|
||||
{
|
||||
if (pos.x >= 0 && pos.x < DIMOBJX * MAXCELX && pos.y >= 0 && pos.y < DIMOBJY * MAXCELY && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon >= 334 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon <= 336)
|
||||
{
|
||||
outCelPorte->x = pos.x / DIMOBJX;
|
||||
outCelPorte->y = pos.y / DIMOBJY;
|
||||
return m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
}
|
||||
pos.x += num;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
int CDecor::IsTeleporte(POINT pos)
|
||||
{
|
||||
if (pos.x % DIMOBJX > 6)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
pos.x += 30;
|
||||
pos.y -= 60;
|
||||
if (pos.x < 0 || pos.x >= DIMOBJX * MAXCELX || pos.y < 0 || pos.y >= DIMOBJY * MAXCELY)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
if (m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon >= 330 && m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon <= 333)
|
||||
{
|
||||
return m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
BOOL CDecor::SearchTeleporte(POINT pos, POINT *newpos)
|
||||
{
|
||||
int num = IsTeleporte(pos);
|
||||
if (num == -1)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
for (int i = 0; i < 100; i++)
|
||||
{
|
||||
for (int j = 0; j < 100; j++)
|
||||
{
|
||||
if (num == m_decor[i][j].icon)
|
||||
{
|
||||
newpos->x = i * 64;
|
||||
newpos->y = j * 64 + 60;
|
||||
if (newpos->x < pos.x - 40 || newpos->x > pos.x + 40 || newpos->y < pos.y - 40 || newpos->y > pos.y + 40)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsSurfWater(POINT pos)
|
||||
{
|
||||
if (pos.y % 64 < 64 - BLUPISURF)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
int icon = m_decor[(pos.x + 30) / 64][pos.y / DIMOBJY].icon;
|
||||
int icon2 = m_decor[(pos.x + 30) / 64][(pos.y + BLUPISURF) / 64].icon;
|
||||
return icon != 92 && icon2 == 92;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsDeepWater(POINT pos)
|
||||
{
|
||||
int num = (pos.x + 30) / 64;
|
||||
int num2 = pos.y / DIMOBJY;
|
||||
if (num < 0 || num >= 100 || num2 < 0 || num2 >= 100)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
int icon = m_decor[num][num2].icon;
|
||||
return icon == 91 || icon == 92;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsOutWater(POINT pos)
|
||||
{
|
||||
int icon = m_decor[(pos.x + 30) / 64][(pos.y + 30) / 64].icon;
|
||||
return icon != 91 && icon != 92 && IsPassIcon(icon);
|
||||
}
|
||||
|
||||
BOOL CDecor::IsPassIcon(int icon)
|
||||
{
|
||||
if (icon == 324 && m_time / 4 % 20 >= 18)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
if (icon >= 0 && icon < MAXQUART)
|
||||
{
|
||||
for (int i = 0; i < 16; i++)
|
||||
{
|
||||
if (table_decor_quart[icon * 16 + i] != 0)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsBlocIcon(int icon)
|
||||
{
|
||||
if (icon < 0 || icon >= MAXQUART)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
if (icon == 324 && m_time / 4 % 20 < 18)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
for (int i = 0; i < 16; i++)
|
||||
{
|
||||
if (table_decor_quart[icon * 16 + i] == 0)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsVentillo(POINT pos)
|
||||
{
|
||||
int num = 0;
|
||||
BOOL flag = FALSE;
|
||||
POINT tinyPoint;
|
||||
pos.x += 30;
|
||||
pos.y += 30;
|
||||
if (pos.x < 0 || pos.x >= 6400 || pos.y < 0 || pos.y >= 6400)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
int icon = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
if (icon < 126 || icon > 137)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
if (icon == 126)
|
||||
{
|
||||
if (pos.x % 64 <= 16)
|
||||
{
|
||||
flag = TRUE;
|
||||
}
|
||||
tinyPoint.x = -64;
|
||||
tinyPoint.y = 0;
|
||||
num = 110;
|
||||
}
|
||||
if (icon == 129)
|
||||
{
|
||||
if (pos.x % 64 >= 48)
|
||||
{
|
||||
flag = TRUE;
|
||||
}
|
||||
tinyPoint.x = 64;
|
||||
tinyPoint.y = 0;
|
||||
num = 114;
|
||||
}
|
||||
if (icon == 132)
|
||||
{
|
||||
if (pos.y % 64 <= 32)
|
||||
{
|
||||
flag = TRUE;;
|
||||
}
|
||||
tinyPoint.x = 0;
|
||||
tinyPoint.y = -64;
|
||||
num = 118;
|
||||
}
|
||||
if (icon == 135)
|
||||
{
|
||||
if (pos.y % 64 >= 48)
|
||||
{
|
||||
flag = TRUE;
|
||||
}
|
||||
tinyPoint.x = 0;
|
||||
tinyPoint.y = 64;
|
||||
num = 122;
|
||||
}
|
||||
if (!flag)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
ModifDecor(pos, -1);
|
||||
do
|
||||
{
|
||||
pos.x += tinyPoint.x;
|
||||
pos.y += tinyPoint.y;
|
||||
if (num != m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon)
|
||||
{
|
||||
break;
|
||||
}
|
||||
ModifDecor(pos, -1);
|
||||
} while (pos.x >= 0 && pos.x < 6400 && pos.y >= 0 && pos.y < 6400);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void CDecor::ModifDecor(POINT pos, int icon, BOOL bMulti)
|
||||
{// TODO: this
|
||||
int icon2 = m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon;
|
||||
if (icon == -1 && icon >= 126 && icon2 <= 137)
|
||||
{
|
||||
|
||||
}
|
||||
m_decor[pos.x / DIMOBJX][pos.y / DIMOBJY].icon = icon;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsRightBorder(POINT pos, POINT offset)
|
||||
{
|
||||
int icon;
|
||||
|
||||
if (pos.x >= 0
|
||||
&& pos.x < (m_dimDecor.x != 0 ? 100 : 10)
|
||||
&& pos.y >= 0
|
||||
&& pos.y < (m_dimDecor.y != 0 ? 100 : 8))
|
||||
{
|
||||
icon = m_decor[offset.x][100 * pos.x + pos.y + offset.y].icon;
|
||||
if (icon >= 386 && icon <= 397 || icon == 400)
|
||||
{
|
||||
int icon2 = m_decor[pos.x][pos.y].icon;
|
||||
return icon2 >= 386 && icon2 <= 397 || icon2 == 400;
|
||||
}
|
||||
if (icon >= 250 && icon <= 260)
|
||||
{
|
||||
int icon3 = m_decor[pos.x][pos.y].icon;
|
||||
return icon3 >= 250 && icon <= 260;
|
||||
}
|
||||
int num = m_decor[pos.x][pos.y].icon;
|
||||
|
||||
switch (num)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
return FALSE; // temp.
|
||||
}
|
||||
|
||||
|
||||
BOOL CDecor::IsFromage(POINT cel)
|
||||
{
|
||||
if (!IsValidCel(cel)) return FALSE;
|
||||
|
||||
int icon = m_decor[cel.x][cel.y].icon;
|
||||
return (icon >= 246 && icon <= 249) || icon == 339;
|
||||
}
|
||||
|
||||
BOOL CDecor::IsGrotte(POINT cel)
|
||||
{
|
||||
if (!IsValidCel(cel)) return FALSE;
|
||||
|
||||
int icon = m_decor[cel.x][cel.y].icon;
|
||||
return icon = 284 || icon == 301 || icon == 337;
|
||||
}
|
||||
|
||||
void CDecor::AdaptMidBorder(POINT cel)
|
||||
{
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
int num = 15;
|
||||
if (!IsRightBorder(POINT( cel.x, cel.y + 1 ), POINT( 0, -1 )))
|
||||
{
|
||||
num &= -2;
|
||||
}
|
||||
if (!IsRightBorder(POINT( cel.x, cel.y + 1 ), POINT( 0, 1 )))
|
||||
{
|
||||
num &= -3;
|
||||
}
|
||||
if (!IsRightBorder(POINT( cel.x + 1, cel.y ), POINT( -1, 0 )))
|
||||
{
|
||||
num &= -5;
|
||||
}
|
||||
if (!IsRightBorder(POINT( cel.x - 1, cel.y ), POINT( 1, 0 )))
|
||||
{
|
||||
num &= -9;
|
||||
}
|
||||
int num2 = m_decor[cel.x][cel.y].icon;
|
||||
if (num2 == 156)
|
||||
{
|
||||
num2 = 35;
|
||||
}
|
||||
if (num2 == 252 || num2 == 253)
|
||||
{
|
||||
num2 = 251;
|
||||
}
|
||||
if (num2 == 255)
|
||||
{
|
||||
num2 = 254;
|
||||
}
|
||||
if (num2 == 362)
|
||||
{
|
||||
num2 = 347;
|
||||
}
|
||||
if (num2 == 363)
|
||||
{
|
||||
num2 = 348;
|
||||
}
|
||||
if (num2 >= 341 && num2 <= 346)
|
||||
{
|
||||
num2 = 341;
|
||||
}
|
||||
for (int i = 0; i < 144; i++)
|
||||
{
|
||||
if (num2 == table_adapt_decor[i])
|
||||
{
|
||||
num2 = table_adapt_decor[i / 16 * 16 + num];
|
||||
if (num2 == 35 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 156;
|
||||
}
|
||||
if (num2 == 251)
|
||||
{
|
||||
num2 = Random(251, 253);
|
||||
}
|
||||
if (num2 == 254 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 255;
|
||||
}
|
||||
if (num2 == 347 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 362;
|
||||
}
|
||||
if (num2 == 348 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 363;
|
||||
}
|
||||
if (num2 == 341)
|
||||
{
|
||||
num2 = Random(341, 346);
|
||||
}
|
||||
m_decor[cel.x][cel.y].icon = num2;
|
||||
return;
|
||||
}
|
||||
}
|
||||
num2 = m_decor[cel.x][cel.y].icon;
|
||||
if (num2 == -1 || (num2 >= 264 && num2 <= 282))
|
||||
{
|
||||
num = 15;
|
||||
if (!IsFromage(POINT(cel.x, cel.y + 1)))
|
||||
{
|
||||
num &= -2;
|
||||
}
|
||||
if (!IsFromage(POINT(cel.x, cel.y - 1)))
|
||||
{
|
||||
num &= -3;
|
||||
}
|
||||
if (!IsFromage(POINT(cel.x + 1, cel.y)))
|
||||
{
|
||||
num &= -5;
|
||||
}
|
||||
if (!IsFromage(POINT(cel.x - 1, cel.y)))
|
||||
{
|
||||
num &= -9;
|
||||
}
|
||||
num2 = table_adapt_fromage[num];
|
||||
if (num2 == 268 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 279;
|
||||
}
|
||||
if (num2 == 269 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 280;
|
||||
}
|
||||
if (num2 == 264 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 281;
|
||||
}
|
||||
if (num2 == 265 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 282;
|
||||
}
|
||||
m_decor[cel.x][cel.y].icon = num2;
|
||||
}
|
||||
num2 = m_decor[cel.x][cel.y].icon;
|
||||
if (num2 == -1 || (num2 >= 285 && num2 <= 303 && num2 != 301))
|
||||
{
|
||||
num = 15;
|
||||
if (!IsGrotte(POINT(cel.x, cel.y + 1)))
|
||||
{
|
||||
num &= -2;
|
||||
}
|
||||
if (!IsGrotte(POINT(cel.x, cel.y - 1)))
|
||||
{
|
||||
num &= -3;
|
||||
}
|
||||
if (!IsGrotte(POINT(cel.x + 1, cel.y)))
|
||||
{
|
||||
num &= -5;
|
||||
}
|
||||
if (!IsGrotte(POINT(cel.x - 1, cel.y)))
|
||||
{
|
||||
num &= -9;
|
||||
}
|
||||
num2 = table_adapt_fromage[num + 16];
|
||||
if (num2 == 289 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 300;
|
||||
}
|
||||
if (num2 == 285 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 302;
|
||||
}
|
||||
if (num2 == 286 && rand() % 2 == 0)
|
||||
{
|
||||
num2 = 303;
|
||||
}
|
||||
m_decor[cel.x][cel.y].icon = num2;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::AdaptBorder(POINT cel)
|
||||
{
|
||||
AdaptMidBorder(cel);
|
||||
AdaptMidBorder(POINT(cel.x + 1, cel.y));
|
||||
AdaptMidBorder(POINT(cel.x - 1, cel.y));
|
||||
AdaptMidBorder(POINT(cel.x, cel.y + 1));
|
||||
AdaptMidBorder(POINT(cel.x, cel.y - 1));
|
||||
int icon = m_decor[cel.x][cel.y].icon;
|
||||
if (icon != -1 && !IsPassIcon(icon))
|
||||
{
|
||||
MoveObjectDelete(cel);
|
||||
}
|
||||
icon = m_decor[cel.x][cel.y].icon;
|
||||
if (icon == 304)
|
||||
{
|
||||
for (int i = 0; i < 4; i++)
|
||||
{
|
||||
cel.y++;
|
||||
if (cel.y >= 100)
|
||||
{
|
||||
break;
|
||||
}
|
||||
icon = m_decor[cel.x][cel.y].icon;
|
||||
if (icon != -1)
|
||||
{
|
||||
break;
|
||||
}
|
||||
m_decor[cel.x][cel.y].icon = 305;
|
||||
}
|
||||
}
|
||||
if (icon == -1)
|
||||
{
|
||||
for (int i = 0; i < 4; i++)
|
||||
{
|
||||
cel.y++;
|
||||
if (cel.y >= 100)
|
||||
{
|
||||
return;
|
||||
}
|
||||
icon = m_decor[cel.x][cel.y].icon;
|
||||
if (icon != 305)
|
||||
{
|
||||
return;
|
||||
}
|
||||
m_decor[cel.x][cel.y].icon = -1;
|
||||
}
|
||||
}
|
||||
}
|
4392
src/decblupi.cpp
Normal file
659
src/decdesign.cpp
Normal file
@ -0,0 +1,659 @@
|
||||
// DecDesign.cpp
|
||||
//
|
||||
|
||||
#include "def.h"
|
||||
#include "decor.h"
|
||||
#include "misc.h"
|
||||
#include "dectables.h"
|
||||
|
||||
POINT CDecor::ScreenPosToCelPos(POINT pos)
|
||||
{
|
||||
if (pos.x >= 0 && pos.x < LXIMAGE && pos.y >= 0 && pos.y < LYIMAGE) {
|
||||
return POINT(
|
||||
(m_posDecor.x + m_dimCelHili.x * -32 + 32 + pos.x) / DIMOBJX,
|
||||
(m_posDecor.y + m_dimCelHili.y * -32 + 32 + pos.y) / DIMOBJY
|
||||
);
|
||||
}
|
||||
else return POINT( -1, -1 );
|
||||
}
|
||||
|
||||
void CDecor::SetCelPosFromScreenPos(POINT pos)
|
||||
{
|
||||
m_posCelHili = ScreenPosToCelPos(pos);
|
||||
}
|
||||
|
||||
void CDecor::SetFieldCC38AndStuff(int _foo, int _bar)
|
||||
{
|
||||
m_dimCelHili = POINT( 1, 1 );
|
||||
if (_foo == 2 && _bar != 3 && _bar != 9 && _bar != 10) m_dimCelHili = POINT( 2, 2 );
|
||||
if (_foo == 3) m_iconLift = _bar;
|
||||
if (_foo == 4) m_iconLift = _bar + 20;
|
||||
if (_foo == 5) m_iconLift = _bar + 40;
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
}
|
||||
|
||||
void CDecor::DeleteCel(POINT cel)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
m_decor[cel.x][cel.y].icon = -1;
|
||||
AdaptBorder(cel);
|
||||
m_bigDecor[cel.x][cel.y].icon = -1;
|
||||
MoveObjectDelete(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceMenuItem(short *pCel, int *pTable, int lastIndex, BYTE flags, int currentIcon, BOOL bRand)
|
||||
{
|
||||
if (bRand) {
|
||||
*pCel = pTable[rand() % (pTable[0] + 1)];
|
||||
}
|
||||
else if (!(flags & 8)) {
|
||||
if (flags & 1) {
|
||||
lastIndex++;
|
||||
if (*pCel == pTable[lastIndex] && currentIcon != 0 && pTable[0] <= lastIndex) {
|
||||
lastIndex = 0;
|
||||
}
|
||||
*pCel = pTable[lastIndex + 1];
|
||||
}
|
||||
}
|
||||
else {
|
||||
*pCel = pTable[lastIndex + 1];
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu1(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
short *pIconBig = &m_bigDecor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Tree
|
||||
PlaceMenuItem(pIconBig, table_366b0, m_lastDecorIndexes[0], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 1: // Palmtree
|
||||
PlaceMenuItem(pIconBig, table_366c0, m_lastDecorIndexes[1], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 2: // Decorative plant
|
||||
PlaceMenuItem(pIconBig, table_366d8, m_lastDecorIndexes[2], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 3: // Marine plant
|
||||
*pIcon = Object::Marine_1;
|
||||
break;
|
||||
case 4: // House
|
||||
PlaceMenuItem(pIconBig, table_366e8, m_lastDecorIndexes[3], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 5: // Mechanical background
|
||||
PlaceMenuItem(pIconBig, table_366f8, m_lastDecorIndexes[4], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 6: // Kid's stuff background
|
||||
PlaceMenuItem(pIconBig, table_36710, m_lastDecorIndexes[5], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 7: // Green slime 2
|
||||
PlaceMenuItem(pIconBig, table_36748, m_lastDecorIndexes[6], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 8: // Element for Palace
|
||||
PlaceMenuItem(pIconBig, table_36520, m_lastDecorIndexes[7], flags, *pIconBig, TRUE);
|
||||
break;
|
||||
case 9: // Support
|
||||
PlaceMenuItem(pIcon, table_36670, m_lastDecorIndexes[8], flags, *pIcon, TRUE);
|
||||
break;
|
||||
case 10: // Spider's web
|
||||
PlaceMenuItem(pIcon, table_366a0, m_lastDecorIndexes[9], flags, *pIcon, TRUE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu2(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
m_iconLift = index;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Square tech-blocks
|
||||
PlaceMenuItem(pIcon, table_36418, m_lastDecorIndexes[10], flags, *pIcon, TRUE);
|
||||
break;
|
||||
case 1: // Special tech-blocks
|
||||
PlaceMenuItem(pIcon, table_36458, m_lastDecorIndexes[11], flags, *pIcon, TRUE);
|
||||
break;
|
||||
case 2: // Triangular tech-blocks
|
||||
PlaceMenuItem(pIcon, table_36488, m_lastDecorIndexes[12], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 3: // Secret tech-block
|
||||
PlaceMenuItem(pIcon, table_364a0, m_lastDecorIndexes[13], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 4: // Mechanical square
|
||||
PlaceMenuItem(pIcon, table_364b0, m_lastDecorIndexes[14], flags, *pIcon, TRUE);
|
||||
break;
|
||||
case 5: // Special mechanical
|
||||
PlaceMenuItem(pIcon, table_364d0, m_lastDecorIndexes[15], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 6: // Secret mechanical
|
||||
PlaceMenuItem(pIcon, table_364e8, m_lastDecorIndexes[16], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 7: // Pipes
|
||||
*pIcon = Object::Pipes_1;
|
||||
break;
|
||||
}
|
||||
AdaptBorder(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu3(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
m_iconLift = index + 20;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Square rock
|
||||
PlaceMenuItem(pIcon, table_36530, m_lastDecorIndexes[20], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 1: // Triangular rock
|
||||
PlaceMenuItem(pIcon, table_36538, m_lastDecorIndexes[21], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 2: // Secret rock
|
||||
PlaceMenuItem(pIcon, table_36548, m_lastDecorIndexes[22], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 3: // Cave
|
||||
// todo
|
||||
break;
|
||||
case 4: // Secret cave
|
||||
*pIcon = Object::CaveSecret;
|
||||
break;
|
||||
case 5: // Cheese
|
||||
*pIcon = Random(Object::CheeseSquare_1, Object::CheeseSquare_4);
|
||||
break;
|
||||
case 6: // Secret cheese
|
||||
*pIcon = Object::CheeseSecret;
|
||||
break;
|
||||
case 7: // Green slime 2
|
||||
*pIcon = Object::Slime_1;
|
||||
break;
|
||||
case 8: // Grass
|
||||
PlaceMenuItem(pIcon, table_365d0, m_lastDecorIndexes[23], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 9: // Water
|
||||
PlaceMenuItem(pIcon, table_36630, m_lastDecorIndexes[24], flags, *pIcon, FALSE);
|
||||
break;
|
||||
}
|
||||
AdaptBorder(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu4(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
m_iconLift = index + 40;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Palace
|
||||
break;
|
||||
case 1: // Element for Palace
|
||||
break;
|
||||
case 2: // Building facade
|
||||
break;
|
||||
case 3: // Roof
|
||||
break;
|
||||
case 4: // Bricks
|
||||
break;
|
||||
case 5: // Furniture
|
||||
break;
|
||||
case 6: // Wooden wall
|
||||
break;
|
||||
case 7: // Kid's stuff square
|
||||
break;
|
||||
case 8: // Special Kid's stuff
|
||||
break;
|
||||
case 9: // Invisible block
|
||||
break;
|
||||
}
|
||||
AdaptBorder(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu5(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
int mobId;
|
||||
MoveObject* pMob;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Bomb
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_BOMBEDOWN;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 4 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x0c;
|
||||
break;
|
||||
case 1: // Hanging bomb
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_BOMBEUP;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x30;
|
||||
break;
|
||||
case 2: // Homing bomb
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_BOMBEFOLLOW1;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX, cel.y * DIMOBJY );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x100;
|
||||
break;
|
||||
case 3: // Lava
|
||||
PlaceMenuItem(pIcon, table_decor_lave, m_lastDecorIndexes[40], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 4: // Fan
|
||||
PlaceMenuItem(pIcon, table_decor_ventillog, m_lastDecorIndexes[41], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 5: // Wind
|
||||
PlaceMenuItem(pIcon, table_decor_ventg, m_lastDecorIndexes[42], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 6: // Slime trap (floor)
|
||||
*pIcon = Object::SlimeTrapFloor_1;
|
||||
break;
|
||||
case 7: // Slime trap (ceiling)
|
||||
*pIcon = Object::SlimeTrapCeiling_1;
|
||||
break;
|
||||
case 8: // Circular saw
|
||||
PlaceMenuItem(pIcon, table_decor_scie, m_lastDecorIndexes[43], flags, *pIcon, FALSE);
|
||||
break;
|
||||
case 9: // Inverter
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_INVERT;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 8 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0xBB;
|
||||
break;
|
||||
case 10: // Lightning
|
||||
*pIcon = Object::LightningMachine;
|
||||
break;
|
||||
case 11: // Crusher
|
||||
*pIcon = Object::Crusher_1;
|
||||
break;
|
||||
}
|
||||
AdaptBorder(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu6(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel) || currentIcon == 0) return;
|
||||
|
||||
switch (m_iconLift) {
|
||||
|
||||
}
|
||||
|
||||
switch (index) {
|
||||
case 0: // Slow lift
|
||||
case 1: // Normal lift
|
||||
case 2: // Fast lift
|
||||
case 3: // Fast/Slow lift
|
||||
case 4: // Lift with conveyor belt
|
||||
case 5: // Bulldozer
|
||||
case 6: // Fish
|
||||
case 7: // Bird
|
||||
case 8: // Wasp
|
||||
case 9: // Slime creature
|
||||
case 10: // Moving bomb
|
||||
case 11: // Heliported ennemy
|
||||
case 12: // Motorized ennemy
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu7(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
MoveObject* pMob;
|
||||
int mobId;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Chest
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_TRESOR;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 4 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x00;
|
||||
break;
|
||||
case 1: // Egg
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_EGG;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 8 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x15;
|
||||
break;
|
||||
case 2: // Lollipop
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_POWER;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 8 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x88;
|
||||
break;
|
||||
case 3: // Shield
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_SHIELD;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 8 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0x90;
|
||||
break;
|
||||
case 4: // Invisibility potion
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_DRINK;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 6 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0xB2;
|
||||
break;
|
||||
case 5: // Glue supply
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_BULLET;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 4 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0xB1;
|
||||
break;
|
||||
case 6: // Recharging device
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_CHARGE;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 4 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0xEE;
|
||||
break;
|
||||
case 7: // Personal bomb
|
||||
int type;
|
||||
mobId = MoveObjectSearch(cel, -1);
|
||||
if (mobId != -1 && currentIcon != 0) {
|
||||
if (mobId >= TYPE_BOMBEPERSO4) {
|
||||
m_lastDecorIndexes[60] = 0;
|
||||
}
|
||||
else {
|
||||
m_lastDecorIndexes[60] = m_moveObject[mobId].type - TYPE_BOMBEPERSO1;
|
||||
}
|
||||
}
|
||||
type = m_lastDecorIndexes[60] + TYPE_BOMBEPERSO1;
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = type;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 6 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
switch (type) {
|
||||
default:
|
||||
case TYPE_BOMBEPERSO1:
|
||||
pMob->channel = CHBLUPI;
|
||||
break;
|
||||
case TYPE_BOMBEPERSO2:
|
||||
pMob->channel = CHBLUPI1;
|
||||
break;
|
||||
case TYPE_BOMBEPERSO3:
|
||||
pMob->channel = CHBLUPI2;
|
||||
break;
|
||||
case TYPE_BOMBEPERSO4:
|
||||
pMob->channel = CHBLUPI3;
|
||||
break;
|
||||
}
|
||||
pMob->icon = 0x101;
|
||||
break;
|
||||
case 8: // Dynamite
|
||||
MoveObjectDelete(cel);
|
||||
mobId = MoveObjectFree();
|
||||
if (mobId == -1) return;
|
||||
pMob = &m_moveObject[mobId];
|
||||
pMob->type = TYPE_DYNAMITE;
|
||||
pMob->stepAdvance = 1;
|
||||
pMob->stepRecede = 1;
|
||||
pMob->timeStopStart = 0;
|
||||
pMob->timeStopEnd = 0;
|
||||
pMob->posStart = POINT( cel.x * DIMOBJX + 2, cel.y * DIMOBJY + 6 );
|
||||
pMob->posEnd = pMob->posStart;
|
||||
pMob->posCurrent = pMob->posStart;
|
||||
pMob->step = STEP_STOPSTART;
|
||||
pMob->time = 0;
|
||||
pMob->phase = 0;
|
||||
pMob->channel = CHELEMENT;
|
||||
pMob->icon = 0xFC;
|
||||
break;
|
||||
}
|
||||
AdaptBorder(cel);
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu8(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Key
|
||||
case 1: // Door
|
||||
case 2: // Closed while not all chests have been found
|
||||
case 3: // Teleporter
|
||||
case 4: // Bar to hang from
|
||||
case 5: // Spring
|
||||
case 6: // Vanishing bloc
|
||||
case 7: // Fragile bridge
|
||||
case 8: // Wooden case
|
||||
case 9: // Secret wooden case
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu9(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Hovercraft
|
||||
case 1: // Helicopter
|
||||
case 2: // Skateboard
|
||||
case 3: // Jeep
|
||||
case 4: // Glue tank
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::PlaceItemFromMenu10(POINT cel, int index, BYTE flags, int currentIcon)
|
||||
{
|
||||
m_2ndPositionCalculationSlot = -1;
|
||||
|
||||
short *pIcon = &m_decor[cel.x][cel.y].icon;
|
||||
|
||||
if (!IsValidCel(cel)) return;
|
||||
|
||||
switch (index) {
|
||||
case 0: // Goal
|
||||
case 1: // Yellow Blupi
|
||||
case 2: // Orange Blupi
|
||||
case 3: // Blue Blupi
|
||||
case 4: // Green Blupi
|
||||
case 5: // Door
|
||||
case 6: // Level start
|
||||
case 7: // Key
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
char* CDecor::GetMissionTitle()
|
||||
{
|
||||
return m_missionTitle;
|
||||
}
|
||||
|
||||
void CDecor::SetMissionTitle(char *str)
|
||||
{
|
||||
strcpy(m_missionTitle, str);
|
||||
}
|
388
src/decio.cpp
Normal file
@ -0,0 +1,388 @@
|
||||
// DecIO.cpp
|
||||
//
|
||||
|
||||
#include "def.h"
|
||||
#include "decor.h"
|
||||
#include "misc.h"
|
||||
|
||||
void CDecor::GetMissionPath(char* str, int user, int mission, BOOL bUser)
|
||||
{
|
||||
if (bUser != 0)
|
||||
{
|
||||
sprintf(str, "data\\%.3d-%.3d.blp", user, mission);
|
||||
AddUserPath(str);
|
||||
return;
|
||||
}
|
||||
sprintf(str, "data\\world%.3d.blp", mission);
|
||||
AddUserPath(str);
|
||||
return;
|
||||
}
|
||||
|
||||
BOOL CDecor::DeleteMission(int user, int mission, BOOL bUser)
|
||||
{
|
||||
char filename[FILENAME_MAX];
|
||||
|
||||
GetMissionPath(filename, user, mission, bUser);
|
||||
remove(filename);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CDecor::Write(int gamer, int mission, BOOL bUser)
|
||||
{
|
||||
char filename[FILENAME_MAX];
|
||||
DescFile* pBuffer = NULL;
|
||||
FILE* file;
|
||||
int* blupiDir;
|
||||
POINT* blupiPos;
|
||||
int nb;
|
||||
int i;
|
||||
|
||||
|
||||
GetMissionPath(filename, gamer, mission, bUser);
|
||||
|
||||
|
||||
file = fopen(filename, "wb");
|
||||
if (file == NULL) goto error;
|
||||
|
||||
pBuffer = (DescFile*)malloc(sizeof(DescFile));
|
||||
if (pBuffer == NULL) goto error;
|
||||
memset(pBuffer, 0, sizeof(DescFile));
|
||||
|
||||
i = 4;
|
||||
pBuffer->majRev = 1;
|
||||
pBuffer->minRev = 3;
|
||||
*pBuffer->reserve1 = 0;
|
||||
pBuffer->posDecor = m_posDecor;
|
||||
pBuffer->dimDecor = m_dimDecor;
|
||||
pBuffer->music = m_music;
|
||||
pBuffer->region = m_region;
|
||||
blupiDir = m_blupiStartDir;
|
||||
strcpy(pBuffer->name, m_missionTitle);
|
||||
blupiPos = m_blupiStartPos;
|
||||
|
||||
for (i = 0; i < 4; i++)
|
||||
{
|
||||
pBuffer->blupiPos[i] = m_blupiStartPos[i];
|
||||
}
|
||||
|
||||
for (i = 0; i < 4; i++)
|
||||
{
|
||||
pBuffer->blupiDir[i] = m_blupiStartDir[i];
|
||||
}
|
||||
|
||||
nb = fwrite(pBuffer, sizeof(DescFile), 1, file);
|
||||
if (nb < 1) goto error;
|
||||
|
||||
nb = fwrite(m_decor, sizeof(Cellule), MAXCELX * MAXCELY / 4, file);
|
||||
if (nb < MAXCELX * MAXCELY / 4) goto error;
|
||||
|
||||
nb = fwrite(m_bigDecor, sizeof(Cellule), MAXCELX * MAXCELY / 4, file);
|
||||
if (nb < MAXCELX * MAXCELY / 4) goto error;
|
||||
|
||||
nb = fwrite(m_moveObject, sizeof(MoveObject), MAXMOVEOBJECT, file);
|
||||
if (nb < MAXMOVEOBJECT) goto error;
|
||||
|
||||
free(pBuffer);
|
||||
fclose(file);
|
||||
return TRUE;
|
||||
|
||||
error:
|
||||
if (pBuffer != NULL) free(pBuffer);
|
||||
if (file != NULL) fclose(file);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CDecor::Read(int gamer, int mission, BOOL bUser)
|
||||
{
|
||||
char filename[FILENAME_MAX];
|
||||
FILE* file;
|
||||
DescFile* pBuffer;
|
||||
short majRev, minRev;
|
||||
short obj;
|
||||
Cellule(*objects)[100];
|
||||
POINT* startPos;
|
||||
POINT* blupiPos;
|
||||
int nb;
|
||||
int i = 4;
|
||||
int x, y;
|
||||
int* startDir;
|
||||
int* blupiDir;
|
||||
|
||||
pBuffer = 0;
|
||||
InitDecor();
|
||||
GetMissionPath(filename, gamer, mission, bUser);
|
||||
|
||||
file = fopen(filename, "rb");
|
||||
if (file == NULL) goto error;
|
||||
|
||||
pBuffer = (DescFile*)malloc(sizeof(DescFile));
|
||||
if (pBuffer == NULL) goto error;
|
||||
|
||||
nb = fread(pBuffer, sizeof(DescFile), 1, file);
|
||||
if (nb < 1) goto error;
|
||||
|
||||
majRev = pBuffer->majRev;
|
||||
minRev = pBuffer->minRev;
|
||||
m_posDecor = pBuffer->posDecor;
|
||||
m_dimDecor = pBuffer->dimDecor;
|
||||
m_music = pBuffer->music;
|
||||
m_region = pBuffer->region;
|
||||
if (majRev >= 1 && minRev >= 3)
|
||||
{
|
||||
strcpy(m_missionTitle,pBuffer->name);
|
||||
}
|
||||
startDir = m_blupiStartDir;
|
||||
blupiDir = pBuffer->blupiDir;
|
||||
startPos = m_blupiStartPos;
|
||||
blupiPos = pBuffer->blupiPos;
|
||||
|
||||
for (i = 0; i < MAXNETPLAYER; i++)
|
||||
{
|
||||
m_blupiStartPos[i] = pBuffer->blupiPos[i];
|
||||
m_blupiStartDir[i] = pBuffer->blupiDir[i];
|
||||
}
|
||||
|
||||
nb = fread(m_decor, sizeof(Cellule), MAXCELX * MAXCELY, file);
|
||||
if (nb < MAXCELX * MAXCELY) goto error;
|
||||
|
||||
#if !_DREAM
|
||||
for (x = 0; x < MAXCELX; x++)
|
||||
{
|
||||
for (y = 0; y < MAXCELY; y++)
|
||||
{
|
||||
if (m_decor[x][y].icon >= Object::Dream_1 &&
|
||||
m_decor[x][y].icon <= Object::Dream_20)
|
||||
{
|
||||
m_decor[x][y].icon = Object::KidsSquare_10;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (majRev == 1 && minRev >= 1)
|
||||
{
|
||||
nb = fread(m_bigDecor, sizeof(Cellule), MAXCELX * MAXCELY, file);
|
||||
if (nb < MAXCELX * MAXCELY) goto error;
|
||||
}
|
||||
|
||||
memset(m_moveObject, 0, sizeof(MoveObject) * MAXMOVEOBJECT);
|
||||
if (majRev == 1 && minRev >= 2)
|
||||
{
|
||||
nb = fread(m_moveObject, sizeof(MoveObject), MAXMOVEOBJECT, file);
|
||||
if (nb < MAXMOVEOBJECT) goto error;
|
||||
}
|
||||
else
|
||||
{
|
||||
nb = fread(m_moveObject, sizeof(MoveObject), MAXMOVEOBJECT / 2, file);
|
||||
if (nb < MAXMOVEOBJECT / 2) goto error;
|
||||
}
|
||||
|
||||
free(pBuffer);
|
||||
fclose(file);
|
||||
return TRUE;
|
||||
error:
|
||||
if (pBuffer != NULL) free(pBuffer);
|
||||
if (file != NULL) fclose(file);
|
||||
|
||||
InitDecor();
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CDecor::SomethingMissionPath(int gamer, int mission, BOOL bUser)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CDecor::CurrentWrite(int gamer, int mission, BOOL bUser)
|
||||
{
|
||||
char filename[MAX_PATH];
|
||||
FILE* file = NULL;
|
||||
DescSave* pBuffer = NULL;
|
||||
int nb, i, x, y;
|
||||
int majRev, minRev;
|
||||
|
||||
sprintf(filename, "data\\s%.3d-%.3d.blp", gamer, mission);
|
||||
AddUserPath(filename);
|
||||
|
||||
file = fopen(filename, "wb");
|
||||
if (file == NULL) goto error;
|
||||
|
||||
pBuffer = (DescSave*)malloc(sizeof(DescSave));
|
||||
if (pBuffer == NULL) goto error;
|
||||
|
||||
memset(pBuffer, 0, sizeof(DescSave));
|
||||
pBuffer->lg = sizeof(DescSave);
|
||||
pBuffer->majRev = 1;
|
||||
pBuffer->minRev = 4;
|
||||
pBuffer->reserve1[0] = 0;
|
||||
memcpy(pBuffer->decor, m_decor, sizeof(pBuffer->decor));
|
||||
memcpy(pBuffer->bigDecor, m_bigDecor, sizeof(pBuffer->bigDecor));
|
||||
memcpy(pBuffer->balleTraj, m_balleTraj, sizeof(pBuffer->balleTraj));
|
||||
memcpy(pBuffer->moveTraj, m_moveTraj, sizeof(pBuffer->moveTraj));
|
||||
memcpy(pBuffer->moveObject, m_moveObject, sizeof(pBuffer->moveObject));
|
||||
pBuffer->posDecor = m_posDecor;
|
||||
pBuffer->dimDecor = m_dimDecor;
|
||||
pBuffer->phase = m_phase;
|
||||
pBuffer->term = m_term;
|
||||
pBuffer->music = m_music;
|
||||
pBuffer->region = m_region;
|
||||
pBuffer->time = m_time;
|
||||
memcpy(pBuffer->missionTitle, m_missionTitle, sizeof(pBuffer->missionTitle));
|
||||
pBuffer->nbRankCaisse = m_nbRankCaisse;
|
||||
memcpy(pBuffer->rankCaisse, m_rankCaisse, sizeof(pBuffer->rankCaisse));
|
||||
pBuffer->nbLinkCaisse = m_nbLinkCaisse;
|
||||
memcpy(pBuffer->linkCaisse, m_linkCaisse, sizeof(pBuffer->linkCaisse));
|
||||
pBuffer->blupiPos = m_blupiPos;
|
||||
pBuffer->blupiValidPos = m_blupiValidPos;
|
||||
pBuffer->blupiAction = m_blupiAction;
|
||||
pBuffer->blupiDir = m_blupiDir;
|
||||
pBuffer->blupiPhase = m_blupiPhase;
|
||||
pBuffer->blupiVitesse = m_blupiVitesse;
|
||||
pBuffer->blupiIcon = m_blupiIcon;
|
||||
pBuffer->blupiSec = m_blupiSec;
|
||||
pBuffer->blupiChannel = m_blupiChannel;
|
||||
pBuffer->blupiVector = m_blupiVector;
|
||||
pBuffer->blupiTransport = m_blupiTransport;
|
||||
pBuffer->blupiFocus = m_blupiFocus;
|
||||
pBuffer->blupiAir = m_blupiAir;
|
||||
pBuffer->blupiHelico = m_blupiHelico;
|
||||
pBuffer->blupiOver = m_blupiOver;
|
||||
pBuffer->blupiJeep = m_blupiJeep;
|
||||
pBuffer->blupiTank = m_blupiTank;
|
||||
pBuffer->blupiSkate = m_blupiSkate;
|
||||
pBuffer->blupiNage = m_blupiNage;
|
||||
pBuffer->blupiSurf = m_blupiSurf;
|
||||
pBuffer->blupiVent = m_blupiVent;
|
||||
pBuffer->blupiSuspend = m_blupiSuspend;
|
||||
pBuffer->blupiJumpAie = m_blupiJumpAie;
|
||||
pBuffer->blupiShield = m_blupiShield;
|
||||
pBuffer->blupiPower = m_blupiPower;
|
||||
pBuffer->blupiCloud = m_blupiCloud;
|
||||
pBuffer->blupiHide = m_blupiHide;
|
||||
pBuffer->blupiInvert = m_blupiInvert;
|
||||
pBuffer->blupiBalloon = m_blupiBalloon;
|
||||
pBuffer->blupiEcrase = m_blupiEcrase;
|
||||
pBuffer->blupiPosHelico = m_blupiPosHelico;
|
||||
pBuffer->blupiPosMagic = m_blupiPosMagic;
|
||||
pBuffer->blupiRestart = m_blupiRestart;
|
||||
pBuffer->blupiFront = m_blupiFront;
|
||||
pBuffer->blupiBullet = m_blupiBullet;
|
||||
pBuffer->blupiCle = m_blupiCle;
|
||||
pBuffer->blupiPerso = m_blupiPerso;
|
||||
pBuffer->blupiDynamite = m_blupiDynamite;
|
||||
pBuffer->blupiNoBarre = m_blupiNoBarre;
|
||||
pBuffer->blupiTimeShield = m_blupiTimeShield;
|
||||
pBuffer->blupiTimeFire = m_blupiTimeFire;
|
||||
pBuffer->blupiTimeNoAsc = m_blupiTimeNoAsc;
|
||||
pBuffer->blupiTimeOuf = m_blupiTimeOuf;
|
||||
pBuffer->blupiActionOuf = m_blupiActionOuf;
|
||||
pBuffer->blupiFifoNb = m_blupiFifoNb;
|
||||
memcpy(pBuffer->blupiFifoPos, m_blupiFifoPos, sizeof(pBuffer->blupiFifoPos));
|
||||
memcpy(pBuffer->blupiStartPos, m_blupiStartPos, sizeof(pBuffer->blupiStartPos));
|
||||
pBuffer->blupiStartDir[0] = m_blupiStartDir[0];
|
||||
pBuffer->blupiStartDir[1] = m_blupiStartDir[1];
|
||||
pBuffer->blupiStartDir[2] = m_blupiStartDir[2];
|
||||
pBuffer->blupiStartDir[3] = m_blupiStartDir[3];
|
||||
pBuffer->jaugeHide[0] = m_jauges[0].GetHide();
|
||||
pBuffer->jaugeHide[1] = m_jauges[1].GetHide();
|
||||
pBuffer->jaugeType[0] = m_jauges[0].GetType();
|
||||
pBuffer->jaugeType[1] = m_jauges[1].GetType();
|
||||
pBuffer->jaugeLevel[0] = m_jauges[0].GetLevel();
|
||||
pBuffer->jaugeLevel[1] = m_jauges[1].GetLevel();
|
||||
pBuffer->blupiLevel = m_blupiLevel;
|
||||
pBuffer->energyUnused = m_blupiEnergyUnused;
|
||||
pBuffer->bHelicoMarch = m_bHelicoMarch;
|
||||
pBuffer->bHelicoStop = m_bHelicoStop;
|
||||
pBuffer->bJeepMarch = m_bJeepMarch;
|
||||
pBuffer->bJeepStop = m_bJeepStop;
|
||||
pBuffer->bFoundCle = m_bFoundCle;
|
||||
pBuffer->bPrivate = m_bPrivate;
|
||||
pBuffer->bCheatDoors = m_bCheatDoors;
|
||||
pBuffer->bSuperBlupi = m_bSuperBlupi;
|
||||
pBuffer->bDrawSecret = m_bDrawSecret;
|
||||
pBuffer->bJoystick = m_bJoystick;
|
||||
pBuffer->mission = m_mission;
|
||||
memcpy(pBuffer->doors, m_doors, sizeof(pBuffer->doors));
|
||||
pBuffer->nbVies = m_nbVies;
|
||||
pBuffer->nbTresor = m_nbTresor;
|
||||
pBuffer->totalTresor = m_totalTresor;
|
||||
pBuffer->goalPhase = m_goalPhase;
|
||||
pBuffer->d8f8 = m_D8F8;
|
||||
pBuffer->scrollPoint = m_scrollPoint;
|
||||
pBuffer->scrollAdd = m_scrollAdd;
|
||||
pBuffer->voyageIcon = m_voyageIcon;
|
||||
pBuffer->voyageChannel = m_voyageChannel;
|
||||
pBuffer->voyagePhase = m_voyagePhase;
|
||||
pBuffer->voyageTotal = m_voyageTotal;
|
||||
pBuffer->voyageStart = m_voyageStart;
|
||||
pBuffer->voyageEnd = m_voyageEnd;
|
||||
pBuffer->decorAction = m_decorAction;
|
||||
pBuffer->decorPhase = m_decorPhase;
|
||||
|
||||
if (fwrite(pBuffer, sizeof(DescSave), 1, file) >= 1)
|
||||
{
|
||||
free(pBuffer);
|
||||
fclose(file);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
error:
|
||||
if (pBuffer != NULL) free(pBuffer);
|
||||
if (file != NULL) fclose(file);
|
||||
return FALSE;
|
||||
|
||||
}
|
||||
|
||||
BOOL CDecor::CurrentRead(int gamer, int mission, BOOL *pbMission, BOOL *pbPrivate)
|
||||
{
|
||||
char filename[MAX_PATH];
|
||||
FILE* file = NULL;
|
||||
DescFile* pBuffer = NULL;
|
||||
int majRev, minRev;
|
||||
int nb, i, x, y;
|
||||
|
||||
sprintf(filename, "data\\s%.3d-%.3d.blp", gamer, mission);
|
||||
AddUserPath(filename);
|
||||
|
||||
file = fopen(filename, "rb");
|
||||
if (file == NULL) goto error;
|
||||
|
||||
pBuffer = (DescFile*)malloc(sizeof(DescFile));
|
||||
if (pBuffer == NULL) goto error;
|
||||
|
||||
nb = fread(pBuffer, sizeof(DescFile), 1, file);
|
||||
if (nb < 1) goto error;
|
||||
|
||||
majRev = pBuffer->majRev;
|
||||
|
||||
return TRUE;
|
||||
|
||||
error:
|
||||
if (pBuffer != NULL) free(pBuffer);
|
||||
if (file != NULL) fclose(file);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CDecor::MissionStart(int gamer, int mission, char* param3)
|
||||
{
|
||||
char filename[MAX_PATH];
|
||||
FILE* file = NULL;
|
||||
DescFile* pBuffer = NULL;
|
||||
int majRev, minRev;
|
||||
int nb, i, x, y;
|
||||
|
||||
sprintf(filename, "data\\s%.3d-%.3d.blp", gamer, mission);
|
||||
AddUserPath(filename);
|
||||
file = fopen(filename, "wb");
|
||||
if (file == NULL) goto error;
|
||||
|
||||
pBuffer = (DescFile*)malloc(sizeof(DescFile));
|
||||
if (pBuffer == NULL) goto error;
|
||||
|
||||
return TRUE;
|
||||
|
||||
error:
|
||||
if (pBuffer != NULL) free(pBuffer);
|
||||
if (file != NULL) fclose(file);
|
||||
return FALSE;
|
||||
}
|
2308
src/decmove.cpp
Normal file
464
src/decnet.cpp
Normal file
@ -0,0 +1,464 @@
|
||||
// DecNet.cpp
|
||||
//
|
||||
|
||||
#include "def.h"
|
||||
#include "decor.h"
|
||||
#include "misc.h"
|
||||
#include "network.h"
|
||||
|
||||
void CDecor::NetStopCloud(int rank)
|
||||
{
|
||||
NetMessage msg;
|
||||
|
||||
msg.type = MESS_STOPCLOUD;
|
||||
msg.data1 = 0;
|
||||
msg.data2 = 0;
|
||||
msg.data3 = 0;
|
||||
msg.data4 = rank;
|
||||
NetMessagePush(&msg);
|
||||
return;
|
||||
}
|
||||
|
||||
void CDecor::NetPlaySound(short channel, POINT pos)
|
||||
{
|
||||
NetMessage msg;
|
||||
|
||||
msg.type = MESS_PLAYSOUND;
|
||||
msg.data1 = 0;
|
||||
msg.data2 = pos.x;
|
||||
msg.data3 = pos.y;
|
||||
msg.data4 = channel;
|
||||
NetMessagePush(&msg);
|
||||
return;
|
||||
}
|
||||
|
||||
void CDecor::NetStopSound(short channel)
|
||||
{
|
||||
NetMessage msg;
|
||||
|
||||
msg.type = MESS_STOPSOUND;
|
||||
msg.data1 = 0;
|
||||
msg.data2 = 0;
|
||||
msg.data3 = 0;
|
||||
msg.data4 = channel;
|
||||
NetMessagePush(&msg);
|
||||
}
|
||||
|
||||
void CDecor::NetDataFlush()
|
||||
{
|
||||
for (int i = 0; i < MAXNETPLAYER; i++)
|
||||
{
|
||||
m_netBlupiPos[i].x = 0;
|
||||
m_netBlupiPos[i].y = 0;
|
||||
m_netBlupiIcon[i] = -1;
|
||||
m_netBlupiSec[i] = 0;
|
||||
m_netBlupiTransport[i] = 0;
|
||||
m_netTransports[i] = 0;
|
||||
m_netTimes[i] = 0;
|
||||
m_netPrevTimes[i] = 0;
|
||||
m_netTimeSincePacket[i] = 0;
|
||||
m_netVitesses[i].x = 0;
|
||||
m_netVitesses[i].y = 0;
|
||||
m_netBlupiPrevPos[i].x = 0;
|
||||
m_netBlupiPrevPos[i].y = 0;
|
||||
}
|
||||
m_netPacketsSent = 0;
|
||||
m_netPacketsSent2 = 0;
|
||||
m_netPacketsReceived = 0;
|
||||
m_netPacketsReceived2 = 0;
|
||||
m_netPacketIcon = -1;
|
||||
NetMessageIndexFlush();
|
||||
}
|
||||
|
||||
void CDecor::NetSendBarePacket(BYTE type, short num)
|
||||
{
|
||||
char data[4];
|
||||
data[0] = 4;
|
||||
data[1] = type;
|
||||
data[2] = num & 0xff;
|
||||
data[3] = num >> 8;
|
||||
m_pNetwork->Send(&data, 4, DPSEND_GUARANTEED);
|
||||
return;
|
||||
}
|
||||
|
||||
void CDecor::TreatNetData()
|
||||
{
|
||||
NetPacket pack;
|
||||
NetMessage* pMsg;
|
||||
int i, j, dt;
|
||||
int flag = 0;
|
||||
int player;
|
||||
int foo;
|
||||
char res[100];
|
||||
char text[100];
|
||||
|
||||
BOOL recentSenders[MAXNETPLAYER];
|
||||
|
||||
if ((m_netMessageIndex1 != 0 ||
|
||||
m_blupiIcon != m_netPacketIcon ||
|
||||
m_blupiPos != m_netPacketPos) &&
|
||||
!m_bNetPacked || m_time % 2 == 0)
|
||||
{
|
||||
m_netPacketPos = m_blupiPos;
|
||||
m_netPacketIcon = m_blupiIcon;
|
||||
pack.time = m_time;
|
||||
pack.keyPress = m_keyPress;
|
||||
pack.blupiPosX = m_blupiPos.x;
|
||||
pack.blupiPosY = m_blupiPos.y;
|
||||
pack.blupiIcon = m_blupiIcon;
|
||||
pack.size = sizeof(pack);
|
||||
pack.type = 1;
|
||||
pack.blupiSec = m_blupiSec;
|
||||
pack.blupiChannel = m_blupiChannel;
|
||||
pack.blupiTransport = m_blupiTransport;
|
||||
pack.nbMessages = 0;
|
||||
for (i = 0; i < MAXMESSAGEPERPACKET; i++)
|
||||
{
|
||||
if (!NetMessagePop(&pack.messages[i]))
|
||||
{
|
||||
break;
|
||||
}
|
||||
pack.nbMessages++;
|
||||
if (pack.messages[i].type == MESS_OBJECTSTART ||
|
||||
pack.messages[i].type == MESS_OBJECTDELETE)
|
||||
{
|
||||
if (pack.messages[i].data4 != TYPE_EXPLO1 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO2 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO3 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO4 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO5 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO6 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO7 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO8 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO9 &&
|
||||
pack.messages[i].data4 != TYPE_EXPLO10 &&
|
||||
pack.messages[i].data4 != TYPE_SPLOUTCH1 &&
|
||||
pack.messages[i].data4 != TYPE_SPLOUTCH2 &&
|
||||
pack.messages[i].data4 != TYPE_SPLOUTCH3 &&
|
||||
pack.messages[i].data4 != TYPE_TENTACULE &&
|
||||
pack.messages[i].data4 != TYPE_PLOUF &&
|
||||
pack.messages[i].data4 != TYPE_BLUP &&
|
||||
pack.messages[i].data4 != TYPE_MAGICTRACK &&
|
||||
pack.messages[i].data4 != TYPE_SHIELDTRACK &&
|
||||
pack.messages[i].data4 != TYPE_TRESORTRACK &&
|
||||
pack.messages[i].data4 != TYPE_TIPLOUF &&
|
||||
pack.messages[i].data4 != TYPE_INVERTSTART &&
|
||||
pack.messages[i].data4 != TYPE_INVERTSTOP &&
|
||||
pack.messages[i].data4 != TYPE_POLLUTION)
|
||||
{
|
||||
flag = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
pack.unk12 = flag;
|
||||
m_pNetwork->Send(&pack, sizeof(NetMessage) * pack.nbMessages + 20, flag);
|
||||
m_netPacketsSent++;
|
||||
if (flag) m_netPacketsSent2++;
|
||||
}
|
||||
|
||||
ZeroMemory(&recentSenders, sizeof(recentSenders));
|
||||
|
||||
for (i = 0; i < 10; i++)
|
||||
{
|
||||
if (!m_pNetwork->Receive(&pack, sizeof(pack), (LPDWORD)&player))
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
if (pack.type == 1)
|
||||
{
|
||||
m_netPacketsReceived++;
|
||||
if (pack.unk12) m_netPacketsReceived2++;
|
||||
|
||||
if (player < MAXNETPLAYER)
|
||||
{
|
||||
if (pack.time > m_netTimes[player])
|
||||
{
|
||||
m_netPrevTimes[player] = m_netTimes[player];
|
||||
recentSenders[player] = TRUE;
|
||||
m_netTimes[player] = pack.time;
|
||||
m_netBlupiPos[player].x = pack.blupiPosX;
|
||||
m_netBlupiPos[player].y = pack.blupiPosY;
|
||||
m_netBlupiIcon[player] = pack.blupiIcon;
|
||||
m_netBlupiSec[player] = pack.blupiSec;
|
||||
m_netBlupiTransport[player] = pack.blupiTransport;
|
||||
dt = pack.time - m_netPrevTimes[player];
|
||||
if (dt <= 0)
|
||||
{
|
||||
m_netVitesses[player] = POINT(0, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_netVitesses[player] = (m_netBlupiPos[player] - m_netBlupiPrevPos[player]) / dt;
|
||||
}
|
||||
m_netBlupiPrevPos[player] = m_netBlupiPos[player];
|
||||
m_netTimeSincePacket[player] = 0;
|
||||
}
|
||||
}
|
||||
for (j = 0; j < pack.nbMessages; j++)
|
||||
{
|
||||
pMsg = &pack.messages[j];
|
||||
switch (pMsg->type)
|
||||
{
|
||||
case MESS_OBJECTSTART:
|
||||
ObjectStart(POINT(pMsg->data2, pMsg->data3), pMsg->data4, pMsg->data1, FALSE);
|
||||
break;
|
||||
case MESS_OBJECTDELETE:
|
||||
ObjectDelete(POINT(pMsg->data2, pMsg->data3), pMsg->data4, FALSE);
|
||||
break;
|
||||
case MESS_MODIFDECOR:
|
||||
ModifDecor(POINT(pMsg->data2, pMsg->data3), pMsg->data4, FALSE);
|
||||
break;
|
||||
case MESS_PLAYSOUND:
|
||||
m_pSound->PlayImage(pMsg->data4, POINT(pMsg->data2, pMsg->data3) - m_posDecor, -1);
|
||||
break;
|
||||
case MESS_STOPSOUND:
|
||||
m_pSound->StopSound(pMsg->data4);
|
||||
break;
|
||||
case MESS_ASCENSEURSTART:
|
||||
NetAscenseurSynchro(pMsg->data4, STEP_STOPSTART);
|
||||
break;
|
||||
case MESS_ASCENSEUREND:
|
||||
NetAscenseurSynchro(pMsg->data4, STEP_STOPEND);
|
||||
break;
|
||||
case MESS_STOPCLOUD:
|
||||
if (pMsg->data4 == m_team)
|
||||
{
|
||||
m_blupiCloud = FALSE;
|
||||
m_jauges[JAUGE_POWER].SetHide(TRUE);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (pack.type == PK_LEAVE)
|
||||
{
|
||||
LoadString(257, res, 100);
|
||||
sprintf(text, res, m_pNetwork->m_players[player].name);
|
||||
NotifPush(text);
|
||||
m_pNetwork->m_players[player].bIsPresent = 0;
|
||||
m_netBlupiIcon[player] = -1;
|
||||
}
|
||||
if (pack.type == PK_LOST)
|
||||
{
|
||||
LoadString(258, res, 100);
|
||||
sprintf(text, res, m_pNetwork->m_players[player].name);
|
||||
NotifPush(text);
|
||||
m_pNetwork->m_players[player].bIsPresent = 0;
|
||||
m_netBlupiIcon[player] = -1;
|
||||
}
|
||||
if (pack.type == PK_DIE)
|
||||
{
|
||||
if (pack.keyPress == 0)
|
||||
{
|
||||
LoadString(261, res, 100);
|
||||
}
|
||||
else if (pack.keyPress == 1)
|
||||
{
|
||||
LoadString(260, res, 100);
|
||||
}
|
||||
else
|
||||
{
|
||||
LoadString(259, res, 100);
|
||||
}
|
||||
sprintf(text, res, m_pNetwork->m_players[player].name, pack.keyPress);
|
||||
NotifPush(text);
|
||||
}
|
||||
if (pack.type == PK_PAUSE)
|
||||
{
|
||||
m_bPause = pack.keyPress;
|
||||
}
|
||||
}
|
||||
|
||||
for (i = 0; i < MAXNETPLAYER; i++)
|
||||
{
|
||||
if (!recentSenders[i])
|
||||
{
|
||||
DoNetSmooth(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::DoNetSmooth(int player)
|
||||
{
|
||||
POINT start, end;
|
||||
RECT rect;
|
||||
|
||||
if (m_bNetMovePredict && m_netBlupiIcon[player] != -1)
|
||||
{
|
||||
if (m_netTimeSincePacket[player] < 5)
|
||||
{
|
||||
start = m_netBlupiPos[player];
|
||||
end = start + m_netVitesses[player];
|
||||
rect = RECT(start.x + 12, start.y + 11, start.x + DIMBLUPIX - 12, start.y + DIMBLUPIY - 2);
|
||||
TestPath(rect, start, &end);
|
||||
m_netBlupiPos[player] = end;
|
||||
}
|
||||
m_netTimeSincePacket[player]++;
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::NetAdjustToLift()
|
||||
{
|
||||
for (int i = 0; i < MAXNETPLAYER; i++)
|
||||
{
|
||||
if (m_netBlupiPos[i].x != -1 && m_netTransports[i] >= 0 && m_netTransports[i] < MAXMOVEOBJECT)
|
||||
{
|
||||
m_netBlupiPos[i].y = m_moveObject[m_netTransports[i]].posCurrent.y - (DIMBLUPIY - 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::NetAscenseurSynchro(int index, short step)
|
||||
{
|
||||
int i;
|
||||
POINT delta;
|
||||
MoveObject* otherMob;
|
||||
MoveObject* mob = &m_moveObject[index];
|
||||
|
||||
mob->step = step;
|
||||
mob->time = 0;
|
||||
delta.x = abs(mob->posEnd.x - mob->posStart.x);
|
||||
delta.y = abs(mob->posEnd.y - mob->posStart.y);
|
||||
|
||||
for (i = 0; i < MAXMOVEOBJECT; i++)
|
||||
{
|
||||
otherMob = &m_moveObject[i];
|
||||
if (i != index && otherMob->type == mob->type)
|
||||
{
|
||||
if (otherMob->stepAdvance == mob->stepAdvance &&
|
||||
otherMob->stepRecede == mob->stepRecede &&
|
||||
otherMob->timeStopStart == mob->timeStopStart &&
|
||||
otherMob->timeStopEnd == mob->timeStopEnd)
|
||||
{
|
||||
otherMob->step = step;
|
||||
otherMob->time = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void CDecor::NetPlayerCollide(POINT pos, int* out)
|
||||
{
|
||||
int i;
|
||||
RECT rect1;
|
||||
RECT rect2;
|
||||
RECT rect3;
|
||||
|
||||
rect2.left = pos.x + 16;
|
||||
rect2.top = pos.y + 11;
|
||||
rect2.right = pos.x + DIMBLUPIX - 16;
|
||||
rect2.bottom = pos.y + DIMBLUPIY - 2;
|
||||
|
||||
for (i = 0; i < MAXNETPLAYER; i++)
|
||||
{
|
||||
if (m_netBlupiIcon[i] != -1)
|
||||
{
|
||||
if (m_netBlupiSec[i] != SEC_HIDE)
|
||||
{
|
||||
rect1.left = m_netBlupiPos[i].x + 16;
|
||||
rect1.top = m_netBlupiPos[i].y + 11;
|
||||
rect1.right = m_netBlupiPos[i].x + DIMBLUPIX - 16;
|
||||
rect1.bottom = m_netBlupiPos[i].y + DIMBLUPIY - 2;
|
||||
}
|
||||
if (IntersectRect(&rect3, &rect1, &rect2))
|
||||
{
|
||||
*out = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
*out = -1;
|
||||
}
|
||||
|
||||
void CDecor::NetMessageIndexFlush()
|
||||
{
|
||||
m_netMessageIndex1 = 0;
|
||||
m_netMessageIndex2 = 0;
|
||||
m_netMessageIndex3 = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
BOOL CDecor::NetMessagePush(NetMessage* message)
|
||||
{
|
||||
NetMessage* messages;
|
||||
BYTE data;
|
||||
short pos;
|
||||
int i;
|
||||
|
||||
if (m_netMessageIndex1 == MAXNETMESSAGE) return FALSE;
|
||||
|
||||
CopyMemory(&m_netMessages[m_netMessageIndex2], message, sizeof(NetMessage));
|
||||
m_netMessageIndex1++;
|
||||
m_netMessageIndex2++;
|
||||
if (m_netMessageIndex2 == MAXNETMESSAGE)
|
||||
{
|
||||
m_netMessageIndex2 = 0;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
BOOL CDecor::NetMessagePop(NetMessage* out_msg)
|
||||
{
|
||||
int i;
|
||||
|
||||
if (m_netMessageIndex1 == 0) return FALSE;
|
||||
|
||||
CopyMemory(out_msg, &m_netMessages[m_netMessageIndex3], sizeof(NetMessage));
|
||||
m_netMessageIndex1--;
|
||||
m_netMessageIndex3++;
|
||||
if (m_netMessageIndex3 == MAXNETMESSAGE)
|
||||
{
|
||||
m_netMessageIndex3 = 0;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void CDecor::NotifFlush()
|
||||
{
|
||||
for (int i = 0; i < MAXNOTIF; i++)
|
||||
{
|
||||
m_notifText[i][0] = '\0';
|
||||
}
|
||||
|
||||
m_notifTime = 0;
|
||||
}
|
||||
|
||||
void CDecor::NotifPop()
|
||||
{
|
||||
for (int i = MAXNOTIF; i > 0; --i)
|
||||
{
|
||||
//strcpy()
|
||||
m_notifText[MAXNOTIF - 1][0] = '\0';
|
||||
m_notifTime = NOTIFDELAY; // idk
|
||||
}
|
||||
}
|
||||
|
||||
void CDecor::NotifPush(char *str)
|
||||
{
|
||||
int i;
|
||||
for (i = 0; i < MAXNOTIF; i++)
|
||||
{
|
||||
if (m_notifText[i][0] != '\0') break;
|
||||
}
|
||||
if (i >= MAXNOTIF)
|
||||
{
|
||||
NotifPop();
|
||||
i = MAXNOTIF - 1;
|
||||
}
|
||||
strcpy(m_notifText[i], str);
|
||||
m_notifTime = NOTIFDELAY;
|
||||
m_pSound->PlayImage(SOUND_TRESOR, POINT( LXIMAGE / 2, LYIMAGE / 2 ), -1);
|
||||
}
|
||||
|
||||
void CDecor::NotifStep()
|
||||
{
|
||||
if (m_notifTime == 0)
|
||||
{
|
||||
NotifPop();
|
||||
}
|
||||
else {
|
||||
m_notifTime--;
|
||||
}
|
||||
}
|
||||
|
2042
src/decor.cpp
Normal file
645
src/decor.h
Normal file
@ -0,0 +1,645 @@
|
||||
// Decor.h
|
||||
#ifndef DECOR_H
|
||||
#define DECOR_H
|
||||
|
||||
#include "DEF.H"
|
||||
#include "jauge.h"
|
||||
#include "sound.h"
|
||||
#include "pixmap.h"
|
||||
#include "network.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#define MAXQUART 441
|
||||
#define SCROLL_SPEED 8
|
||||
#define SCROLL_MARGX 80
|
||||
#define SCROLL_MARGY 40
|
||||
|
||||
#define BLUPIFLOOR 2
|
||||
#define BLUPIOFFY 4 + BLUPIFLOOR
|
||||
#define BLUPISURF 12
|
||||
#define BLUPISUSPEND 12
|
||||
#define OVERHEIGHT 80
|
||||
|
||||
#define TEXTDELAY 10 // tooltip popup delay
|
||||
#define NOTIFDELAY 200
|
||||
|
||||
typedef struct
|
||||
{
|
||||
short icon;
|
||||
}
|
||||
Cellule;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
short type;
|
||||
short stepAdvance;
|
||||
short stepRecede;
|
||||
short timeStopStart;
|
||||
short timeStopEnd;
|
||||
short unknown1;
|
||||
POINT posStart;
|
||||
POINT posEnd;
|
||||
POINT posCurrent;
|
||||
short step;
|
||||
short time;
|
||||
short phase;
|
||||
short channel;
|
||||
short icon;
|
||||
short unknown2;
|
||||
}
|
||||
MoveObject;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
char type;
|
||||
char data1;
|
||||
short data2;
|
||||
short data3;
|
||||
short data4;
|
||||
}
|
||||
NetMessage;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
char size;
|
||||
char type;
|
||||
short keyPress;
|
||||
int time;
|
||||
short blupiPosX;
|
||||
short blupiPosY;
|
||||
short blupiIcon;
|
||||
short blupiSec;
|
||||
char blupiChannel;
|
||||
char blupiTransport;
|
||||
char unk12;
|
||||
char nbMessages;
|
||||
NetMessage messages[MAXMESSAGEPERPACKET];
|
||||
}
|
||||
NetPacket;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
short majRev;
|
||||
short minRev;
|
||||
short reserve1[100];
|
||||
POINT posDecor;
|
||||
POINT dimDecor;
|
||||
short world;
|
||||
short music;
|
||||
short region;
|
||||
short reserve2[51];
|
||||
POINT blupiPos[4];
|
||||
int blupiDir[4];
|
||||
char name[100];
|
||||
short reserve3[196];
|
||||
}
|
||||
DescFile;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int lg;
|
||||
int majRev;
|
||||
int minRev;
|
||||
int reserve1[50];
|
||||
short decor[100][100];
|
||||
short bigDecor[100][100];
|
||||
char balleTraj[100][13];
|
||||
char moveTraj[100][13];
|
||||
MoveObject moveObject[200];
|
||||
int reserve2[50];
|
||||
POINT posDecor;
|
||||
POINT dimDecor;
|
||||
int phase;
|
||||
int term;
|
||||
int music;
|
||||
int region;
|
||||
int time;
|
||||
char missionTitle[100];
|
||||
int reserve3[50];
|
||||
int nbRankCaisse;
|
||||
int rankCaisse[200];
|
||||
int nbLinkCaisse;
|
||||
int linkCaisse[200];
|
||||
int reserve4[50];
|
||||
POINT blupiPos;
|
||||
POINT blupiValidPos;
|
||||
int blupiAction;
|
||||
int blupiDir;
|
||||
int blupiPhase;
|
||||
POINT blupiVitesse;
|
||||
int blupiIcon;
|
||||
int blupiSec;
|
||||
int blupiChannel;
|
||||
POINT blupiVector;
|
||||
int blupiTransport;
|
||||
BOOL blupiFocus;
|
||||
BOOL blupiAir;
|
||||
BOOL blupiHelico;
|
||||
BOOL blupiJeep;
|
||||
BOOL blupiTank;
|
||||
BOOL blupiSkate;
|
||||
BOOL blupiNage;
|
||||
BOOL blupiSurf;
|
||||
BOOL blupiVent;
|
||||
BOOL blupiSuspend;
|
||||
BOOL blupiJumpAie;
|
||||
BOOL blupiShield;
|
||||
BOOL blupiPower;
|
||||
BOOL blupiCloud;
|
||||
BOOL blupiHide;
|
||||
POINT blupiPosHelico;
|
||||
POINT blupiPosMagic;
|
||||
BOOL blupiRestart;
|
||||
BOOL blupiFront;
|
||||
int blupiBullet;
|
||||
int blupiCle;
|
||||
int blupiPerso;
|
||||
int blupiNoBarre;
|
||||
int blupiTimeShield;
|
||||
int blupiTimeFire;
|
||||
int blupiTimeOuf;
|
||||
int blupiActionOuf;
|
||||
int blupiFifoNb;
|
||||
POINT blupiFifoPos[MAXFIFOPOS];
|
||||
BOOL blupiInvert;
|
||||
BOOL blupiBalloon;
|
||||
BOOL blupiOver;
|
||||
BOOL blupiEcrase;
|
||||
int blupiTimeNoAsc;
|
||||
int blupiDynamite;
|
||||
int reserve5[41];
|
||||
POINT blupiStartPos[4];
|
||||
int blupiStartDir[4];
|
||||
int reserve6[50];
|
||||
BOOL jaugeHide[2];
|
||||
BOOL jaugeType[2];
|
||||
BOOL jaugeLevel[2];
|
||||
int blupiLevel;
|
||||
int energyUnused;
|
||||
int reserve7[50];
|
||||
BOOL bHelicoMarch;
|
||||
BOOL bHelicoStop;
|
||||
BOOL bJeepMarch;
|
||||
BOOL bJeepStop;
|
||||
int reserve8[50];
|
||||
BOOL bFoundCle;
|
||||
BOOL bPrivate;
|
||||
BOOL bCheatDoors;
|
||||
BOOL bSuperBlupi;
|
||||
BOOL bDrawSecret;
|
||||
BOOL bJoystick;
|
||||
int idklol;
|
||||
int mission;
|
||||
char doors[200];
|
||||
int nbVies;
|
||||
int nbTresor;
|
||||
int totalTresor;
|
||||
int goalPhase;
|
||||
int reserve9[50];
|
||||
int d8f8;
|
||||
POINT scrollPoint;
|
||||
POINT scrollAdd;
|
||||
int reserve10[50];
|
||||
int voyageIcon;
|
||||
int voyageChannel;
|
||||
int voyagePhase;
|
||||
int voyageTotal;
|
||||
POINT voyageStart;
|
||||
POINT voyageEnd;
|
||||
int reserve11[50];
|
||||
int decorAction;
|
||||
int decorPhase;
|
||||
int reserve12[50];
|
||||
}
|
||||
DescSave;
|
||||
|
||||
class CDecor
|
||||
{
|
||||
public:
|
||||
CDecor();
|
||||
~CDecor();
|
||||
|
||||
// Decor.cpp
|
||||
void Create(HWND hWnd, CSound *pSound, CPixmap *pPixmap,
|
||||
CNetwork *pNetwork);
|
||||
BOOL LoadImages();
|
||||
void InitGamer();
|
||||
void InitDecor();
|
||||
void SetTime(int time);
|
||||
int GetTime();
|
||||
void PlayPrepare(BOOL bTest);
|
||||
void BuildPrepare();
|
||||
int IsTerminated();
|
||||
void MoveStep();
|
||||
int GetBlupiChannelStandard();
|
||||
int GetBlupiChannelActual();
|
||||
int GetIconPerso();
|
||||
void Build(RECT rect);
|
||||
void DrawInfo();
|
||||
POINT DecorNextAction();
|
||||
void SetInput(int keys);
|
||||
void SetJoystickEnable(BOOL bJoystick);
|
||||
void SetDemoPlay(BOOL param_1);
|
||||
void PlaySound(int sound, POINT pos, BOOL bLocal);
|
||||
void PlaySound(int sound, POINT pos); // hack
|
||||
void StopSound(int sound);
|
||||
void AdaptMotorVehicleSound(POINT pos);
|
||||
void VehicleSoundsPhase(int phase);
|
||||
|
||||
int GetRegion();
|
||||
void SetRegion(int region);
|
||||
int GetMusic();
|
||||
void SetMusic(int music);
|
||||
POINT GetDim();
|
||||
void SetDim(POINT dim);
|
||||
int GetNbVies();
|
||||
void SetNbVies(int nbVies);
|
||||
BOOL GetPause();
|
||||
void SetPause(BOOL bPause);
|
||||
void InitializeDoors(BYTE *doors);
|
||||
void MemorizeDoors(BYTE* doors);
|
||||
void SetAllMissions(BOOL bAllMissions);
|
||||
void CheatAction(int cheat);
|
||||
BOOL GetSuperBlupi();
|
||||
void SetSuperBlupi(BOOL bSuperBlupi);
|
||||
BOOL GetDrawSecret();
|
||||
void SetDrawSecret(BOOL bDrawSecret);
|
||||
void SetBuildOfficialMissions(BOOL bBuildOfficialMissions);
|
||||
BOOL GetNetPacked();
|
||||
void SetNetPacked(BOOL bNetPacked);
|
||||
BOOL GetNetMovePredict();
|
||||
void SetNetMovePredict(BOOL bNetMovePredict);
|
||||
BOOL GetNetDebug();
|
||||
void SetNetDebug(BOOL bNetDebug);
|
||||
void OutputNetDebug(char* text);
|
||||
void SetMulti(BOOL bMulti);
|
||||
void SetTeam(int team);
|
||||
POINT VoyageGetPosVie(int nbVies);
|
||||
void VoyageInit(POINT start, POINT end, int icon, int channel);
|
||||
void VoyageStep();
|
||||
void VoyageDraw();
|
||||
BOOL DrawMap(BOOL bPlay, int team);
|
||||
|
||||
// DecBlock.cpp
|
||||
BOOL BlitzActif(POINT cel);
|
||||
int SoundEnviron(int sound, int obstacle);
|
||||
int IsWorld(POINT pos);
|
||||
void ActiveSwitch(BOOL bState, POINT cel);
|
||||
int GetTypeBarre(POINT pos);
|
||||
BOOL IsLave(POINT pos);
|
||||
BOOL IsPiege(POINT pos);
|
||||
BOOL IsGoutte(POINT pos, BOOL bAlways);
|
||||
BOOL IsScie(POINT pos);
|
||||
BOOL IsSwitch(POINT pos, POINT *outCelSwitch);
|
||||
BOOL IsEcraseur(POINT pos);
|
||||
BOOL IsBlitz(POINT pos, BOOL bAlways);
|
||||
BOOL IsRessort(POINT pos);
|
||||
BOOL IsTemp(POINT pos);
|
||||
BOOL IsBridge(POINT pos, POINT *outCelBridge);
|
||||
int IsDoor(POINT pos, POINT *outCelPorte);
|
||||
int IsTeleporte(POINT pos);
|
||||
BOOL SearchTeleporte(POINT pos, POINT *newpos);
|
||||
BOOL IsSurfWater(POINT pos);
|
||||
BOOL IsDeepWater(POINT pos);
|
||||
BOOL IsOutWater(POINT pos);
|
||||
BOOL IsPassIcon(int icon);
|
||||
BOOL IsBlocIcon(int icon);
|
||||
BOOL IsVentillo(POINT pos);
|
||||
void ModifDecor(POINT pos, int icon, BOOL bMulti=TRUE);
|
||||
BOOL IsRightBorder(POINT cel, POINT offset);
|
||||
BOOL IsFromage(POINT cel);
|
||||
BOOL IsGrotte(POINT cel);
|
||||
void AdaptMidBorder(POINT cel);
|
||||
void AdaptBorder(POINT cel);
|
||||
|
||||
// DecDesign.cpp
|
||||
POINT ScreenPosToCelPos(POINT pos);
|
||||
void SetCelPosFromScreenPos(POINT pos);
|
||||
void SetFieldCC38AndStuff(int _foo, int _bar);
|
||||
void DeleteCel(POINT cel);
|
||||
void PlaceMenuItem(short *pCel, int *pTable, int lastIndex, BYTE flags, int currentIcon, BOOL bRand);
|
||||
void PlaceItemFromMenu1(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu2(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu3(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu4(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu5(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu6(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu7(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu8(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu9(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
void PlaceItemFromMenu10(POINT cel, int index, BYTE flags, int currentIcon);
|
||||
char* GetMissionTitle();
|
||||
void SetMissionTitle(char *str);
|
||||
|
||||
// DecBlupi.cpp
|
||||
void BlupiSearchIcon();
|
||||
BOOL BlupiIsGround();
|
||||
RECT BlupiRect(POINT pos);
|
||||
void BlupiAdjust();
|
||||
BOOL BlupiBloque(POINT pos, int dir);
|
||||
void BlupiStep();
|
||||
void BlupiDead(int action, int action2);
|
||||
POINT GetPosDecor(POINT pos);
|
||||
void BlupiAddFifo(POINT pos);
|
||||
BOOL DecorDetect(RECT rect, BOOL bCaisse=TRUE);
|
||||
void GetBlupiInfo(BOOL *pbHelico, BOOL *pbJeep, BOOL *pbSkate,
|
||||
BOOL *pbNage);
|
||||
|
||||
// DecMove.cpp
|
||||
BOOL TestPath(RECT rect, POINT start, POINT *end);
|
||||
void MoveObjectPollution();
|
||||
void MoveObjectPlouf(POINT pos);
|
||||
void MoveObjectTiplouf(POINT pos);
|
||||
void MoveObjectBlup(POINT pos);
|
||||
void FlushBalleTraj();
|
||||
void SetBalleTraj(POINT pos);
|
||||
BOOL IsBalleTraj(POINT pos);
|
||||
void FlushMoveTraj();
|
||||
void SetMoveTraj(POINT pos);
|
||||
BOOL IsMoveTraj(POINT pos);
|
||||
int SearchDistRight(POINT pos, POINT dir, int type);
|
||||
void StartSploutchGlu(POINT pos);
|
||||
BOOL ObjectStart(POINT pos, int type, int speed);
|
||||
BOOL ObjectStart(POINT pos, int type, int speed, BOOL bMulti);
|
||||
BOOL ObjectDelete(POINT pos, int type, BOOL bMulti = TRUE);
|
||||
void MoveObjectStep();
|
||||
void MoveObjectStepLine(int i);
|
||||
void MoveObjectStepIcon(int i);
|
||||
void DynamiteStart(int i, int dx, int dy);
|
||||
int AscenseurDetect(RECT rect, POINT oldpos, POINT newpos);
|
||||
void AscenseurVertigo(int i, BOOL *pbVertigoLeft, BOOL *pbVertigoRight);
|
||||
BOOL AscenseurShift(int i);
|
||||
void AscenseurSynchro(int i);
|
||||
void UpdateCaisse();
|
||||
BOOL TestPushCaisse(int i, POINT pos, BOOL bPop);
|
||||
BOOL TestPushOneCaisse(int i, POINT move, int b);
|
||||
void SearchLinkCaisse(int rank, BOOL bPop);
|
||||
BOOL AddLinkCaisse(int rank);
|
||||
int CaisseInFront();
|
||||
int CaisseGetMove(int max);
|
||||
BOOL MockeryDetect(POINT pos);
|
||||
BOOL BlupiElectro(POINT pos);
|
||||
void MoveObjectFollow(POINT pos);
|
||||
int MoveObjectDetect(POINT pos, BOOL *pbNear);
|
||||
int MoveAscenseurDetect(POINT pos, int height);
|
||||
int MoveChargeDetect(POINT pos);
|
||||
int MovePersoDetect(POINT pos);
|
||||
int MoveBalleDetect(POINT pos);
|
||||
int MoveObjectDelete(POINT pos);
|
||||
int MoveObjectFree();
|
||||
int SortGetType(int type);
|
||||
void MoveObjectSort();
|
||||
void MoveObjectPriority(int i);
|
||||
int MoveObjectSearch(POINT pos, int type);
|
||||
|
||||
// DecNet.cpp
|
||||
void NetStopCloud(int rank);
|
||||
void NetPlaySound(short channel, POINT pos);
|
||||
void NetStopSound(short channel);
|
||||
void NetDataFlush();
|
||||
void NetSendBarePacket(BYTE _foo, short _bar);
|
||||
void TreatNetData();
|
||||
void DoNetSmooth(int player);
|
||||
void NetAdjustToLift();
|
||||
void NetAscenseurSynchro(int rank, short step);
|
||||
void NetPlayerCollide(POINT pos, int *out);
|
||||
void NetMessageIndexFlush();
|
||||
BOOL NetMessagePush(NetMessage *message);
|
||||
BOOL NetMessagePop(NetMessage *message);
|
||||
void NotifFlush();
|
||||
void NotifPop();
|
||||
void NotifPush(char *str);
|
||||
void NotifStep();
|
||||
|
||||
// DecIO.cpp
|
||||
void GetMissionPath(char *out, int gamer, int mission, BOOL bUser);
|
||||
BOOL Write(int gamer, int mission, BOOL bUser);
|
||||
BOOL Read(int gamer, int mission, BOOL bUser);
|
||||
BOOL SomethingMissionPath(int gamer, int mission, BOOL bUser);
|
||||
BOOL CurrentWrite(int gamer, int mission, BOOL bUser=FALSE);
|
||||
BOOL CurrentRead(int gamer, int mission, BOOL *pbMission, BOOL *pbPrivate);
|
||||
BOOL MissionStart(int gamer, int mission, char* param3);
|
||||
|
||||
BOOL SearchWorld(int world, POINT *cel, POINT *newBlupiPos);
|
||||
BOOL SearchDoor(int n, POINT *cel);
|
||||
void AdaptDoors(BOOL bPrivate, int mission);
|
||||
void OpenDoorsTresor();
|
||||
void OpenDoor(POINT cel);
|
||||
void OpenDoorsWin();
|
||||
void OpenGoldsWin();
|
||||
void DoorsLost();
|
||||
|
||||
BOOL DeleteMission(int user, int mission, BOOL bUser);
|
||||
|
||||
inline BOOL IsValidCel(POINT cel);
|
||||
inline void MoveObjectCopy(MoveObject *src, MoveObject *dest);
|
||||
inline void StopVehicleSound();
|
||||
inline BOOL IsDeadAction(int action);
|
||||
inline void StopBlupi(BOOL bFocus = FALSE);
|
||||
inline BOOL IsBlupiVehicle();
|
||||
inline BOOL IsBlupiMotorVehicle();
|
||||
inline BOOL IsBlupiStanding();
|
||||
|
||||
protected:
|
||||
HWND m_hWnd;
|
||||
CSound* m_pSound;
|
||||
CPixmap* m_pPixmap;
|
||||
CNetwork* m_pNetwork;
|
||||
Cellule m_decor[MAXCELX][MAXCELY];
|
||||
Cellule m_bigDecor[MAXCELX][MAXCELY];
|
||||
byte m_balleTraj[MAXCELX * MAXCELY / 8 + 1];
|
||||
byte m_moveTraj[MAXCELX * MAXCELY / 8 + 1];
|
||||
MoveObject m_moveObject[MAXMOVEOBJECT];
|
||||
int m_keyPress;
|
||||
int m_lastKeyPress;
|
||||
POINT m_posDecor;
|
||||
POINT m_dimDecor;
|
||||
POINT m_posCelHili;
|
||||
POINT m_dimCelHili;
|
||||
int m_2ndPositionCalculationSlot;
|
||||
int m_phase;
|
||||
int m_term;
|
||||
int m_music;
|
||||
int m_region;
|
||||
int m_lastRegion;
|
||||
int m_iconLift;
|
||||
int m_time;
|
||||
char m_missionTitle[100];
|
||||
BOOL m_bPause;
|
||||
int m_nbRankCaisse;
|
||||
int m_rankCaisse[MAXMOVEOBJECT];
|
||||
int m_nbLinkCaisse;
|
||||
int m_linkCaisse[MAXMOVEOBJECT];
|
||||
POINT m_blupiPos;
|
||||
POINT m_blupiValidPos;
|
||||
int m_blupiAction;
|
||||
int m_blupiDir;
|
||||
int m_blupiPhase;
|
||||
POINT m_blupiVitesse;
|
||||
int m_blupiIcon;
|
||||
int m_blupiSec;
|
||||
int m_blupiChannel;
|
||||
POINT m_blupiVector;
|
||||
int m_blupiTransport;
|
||||
BOOL m_blupiFocus;
|
||||
BOOL m_blupiAir;
|
||||
BOOL m_blupiHelico;
|
||||
BOOL m_blupiOver;
|
||||
BOOL m_blupiJeep;
|
||||
BOOL m_blupiTank;
|
||||
BOOL m_blupiSkate;
|
||||
BOOL m_blupiNage;
|
||||
BOOL m_blupiSurf;
|
||||
BOOL m_blupiVent;
|
||||
BOOL m_blupiSuspend;
|
||||
BOOL m_blupiJumpAie;
|
||||
BOOL m_blupiShield;
|
||||
BOOL m_blupiPower;
|
||||
BOOL m_blupiCloud;
|
||||
BOOL m_blupiHide;
|
||||
BOOL m_blupiInvert;
|
||||
BOOL m_blupiBalloon;
|
||||
BOOL m_blupiEcrase;
|
||||
POINT m_blupiPosHelico;
|
||||
POINT m_blupiPosMagic;
|
||||
BOOL m_blupiRestart;
|
||||
BOOL m_blupiFront;
|
||||
int m_blupiBullet;
|
||||
int m_blupiCle;
|
||||
int m_blupiPerso;
|
||||
int m_blupiDynamite;
|
||||
int m_blupiNoBarre;
|
||||
int m_blupiTimeShield;
|
||||
int m_blupiTimeFire;
|
||||
int m_blupiTimeNoAsc;
|
||||
int m_blupiTimeMockery;
|
||||
int m_blupiTimeOuf;
|
||||
int m_blupiActionOuf;
|
||||
int m_blupiFifoNb;
|
||||
POINT m_blupiFifoPos[10];
|
||||
POINT m_blupiStartPos[4];
|
||||
int m_blupiStartDir[4];
|
||||
BOOL m_bMulti;
|
||||
int m_team;
|
||||
int m_netPacketsSent;
|
||||
int m_netPacketsSent2;
|
||||
int m_netPacketsReceived;
|
||||
int m_netPacketsReceived2;
|
||||
POINT m_netBlupiPos[MAXNETPLAYER];
|
||||
int m_netBlupiIcon[MAXNETPLAYER];
|
||||
int m_netBlupiSec[MAXNETPLAYER];
|
||||
int m_netBlupiTransport[MAXNETPLAYER];
|
||||
int m_netTransports[MAXNETPLAYER]; // index of lift ridden by each player, or -1
|
||||
int m_netTimes[MAXNETPLAYER];
|
||||
int m_netPrevTimes[MAXNETPLAYER];
|
||||
int m_netTimeSincePacket[MAXNETPLAYER];
|
||||
POINT m_netVitesses[MAXNETPLAYER];
|
||||
POINT m_netBlupiPrevPos[MAXNETPLAYER];
|
||||
POINT m_netPacketPos;
|
||||
int m_netPacketIcon;
|
||||
NetMessage m_netMessages[MAXNETMESSAGE];
|
||||
int m_netMessageIndex1;
|
||||
int m_netMessageIndex2;
|
||||
int m_netMessageIndex3;
|
||||
char m_notifText[MAXNOTIF][100];
|
||||
int m_notifTime;
|
||||
CJauge m_jauges[2];
|
||||
int m_blupiLevel;
|
||||
int m_blupiEnergyUnused;
|
||||
BOOL m_bHelicoMarch;
|
||||
BOOL m_bHelicoStop;
|
||||
BOOL m_bJeepMarch;
|
||||
BOOL m_bJeepStop;
|
||||
BOOL m_bFoundCle;
|
||||
BOOL m_bPrivate;
|
||||
BOOL m_bCheatDoors; // opendoors
|
||||
BOOL m_bSuperBlupi; // megablupi
|
||||
BOOL m_bDrawSecret; // showsecret
|
||||
BOOL m_bBuildOfficialMissions; // xmission/xnjttjpo
|
||||
BOOL m_bNetPacked; // netpacked
|
||||
BOOL m_bNetMovePredict; // ynosmooth
|
||||
BOOL m_bNetDebug; // znetdebug
|
||||
BOOL m_bJoystick;
|
||||
int m_bDemoPlay;
|
||||
int m_mission;
|
||||
BYTE m_doors[200];
|
||||
int m_nbVies;
|
||||
int m_nbTresor;
|
||||
int m_totalTresor;
|
||||
int m_goalPhase;
|
||||
int m_detectIcon;
|
||||
int m_D8F8;
|
||||
POINT m_scrollPoint;
|
||||
POINT m_scrollAdd;
|
||||
int m_voyageIcon;
|
||||
int m_voyageChannel;
|
||||
int m_voyagePhase;
|
||||
int m_voyageTotal;
|
||||
POINT m_voyageStart;
|
||||
POINT m_voyageEnd;
|
||||
int m_decorAction;
|
||||
int m_decorPhase;
|
||||
int m_lastDecorIndexes[200];
|
||||
int reserve[11];
|
||||
BYTE dummy[100000];
|
||||
};
|
||||
|
||||
POINT GetCel(int x, int y);
|
||||
POINT GetCel(POINT cel, int x, int y);
|
||||
POINT GetVector(int direct);
|
||||
|
||||
inline BOOL CDecor::IsValidCel(POINT cel)
|
||||
{
|
||||
return cel.x >= 0 && cel.x < MAXCELX && cel.y >= 0 && cel.y < MAXCELY;
|
||||
}
|
||||
|
||||
inline void CDecor::MoveObjectCopy(MoveObject *dest, MoveObject *src)
|
||||
{
|
||||
memcpy(dest, src, sizeof(dest));
|
||||
}
|
||||
|
||||
inline void CDecor::StopVehicleSound()
|
||||
{
|
||||
StopSound(SOUND_HELICOHIGH);
|
||||
StopSound(SOUND_HELICOLOW);
|
||||
StopSound(SOUND_JEEPHIGH);
|
||||
StopSound(SOUND_JEEPLOW);
|
||||
}
|
||||
|
||||
inline BOOL CDecor::IsDeadAction(int action)
|
||||
{
|
||||
return action == ACTION_CLEAR1 || (action >= ACTION_CLEAR2 && action <= ACTION_CLEAR8);
|
||||
}
|
||||
|
||||
inline void CDecor::StopBlupi(BOOL bSetFocus)
|
||||
{
|
||||
m_blupiAction = ACTION_STOP;
|
||||
m_blupiPhase = 0;
|
||||
if (bSetFocus) m_blupiFocus = TRUE;
|
||||
}
|
||||
|
||||
inline BOOL CDecor::IsBlupiVehicle()
|
||||
{
|
||||
return IsBlupiMotorVehicle() || m_blupiSkate;
|
||||
}
|
||||
|
||||
inline BOOL CDecor::IsBlupiMotorVehicle()
|
||||
{
|
||||
return m_blupiHelico || m_blupiOver || m_blupiJeep || m_blupiTank;
|
||||
}
|
||||
|
||||
inline BOOL CDecor::IsBlupiStanding()
|
||||
{
|
||||
return !(m_blupiAction == ACTION_TURN ||
|
||||
m_blupiAction == ACTION_JUMP ||
|
||||
m_blupiAction == ACTION_AIR ||
|
||||
m_blupiAction == ACTION_VERTIGO ||
|
||||
m_blupiAction == ACTION_ADVANCE ||
|
||||
m_blupiAction == ACTION_RECEDE) &&
|
||||
!IsBlupiVehicle() &&
|
||||
!(m_blupiAir || m_blupiBalloon || m_blupiEcrase ||
|
||||
m_blupiNage || m_blupiSurf || m_blupiSuspend);
|
||||
}
|
||||
|
||||
#endif
|
695
src/dectables.h
Normal file
@ -0,0 +1,695 @@
|
||||
#ifndef DECTABLES_H
|
||||
#define DECTABLES_H
|
||||
|
||||
#include "obstacle.h"
|
||||
|
||||
extern int table_blitz[] =
|
||||
{
|
||||
0, 7, 15, 18, 26, 27, 32, 39, 45, 47,
|
||||
50, 58, 60, 62, 64, 66, 68, 70, 71, 72,
|
||||
-1
|
||||
};
|
||||
|
||||
extern int table_vitesse_march[] =
|
||||
{
|
||||
2, 4, 6, 8
|
||||
};
|
||||
|
||||
extern int table_vitesse_nage[] =
|
||||
{
|
||||
2, 1, 5, 10, 8, 6, 4
|
||||
};
|
||||
|
||||
extern int table_vitesse_surf[] =
|
||||
{
|
||||
0, 2, 5, 8, 3, 0
|
||||
};
|
||||
|
||||
extern int table_bulldozer_left[] = { 66, 66, 67, 67, 66, 66, 65, 65 };
|
||||
|
||||
extern int table_bulldozer_right[] = { 58, 58, 57, 57, 58, 58, 59, 59 };
|
||||
|
||||
extern int table_bulldozer_turn2l[] =
|
||||
{
|
||||
58, 59, 59, 59, 60, 60, 60, 61, 61, 62,
|
||||
62, 63, 63, 64, 64, 64, 65, 65, 65, 66,
|
||||
66, 66
|
||||
};
|
||||
|
||||
extern int table_bulldozer_turn2r[] =
|
||||
{
|
||||
66, 65, 65, 65, 64, 64, 64, 63, 63, 62,
|
||||
62, 61, 61, 60, 60, 60, 59, 59, 59, 58,
|
||||
58, 58
|
||||
};
|
||||
|
||||
extern int table_poisson_left[] = { 82, 82, 81, 81, 82, 82, 83, 83 };
|
||||
|
||||
extern int table_poisson_right[] = { 79, 79, 78, 78, 79, 79, 80, 80 };
|
||||
|
||||
extern int table_poisson_turn2l[] =
|
||||
{
|
||||
79, 79, 80, 80, 84, 84, 85, 85, 86, 86,
|
||||
87, 87, 88, 88, 83, 83, 82, 82, 83, 83,
|
||||
88, 88, 87, 87, 86, 86, 85, 85, 84, 84,
|
||||
79, 79, 79, 79, 80, 80, 84, 84, 85, 85,
|
||||
86, 86, 87, 87, 88, 88, 83, 83
|
||||
};
|
||||
|
||||
extern int table_poisson_turn2r[] =
|
||||
{
|
||||
82, 82, 83, 83, 88, 88, 87, 87, 86, 86,
|
||||
85, 85, 84, 84, 79, 79, 79, 79, 80, 80,
|
||||
84, 84, 85, 85, 86, 86, 87, 87, 88, 88,
|
||||
83, 83, 82, 82, 83, 83, 88, 88, 87, 87,
|
||||
86, 86, 85, 85, 84, 84, 79, 79
|
||||
};
|
||||
|
||||
extern int table_oiseau_left[] = { 98, 99, 100, 101, 102, 103, 104, 105 };
|
||||
|
||||
extern int table_oiseau_right[] = { 90, 91, 92, 93, 94, 95, 96, 97 };
|
||||
|
||||
extern int table_oiseau_turn2l[] = { 106, 107, 108, 109, 110, 111, 112, 113, 105, 105 };
|
||||
|
||||
extern int table_oiseau_turn2r[] = { 114, 115, 116, 117, 118, 119, 120, 121, 97, 97 };
|
||||
|
||||
extern int table_guepe_left[] = { 195, 196, 197, 198, 197, 196 };
|
||||
|
||||
extern int table_guepe_right[] = { 199, 200, 201, 202, 201, 200 };
|
||||
|
||||
extern int table_guepe_turn2l[] = { 5, 207, 206, 205, 204, 203 };
|
||||
|
||||
extern int table_guepe_turn2r[] = { 203, 204, 205, 206, 207 };
|
||||
|
||||
extern int table_creature_left[] = { 247, 248, 249, 250, 251, 250, 249, 248 };
|
||||
|
||||
extern int table_creature_right[] = { 247, 248, 249, 250, 251, 250, 249, 248 };
|
||||
|
||||
extern int table_creature_turn2[] =
|
||||
{
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4, 0xF3,
|
||||
0xF3, 0xF2, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF3, 0xF3, 0xF4,
|
||||
0xF4, 0xF5, 0xF5,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF6, 0xF5,
|
||||
0xF5, 0xF4, 0xF4,
|
||||
0xF3, 0xF3, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF2, 0xF2, 0xF3,
|
||||
0xF3, 0xF4, 0xF4,
|
||||
0xF5, 0xF5, 0xF6,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF6, 0xF5,
|
||||
0xF5, 0xF4, 0xF4,
|
||||
0xF3, 0xF3, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF3, 0xF3, 0xF4,
|
||||
0xF4, 0xF5, 0xF5,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF5, 0xF5,
|
||||
0xF4, 0xF4, 0xF3,
|
||||
0xF3, 0xF2, 0xF2,
|
||||
0xF3, 0xF3, 0xF4,
|
||||
0xF4, 0xF5, 0xF5,
|
||||
0xF6, 0xF6, 0xF5,
|
||||
0xF5, 0xF4, 0xF4,
|
||||
0xF3, 0xF3, 0xF2,
|
||||
0xF2, 0xF3, 0xF3,
|
||||
0xF4, 0xF4, 0xF5,
|
||||
0xF5, 0xF6, 0xF6,
|
||||
0xF5, 0xF5, 0xF4,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF7, 0xF7, 0xF8,
|
||||
0xF8, 0xF9, 0xF9,
|
||||
0xFA, 0xFA, 0xFB,
|
||||
0xFB, 0xFA, 0xFA,
|
||||
0xF9, 0xF9, 0xF8,
|
||||
0xF8, 0xF2, 0xF2,
|
||||
0xF3, 0xF3, 0xF4,
|
||||
0xF4, 0xF5, 0xF5,
|
||||
0xF6, 0xF6, 0xF5,
|
||||
0xF5, 0xF4, 0xF4,
|
||||
0xF3, 0xF3, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF3, 0xF3, 0xF4,
|
||||
0xF4, 0xF5, 0xF5,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF5, 0xF5,
|
||||
0xF4, 0xF4, 0xF3,
|
||||
0xF3, 0xF2, 0xF2,
|
||||
0xF2, 0xF2, 0xF2,
|
||||
0xF2, 0xF3, 0xF3,
|
||||
0xF4, 0xF4, 0xF5,
|
||||
0xF5, 0xF6, 0xF6,
|
||||
0xF6, 0xF6, 0xF6,
|
||||
0xF6, 0xF5, 0xF5,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4, 0xF4,
|
||||
0xF4, 0xF4
|
||||
};
|
||||
|
||||
extern int table_blupih_left[] = { 66, 67, 68, 67, 66, 69, 70, 69 };
|
||||
|
||||
extern int table_blupih_right[] = { 61, 62, 63, 62, 61, 64, 65, 64 };
|
||||
|
||||
extern int table_blupih_turn2l[] =
|
||||
{
|
||||
71, 71, 72, 72, 73, 73, 74, 74, 75, 75,
|
||||
68, 68, 275, 275, 271, 271, 271, 271, 272, 272,
|
||||
273, 273, 273, 273, 275, 275
|
||||
};
|
||||
|
||||
extern int table_blupih_turn2r[] =
|
||||
{
|
||||
75, 75, 74, 74, 73, 73, 72, 72, 71, 71,
|
||||
63, 63, 274, 274, 271, 271, 271, 271, 272, 272,
|
||||
273, 273, 273, 273, 274, 274
|
||||
};
|
||||
|
||||
extern int table_blupit_left[] = { 249, 249, 250, 250, 249, 249, 248, 248 };
|
||||
|
||||
extern int table_blupit_right[] = { 238, 238, 237, 237, 238, 238, 239, 239 };
|
||||
|
||||
extern int table_blupit_turn2l[] =
|
||||
{
|
||||
238, 238, 251, 251, 238, 238, 238, 239, 240, 241,
|
||||
242, 243, 244, 245, 246, 247, 248, 249, 249, 249,
|
||||
252, 252, 249, 249
|
||||
};
|
||||
|
||||
extern int table_blupit_turn2r[] =
|
||||
{
|
||||
249, 249, 252, 252, 249, 249, 249, 248, 247, 246,
|
||||
245, 244, 243, 242, 241, 240, 239, 238, 238, 238,
|
||||
251, 251, 238, 238
|
||||
};
|
||||
|
||||
extern int table_explo1[] =
|
||||
{
|
||||
0, 0, 1, 1, 2, 2, 3, 3, 4, 3,
|
||||
4, 4, 3, 4, 3, 3, 4, 4, 5, 5,
|
||||
4, 5, 6, 5, 6, 6, 5, 5, 6, 7,
|
||||
7, 8, 8, 9, 9, 10, 10, 11, 11
|
||||
};
|
||||
|
||||
extern int table_explo2[] =
|
||||
{
|
||||
12, -1, 13, 14, -1, 15, 13, -1, 14, 15,
|
||||
12, -1, 13, 15, 14, 14, -1, 14, 15, 13
|
||||
};
|
||||
|
||||
extern int table_explo3[] =
|
||||
{
|
||||
32, 32, 34, 34, 32, 32, 34, 34, 32, 32,
|
||||
34, 34, 32, 32, 35, 35, 32, 32, 35, 35
|
||||
};
|
||||
|
||||
extern int table_explo4[] = { 12, 13, 14, 15, 7, 8, 9, 10, 11 };
|
||||
|
||||
extern int table_explo5[] =
|
||||
{
|
||||
54, -1, 55, -1, 56, -1, 57, -1, 58, -1,
|
||||
59, -1
|
||||
};
|
||||
|
||||
extern int table_explo6[] = { 54, 55, 56, 57, 58, 59 };
|
||||
|
||||
extern int table_explo7[] =
|
||||
{
|
||||
60, 61, -1, 63, 64, 65, 62, 64, 62, 60,
|
||||
62, -1, 65, -1, 60, 65, 63, 61, 62, -1,
|
||||
64, 65, -1, 62, 64, 61, 62, 63, -1, 65,
|
||||
60, -1, 65, -1, 63, 65, -1, 61, 60, 65,
|
||||
62, 63, 64, -1, 62, 63, -1, 62, 62, 60,
|
||||
62, -1, 65, -1, 60, 65, 64, 61, 62, 63,
|
||||
-1, 65, 60, -1, 63, 61, 62, -1, 64, 65,
|
||||
-1, 62, 62, 60, 62, -1, 65, -1, 60, 65,
|
||||
60, 61, -1, 63, 64, 65, 62, 64, 63, 61,
|
||||
62, -1, 64, 65, -1, 62, 60, 61, -1, 63,
|
||||
64, 65, 62, 64, -1, 60, -1, -1, 65, -1,
|
||||
60, -1, 63, -1, 62, -1, -1, 65, -1, -1,
|
||||
-1, 61, -1, -1, -1, 60, -1, -1
|
||||
};
|
||||
|
||||
extern int table_explo8[] = { 7, 8, 9, 10, 11 };
|
||||
|
||||
extern int table_sploutch1[] = { 90, 91, 92, 93, 94, 95, 96, 97, 98, 99 };
|
||||
|
||||
extern int table_sploutch2[] =
|
||||
{
|
||||
-1, -1, -1, 90, 91, 92, 93, 94, 95, 96,
|
||||
97, 98, 99
|
||||
};
|
||||
|
||||
extern int table_sploutch3[] =
|
||||
{
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, 90, 91,
|
||||
92, 93, 94, 95, 96, 97, 98, 99
|
||||
};
|
||||
|
||||
extern int table_tentacule[] =
|
||||
{
|
||||
86, 85, 84, 83, 84, 85, 86, -1, 86, 85,
|
||||
84, 83, 82, 81, 80, 79, 78, 77, 76, 75,
|
||||
74, 73, 72, 71, 70, 70, 70, 70, 71, 72,
|
||||
73, 74, 75, 76, 77, 78, 79, 80, 81, 82,
|
||||
83, 84, 85, 86, -1
|
||||
};
|
||||
|
||||
extern int table_bridge[] =
|
||||
{
|
||||
365, 366, 365, 366, 365, 366, 365, 366, 365, 366,
|
||||
365, 366, 365, 366, 365, 366, 367, 367, 368, 368,
|
||||
369, 369, 370, 370, 371, 371, 372, 372, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
372, 372, 371, 371, 370, 370, 369, 369, 368, 368,
|
||||
367, 367, 366, 366, 365, 365, 364
|
||||
};
|
||||
|
||||
extern int table_pollution[] = { 179, 180, 181, 182, 183, 184, 185, 186 };
|
||||
|
||||
extern int table_invertstart[] = { 179, 180, 181, 182, 183, 184, 185, 186 };
|
||||
|
||||
extern int table_invertstop[] = { 186, 185, 184, 183, 182, 181, 180, 179 };
|
||||
|
||||
extern int table_invertpanel[] = { 187, 188, 189, 190, 191, 192, 193, 194 };
|
||||
|
||||
extern int table_plouf[] = { 99, 100, 101, 102, 101, 100, 99 };
|
||||
|
||||
extern int table_tiplouf[] = { 244, 99, 244 };
|
||||
|
||||
extern int table_blup[] =
|
||||
{
|
||||
103, 104, 105, 106, 104, 103, 106, 105, 103, 104,
|
||||
103, 105, 106, 103, 105, 106, 103, 104, 106, 105
|
||||
};
|
||||
|
||||
extern int table_follow1[] =
|
||||
{
|
||||
256, 256, 256, 257, 257, 258, 259, 260, 261, 262,
|
||||
263, 264, 264, 265, 265, 265, 264, 264, 263, 262,
|
||||
261, 260, 259, 258, 257, 257
|
||||
};
|
||||
|
||||
extern int table_follow2[] = { 256, 258, 260, 262, 264 };
|
||||
|
||||
extern int table_cle[] =
|
||||
{
|
||||
122, 123, 124, 125, 126, 127, 128, 127, 126, 125,
|
||||
124, 123
|
||||
};
|
||||
|
||||
extern int table_cle1[] =
|
||||
{
|
||||
209, 210, 211, 212, 213, 214, 215, 214, 213, 212, 211, 210
|
||||
};
|
||||
|
||||
extern int table_cle2[] =
|
||||
{
|
||||
220, 221, 222, 221, 220, 219, 218, 217, 216, 217, 218, 219
|
||||
};
|
||||
|
||||
extern int table_cle3[] =
|
||||
{
|
||||
229, 228, 227, 226, 225, 224, 223, 224, 225, 226, 227, 228
|
||||
};
|
||||
|
||||
extern int table_decor_action[] =
|
||||
{
|
||||
1,32,
|
||||
-4,4, 4,-3, -4,2, 4,5, -4,-1, 4,2, -4,-4, 4,-3, -3,2, 3,2,
|
||||
-3,-5, 3,4, -3,5, 3,-2, -3,5, 3,4, -2,-2, 2,4, -2,-2, 2,-2,
|
||||
-2,-4, 2,2, -2,-2, 2,-3, -1,-3, 1,-2, -1,-1, 1,2, -1,-2, 1,-1,
|
||||
-1,1, 1,2,
|
||||
2,32,
|
||||
-4,0, 4,0, -4,0, 4,0, -4,0, 4,0, -4,0, 4,0, -3,0, 3,0,
|
||||
-3,0, 3,0, -3,0, 3,0, -3,0, 3,0, -2,0, 2,0, -2,0, 2,0,
|
||||
-2,0, 2,0, -2,0, 2,0, -1,0, 1,0, -1,0, 1,0, -1,0, 1,0,
|
||||
-1,0, 1,0,
|
||||
5,192,
|
||||
0,-32, 0,32, 0,-16, 0,6, 0,-8, 0,8, 0,-4, 0,4, 0,-2, 0,2,
|
||||
-7,0, -6,0, -5,0, -4,0, -2,0, 0,0, 2,0, 4,0, 5,0, 6,0,
|
||||
7,0, 7,0, 6,0, 5,0, 4,0, 2,0, 0,0, -2,0, -4,0, -5,0,
|
||||
-6,0, -7,0, -7,0, -6,0, -5,0, -4,0, -2,0, 0,0, 2,0, 4,0,
|
||||
5,0, 6,0, 7,0, 7,0, 6,0, 5,0, 4,0, 2,0, 0,0, -2,0, -4,0,
|
||||
-5,0, -6,0, -7,0, -7,0, -6,0, -5,0, -4,0, -2,0, 0,0, 2,0,
|
||||
4,0, 5,0, 6,0, 7,0, 7,0, 6,0, 5,0, 4,0, 2,0, 0,0,
|
||||
-2,0, -4,0, -5,0, -6,0, -7,0, -7,0, -6,0, -5,0, -4,0, -2,0,
|
||||
0,0, 2,0, 4,0, 5,0, 6,0, 7,0, 7,0, 6,0, 5,0, 4,0,
|
||||
2,0, 0,0, -2,0, -4,0, -5,0, -6,0, -7,0, -7,0, -6,0, -5,0,
|
||||
-4,0, -2,0, 0,0, 2,0, 4,0, 5,0, 6,0, 7,0, 7,0, 6,0,
|
||||
5,0, 4,0, 2,0, 0,0, -2,0, -4,0, -5,0, -6,0, -7,0, -7,0,
|
||||
-6,0, -5,0, -4,0, -2,0, 0,0, 2,0, 4,0, 5,0, 6,0, 7,0,
|
||||
7,0, 6,0, 5,0, 4,0, 2,0, 0,0, -2,0, -4,0, -5,0, -6,0,
|
||||
-7,0, -7,0, -6,0, -5,0, -4,0, -2,0, 0,0, 2,0, 4,0, 5,0,
|
||||
6,0, 7,0, 7,0, 6,0, 5,0, 4,0, 2,0, 0,0, -2,0, -4,0,
|
||||
-5,0, -6,0, -7,0, -7,0, -6,0, -5,0, -4,0, -2,0, 0,0, 2,0,
|
||||
4,0, 5,0, 6,0, 7,0, 7,0, 6,0, 5,0, 4,0, 2,0, 0,0,
|
||||
-2,0, -4,0, -5,0, -6,0, -7,0, -7,0, -6,0, -5,0, -4,0, -2,0,
|
||||
-1,0,
|
||||
0
|
||||
};
|
||||
|
||||
extern int table_dynamitef[] =
|
||||
{
|
||||
253, 252, 254, 252, 252, 255, 252, 254, 253, 252,
|
||||
253, 254, 255, 252, 255, 253, 252, 254, 252, 255,
|
||||
253, 254, 252, 253, 255, 254, 255, 252, 253, 254,
|
||||
255, 252, 253, 254, 255, 254, 254, 253, 254, 255,
|
||||
253, 252, 255, 254, 255, 253, 252, 254, 253, 255,
|
||||
253, 254, 252, 253, 255, 254, 252, 255, 253, 254,
|
||||
255, 253, 252, 254, 255, 254, 252, 253, 254, 255,
|
||||
253, 254, 255, 254, 255, 253, 252, 254, 253, 255,
|
||||
253, 254, 255, 253, 255, 254, 255, 252, 253, 254,
|
||||
255, 253, 253, 254, 255, 254, 252, 253, 254, 255
|
||||
};
|
||||
|
||||
extern int table_skate[] =
|
||||
{
|
||||
129, 129, 129, 129, 130, 130, 130, 131, 131, 132,
|
||||
132, 133, 133, 134, 134, 134, 135, 135, 135, 135,
|
||||
134, 134, 134, 133, 133, 132, 132, 131, 131, 131,
|
||||
130, 130, 130, 130
|
||||
};
|
||||
|
||||
extern int table_glu[] =
|
||||
{
|
||||
168, 168, 169, 169, 170, 170, 171, 171, 170, 170,
|
||||
169, 169, 168, 168, 169, 169, 169, 168, 168, 169,
|
||||
169, 170, 170, 169, 168
|
||||
};
|
||||
|
||||
extern int table_clear[] =
|
||||
{
|
||||
40, 40, 40, 40, 41, 41, 41, 41, 40, 40,
|
||||
40, 40, 40, 40, 40, 41, 41, 41, 40, 40,
|
||||
40, 40, 40, 40, 40, 41, 41, 41, 40, 40,
|
||||
42, 42, 42, 43, 43, 43, 44, 44, 44, 45,
|
||||
45, 45, 46, 46, 47, 47, 46, 46, 47, 47,
|
||||
46, 46, 47, 47, 46, 46, 47, 47, 46, 46,
|
||||
47, 47, 46, 46, 47, 47, 46, 46, 47, 47
|
||||
};
|
||||
|
||||
extern int table_electro[] =
|
||||
{
|
||||
266, 267, 266, 267, 266, 267, 266, 267, 266, 267,
|
||||
266, 267, 266, 267, 266, 267, 266, 267, 266, 267,
|
||||
266, 267, 266, 267, 266, 267, 266, 267, 266, 267,
|
||||
40, 40, 40, 40, 41, 41, 41, 41, 40, 40,
|
||||
40, 40, 40, 40, 40, 41, 41, 41, 40, 40,
|
||||
40, 40, 40, 40, 40, 41, 41, 41, 40, 40,
|
||||
42, 42, 42, 43, 43, 43, 44, 44, 44, 45,
|
||||
45, 45, 46, 46, 47, 47, 46, 46, 47, 47,
|
||||
46, 46, 47, 47, 46, 46, 47, 47, 46, 46
|
||||
};
|
||||
|
||||
extern int table_chenille[] = { 311, 312, 313, 314, 315, 316 };
|
||||
|
||||
extern int table_chenillei[] = { 316, 315, 314, 313, 312, 311 };
|
||||
|
||||
extern int table_adapt_decor[] =
|
||||
{
|
||||
153, 147, 148, 146, 40, 151, 150, 144, 39, 152,
|
||||
149, 145, 38, 36, 37, 35, 153, 147, 148, 146,
|
||||
40, 151, 150, 144, 39, 152, 149, 145, 38, 36,
|
||||
37, 156, 75, 75, 155, 155, 75, 75, 155, 155,
|
||||
74, 74, 154, 154, 75, 75, 155, 155, 157, 157,
|
||||
157, 157, 109, 109, 109, 109, 108, 108, 108, 108,
|
||||
107, 107, 107, 107, 202, 202, 138, 138, 202, 202,
|
||||
138, 138, 202, 202, 138, 138, 202, 202, 138, 138,
|
||||
283, 283, 283, 283, 262, 262, 262, 262, 263, 263,
|
||||
263, 263, 261, 261, 261, 261, 361, 359, 360, 352,
|
||||
357, 353, 355, 349, 358, 354, 356, 350, 351, 347,
|
||||
348, 341, 387, 387, 386, 386, 394, 394, 392, 392,
|
||||
395, 395, 393, 393, 397, 397, 396, 396, 251, 254,
|
||||
254, 254, 251, 258, 260, 258, 251, 257, 259, 257,
|
||||
251, 250, 256, 250
|
||||
};
|
||||
|
||||
extern int table_adapt_fromage[] =
|
||||
{
|
||||
-1, 265, 264, 268, 267, 273, 271, 275, 266, 272,
|
||||
270, 274, 269, 277, 276, 278, -1, 286, 285, 289,
|
||||
288, 294, 292, 296, 287, 293, 291, 295, 290, 298,
|
||||
297, 299
|
||||
};
|
||||
|
||||
extern int table_shield[] =
|
||||
{
|
||||
144, 145, 146, 147, 148, 149, 150, 151, 266, 267,
|
||||
268, 269, 270, 271, 272, 273
|
||||
};
|
||||
|
||||
extern int table_shield_blupi[] =
|
||||
{
|
||||
144, 145, 146, 147, 148, 149, 150, 151, 266, 267,
|
||||
268, 269, 270, 271, 272, 273
|
||||
};
|
||||
|
||||
extern int table_power[] = { 8, 136, 137, 138, 139, 140, 141, 142, 143 };
|
||||
|
||||
extern int table_invert[] =
|
||||
{
|
||||
187, 187, 187, 188, 189, 190, 191, 192, 193, 194,
|
||||
187, 187, 187, 194, 193, 192, 191, 190, 189, 188
|
||||
};
|
||||
|
||||
extern int table_charge[] = { 238, 239, 240, 241, 242, 243 };
|
||||
|
||||
extern int table_magicloop[] = { 152, 153, 154, 155, 156 };
|
||||
|
||||
extern int table_magictrack[] =
|
||||
{
|
||||
152, 153, 154, 155, 156, 152, 153, 154, 155, 156,
|
||||
157, 158, 159, 160, 157, 158, 159, 160, 161, 162,
|
||||
163, 164, 165, 166
|
||||
};
|
||||
|
||||
extern int table_shieldloop[] = { 274, 275, 276, 277, 278 };
|
||||
|
||||
extern int table_shieldtrack[] =
|
||||
{
|
||||
274, 275, 276, 277, 278, 274, 275, 276, 277, 278,
|
||||
279, 280, 281, 282, 283, 284, 285, 286, 287, 288
|
||||
};
|
||||
|
||||
extern int table_drinkeffect[] = { 274, 275, 276, 277, 278 };
|
||||
|
||||
extern int table_drinkoffset[] = { 0, 7, 22 };
|
||||
|
||||
extern int table_tresortrack[] =
|
||||
{
|
||||
166, 165, 164, 163, 162, 161, 162, 163, 164, 165,
|
||||
166
|
||||
};
|
||||
|
||||
extern int table_decor_piege1[] =
|
||||
{
|
||||
374, 374, 373, 347, 373, 374, 374, 374, 373, 347,
|
||||
347, 373, 374, 374, 374, 374
|
||||
};
|
||||
|
||||
extern int table_decor_piege2[] = { 374, 373, 347, 373 };
|
||||
|
||||
extern int table_decor_goutte[] =
|
||||
{
|
||||
410, 409, 410, -1, -1, -1, -1, -1, -1, 410,
|
||||
409, 408, 409, 410, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, 410, 409, 408, 407, 406, 405,
|
||||
404, 405, 406, 407, 408, 409, 410, -1, -1, -1,
|
||||
-1, 410, 409, 410, -1, -1, -1, -1
|
||||
};
|
||||
|
||||
extern int table_decor_ecraseur[] = { 317, 317, 318, 319, 320, 321, 322, 323, 323, 323 };
|
||||
|
||||
extern int table_decor_scie[] = { 378, 379, 380, 381, 382, 383 };
|
||||
|
||||
extern int table_decor_temp[] =
|
||||
{
|
||||
328, 328, 327, 327, 326, 326, 325, 325, 324, 324,
|
||||
325, 325, 326, 326, 327, 329, 328, 328, -1, -1
|
||||
};
|
||||
|
||||
extern int table_decor_eau1[] = { 92, 93, 94, 95, 94, 93 };
|
||||
|
||||
extern int table_decor_eau2[] = { 91, 96, 97, 98, 97, 96 };
|
||||
|
||||
|
||||
|
||||
extern int table_decor_ventillod[] = { 129, 130, 131 };
|
||||
|
||||
extern int table_decor_ventilloh[] = { 132, 133, 134 };
|
||||
|
||||
extern int table_decor_ventillob[] = { 135, 136, 137 };
|
||||
|
||||
|
||||
|
||||
extern int table_decor_ventd[] = { 114, 115, 116, 117 };
|
||||
|
||||
extern int table_decor_venth[] = { 118, 119, 120, 121 };
|
||||
|
||||
extern int table_decor_ventb[] = { 122, 123, 124, 125 };
|
||||
|
||||
extern int table_marine[] =
|
||||
{
|
||||
0xcb, 0xcc, 0xcd, 0xce, 0xcf, 0xd0, 0xcf, 0xce, 0xcd, 0xcc, 0xcb
|
||||
};
|
||||
|
||||
extern int table_36418[] = { 10, 2, 3, 4, 5, 6, 7, 8, 9, 1, 11, 12, 13, 14 };
|
||||
extern int table_36458[] = { 19, 20, 21, 23, 24, 25, 26, 27, 28, 29 };
|
||||
extern int table_36488[] = { 15, 16, 17, 18 };
|
||||
extern int table_364a0[] = { 73, 22 };
|
||||
extern int table_364b0[] = { 78, 79, 80, 81, 82, 83, 84 };
|
||||
extern int table_364d0[] = { 87, 88, 89, 90 };
|
||||
extern int table_364e8[] = { 85, 86 };
|
||||
extern int table_364f8[] = { 396, 388, 389, 390, 391 };
|
||||
extern int table_36510[] = { 398, 399, 400 };
|
||||
extern int table_36520[] = { 87, 88, 89 };
|
||||
extern int table_36530[] = { 0x99 };
|
||||
extern int table_36538[] = { 0x9a, 0x9b };
|
||||
extern int table_36548[] = { 0xb9 };
|
||||
extern int table_36550[] = { 0x29, 0x2a, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f };
|
||||
extern int table_36570[] = { 0xd7, 0xd8, 0xd9, 0xda, 0xdb, 0xdc, 0xdd, 0xde, 0xe6, 0xe7, 0xe9, 0xea };
|
||||
extern int table_365a8[] = { 0xdf, 0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe8 };
|
||||
extern int table_365d0[] = { 0x9d };
|
||||
extern int table_365d8[] = { 0x8b, 0x8c, 0x8d, 0x8e, 0x8f };
|
||||
extern int table_365f0[] = { 0xba, 0xbb, 0xbc, 0xbd, 0xbe, 0xbf, 0xc0 };
|
||||
extern int table_36610[] = { 0xc1, 0xc2, 0xc3, 0xc4, 0xc5 };
|
||||
extern int table_decor_lave[] = { 68, 69, 70, 71, 72, 71, 70, 69 };
|
||||
extern int table_36630[] = { 0x5b, 0x5c };
|
||||
extern int table_decor_ventillog[] = { 126, 127, 128 };
|
||||
extern int table_decor_ventg[] = { 110, 111, 112, 113 };
|
||||
extern int table_36670[] = { 0x4c, 0x4d, 0xc7, 0xc6, 0xc8, 0xc9, 0xeb, 0xec, 0x177, 0x178, 0x179 };
|
||||
extern int table_366a0[] = { 0x193, 0x191, 0x192 };
|
||||
extern int table_366b0[] = { 20, 21, 22 };
|
||||
extern int table_366c0[] = { 16, 17, 18, 19 };
|
||||
extern int table_366d8[] = { 23, 24, 25 };
|
||||
extern int table_366e8[] = { 0x1a, 0x1b };
|
||||
extern int table_366f8[] = { 0x1c, 0x1d, 0x1e, 0x1f };
|
||||
extern int table_36710[] = { 0x2d, 0x2e, 0x2f, 0x24, 0x25, 0x26, 0x27, 0x28, 0x29, 0x2a, 0x2b, 0x2c};
|
||||
extern int table_36748[] = { 0x42, 0x43, 0x44, 0x45 };
|
||||
|
||||
extern int table_mirror[] = {
|
||||
4, 3, 2, 1, 0, 11, 12, 13, 14, 15, 16, 5, 6, 7, 8, 9, 10, 20, 21, 22, 17, 18, 19, 24, 23, 25, 30, 31, 32, 29, 26, 27, 28, 36, 37, 38, 33, 34, 35, 40, 39, 41, 42, 43, 45, 44, 46, 47, 48, 55, 56, 57, 58, 59, 60, 49, 50, 51, 52, 53, 54, 66, 67, 68, 69, 70, 61, 62, 63, 64, 65, 75, 74, 73, 72, 71, 82, 83, 84, 85, 86, 87, 76, 77, 78, 79, 80, 81, 92, 91, 90, 89, 88, 99, 100, 101, 102, 103, 104, 93, 94, 95, 96, 97, 98, 109, 108, 107, 106, 105, 120, 119, 118, 117, 116, 115, 114, 113, 112, 111, 110, 127, 128, 129, 130, 131, 132, 121, 122, 123, 124, 125, 126, 134, 133, 139, 140, 141, 142, 135, 136, 137, 138, 147, 148, 149, 150, 143, 144, 145, 146, 155, 154, 153, 152, 151, 159, 160, 161, 156, 157, 158, 162, 163, 164, 167, 168, 165, 166, 173, 174, 175, 176, 169, 170, 171, 172, 181, 180, 179, 178, 177, 188, 189, 190, 191, 192, 193, 182, 183, 184, 185, 186, 187, 201, 202, 203, 204, 205, 206, 207, 194, 195, 196, 197, 198, 199, 200, 209, 208, 216, 217, 218, 219, 220, 221, 210, 211, 212, 213, 214, 215, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 250, 249, 248, 247, 246, 245, 244, 243, 242, 241, 240, 239, 238, 237, 252, 251, 255, 256, 253, 254, 257, 258, 259, 260, 261, 262, 285, 286, 287, 266, 267, 270, 269, 268, 271, 272, 273, 275, 274, 276, 277, 278, 279, 280, 281, 282, 283, 284, 263, 264, 265, 288, 289, 290, 291, 292, 293, 294, 295, 303, 304, 305, 306, 307, 308, 309, 296, 297, 298, 299, 300, 301, 302, 314, 313, 312, 311, 310, 316, 315, 323, 322, 321, 320, 319, 318, 317, 324, 325, 326, 327, 328, 329, 330, 331, 332, 333, 334
|
||||
};
|
||||
|
||||
extern int table_ressort[] =
|
||||
{
|
||||
0xd1, 0xd2, 0xd3, 0xd4, 0xd5, 0xd4, 0xd3, 0xd2
|
||||
};
|
||||
|
||||
extern int table_blupi[] = {
|
||||
35, 18, 0, 276, 276, 277, 277, 278, 278, 279, 279, 280, 280, 281, 281, 282, 282, 283, 283, 284, 284, 1, 330, 0, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
23, 23, 23, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 23, 23, 23, 0, 0, 0, 23, 23, 23, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0
|
||||
, 0, 133, 133, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 0, 135, 135, 136,
|
||||
136, 137, 137, 137, 137, 137, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 137, 137, 137, 136,
|
||||
136, 135, 135, 135, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 133, 133, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 0, 0,
|
||||
23, 23, 23, 23, 0, 0, 0, 135, 135, 136, 136, 137, 137, 137, 137, 137, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138,
|
||||
138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 138, 138, 137, 137,
|
||||
137, 138, 138, 137, 137, 137, 138, 138, 137, 137, 137, 137, 137, 137, 136, 136, 135, 135, 135, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 133, 133, 0, 0, 0, 23, 23, 23, 23, 0, 0
|
||||
, 0, 0, 0, 0, 0, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 2, 6, 0, 5, 6, 7, 8, 9, 10, 60, 3, 0, 19, 18, 19, 3, 6, 0, 1, 1, 2,
|
||||
2, 3, 3, 4, 3, 0, 17, 18, 19, 5, 5, 4, 169, 26, 170, 170, 27, 59, 6, 0, 3, 3, 2, 2, 1, 1, 61, 5, 0, 34, 35, 34, 34, 33, 62, 2, 0, 35, 34, 6, 3, 2, 33, 34, 35, 7, 1, 0,
|
||||
44, 8, 8, 0, 0, 169, 26, 170, 27, 171, 28, 172, 9, 6, 0, 5, 6, 7, 8, 9, 10, 10, 6, 0, 5, 6, 7, 8, 9, 10, 13, 6, 0, 41, 41, 42, 42, 43, 43, 11, 70, 0, 40, 40, 40, 40,
|
||||
41, 41, 41, 41, 40, 40, 40, 40, 40, 40, 40, 41, 41, 41, 40, 40, 40, 40, 40, 40, 40, 41, 41, 41, 40, 40, 42, 42, 42, 43, 43, 43, 44, 44, 44, 45, 45, 45, 46, 46, 47, 47,
|
||||
46, 46, 47, 47, 46, 46, 47, 47, 46, 46, 47, 47, 46, 46, 47, 47, 46, 46, 47, 47, 46, 46, 47, 47, 75, 1, 0, -1, 76, 70, 0, 40, 40, 40, 40, 41, 41, 41, 41, 40, 40, 40,
|
||||
40, 40, 40, 40, 41, 41, 41, 40, 40, 40, 40, 40, 40, 40, 41, 41, 41, 40, 40, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
|
||||
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1
|
||||
, -1, -1, -1, -1, -1, 77, 110, 0, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 325, 324, 324, 325, 325, 326, 326, 327
|
||||
, 327, 328, 328, 329, 329, 330, 330, 331, 331, 332, 332, 333, 333, 334, 334, 333, 333, 332, 332, 331, 331, 330, 330, 329, 329, 329, 330, 330, 330, 331, 331, 331, 332,
|
||||
332, 332, 333, 333, 333, 334, 334, 334, 333, 333, 333, 332, 332, 332, 331, 331, 331, 330, 330, 330, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329,
|
||||
329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, 78, 1, 0, -1, 79, 1, 0, -1, 80, 1, 0, -1, 81, 1, 0, -1, 14, 6, 0, 49, 50, 51, 52,
|
||||
53, 54, 29, 6, 0, 126, 125, 124, 123, 122, 121, 28, 6, 0, 122, 122, 122, 125, 125, 125, 15, 1, 0, 61, 16, 8, 0, 61, 62, 63, 62, 61, 64, 65, 64, 17, 10, 0, 71, 71, 72,
|
||||
72, 73, 73, 74, 74, 75, 75, 67, 1, 0, 315, 68, 12, 0, 296, 297, 298, 299, 300, 301, 302, 301, 300, 299, 298, 297, 69, 7, 0, 296, 310, 311, 312, 313, 314, 303, 18, 10,
|
||||
0, 76, 76, 76, 76, 76, 76, 77, 77, 77, 77, 19, 14, 0, 76, 76, 77, 77, 78, 78, 79, 79, 80, 80, 81, 81, 39, 39, 20, 10, 0, 88, 88, 89, 89, 90, 90, 91, 91, 92, 92, 21, 12
|
||||
, 0, 93, 93, 94, 94, 95, 95, 96, 96, 97, 97, 98, 98, 22, 12, 0, 93, 93, 94, 94, 95, 95, 96, 96, 97, 97, 98, 98, 23, 10, 0, 105, 105, 106, 106, 107, 107, 108, 108, 109,
|
||||
109, 24, 90, 0, 93, 96, 98, 94, 95, 93, 95, 98, 93, 94, 96, 96, 94, 94, 98, 98, 93, 93, 97, 97, 94, 94, 94, 96, 96, 96, 93, 93, 93, 93, 94, 94, 94, 94, 94, 97, 97, 97
|
||||
, 97, 97, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 79, 79, 76, 76, 76, 76, 79, 79, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76,
|
||||
76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, 25, 8, 0, 111, 111, 110, 110, 111, 111, 112, 112, 26, 8, 0, 111, 111, 110, 110, 111, 111, 112, 112, 27, 7, 0, 112, 113, 114
|
||||
, 115, 116, 117, 118, 30, 12, 0, 25, 25, 29, 29, 46, 46, 47, 47, 46, 46, 29, 29, 31, 328, 0, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157,
|
||||
157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157,
|
||||
156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156,
|
||||
156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 144, 144,
|
||||
143, 143, 151, 151, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164,
|
||||
164, 163, 163, 162, 162, 151, 151, 143, 143, 144, 144, 157, 157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156,
|
||||
157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156, 157, 157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 156, 156, 156, 156, 157,
|
||||
157, 157, 157, 158, 158, 158, 158, 157, 157, 157, 157, 144, 144, 143, 143, 151, 151, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163,
|
||||
162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 151, 151, 143, 143, 151, 151, 162, 162, 163, 163, 164, 164, 163, 163, 162,
|
||||
162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162, 163, 163, 164, 164, 163, 163, 162, 162,
|
||||
163, 163, 164, 164, 163, 163, 162, 162, 151, 151, 143, 143, 144, 144, 157, 157, 32, 12, 0, 144, 144, 145, 145, 146, 146, 145, 145, 144, 144, 143, 143, 33, 10, 0, 151,
|
||||
151, 152, 152, 153, 153, 154, 154, 155, 155, 34, 10, 0, 157, 157, 165, 165, 165, 165, 166, 166, 166, 166, 36, 32, 0, 135, 177, 177, 178, 178, 179, 179, 180, 180, 179,
|
||||
179, 178, 178, 179, 179, 180, 180, 179, 179, 178, 178, 179, 179, 180, 180, 179, 179, 178, 178, 177, 177, 135, 37, 140, 0, 182, 182, 182, 182, 208, 208, 208, 208, 208,
|
||||
182, 182, 182, 182, 182, 182, 208, 208, 208, 208, 208, 194, 194, 194, 182, 182, 182, 182, 208, 208, 208, 208, 208, 182, 182, 182, 182, 182, 182, 208, 208, 208, 208,
|
||||
182, 182, 182, 182, 182, 182, 182, 182, 194, 195, 196, 197, 198, 198, 197, 197, 196, 196, 197, 197, 198, 198, 197, 197, 196, 195, 194, 182, 182, 182, 208, 208, 208,
|
||||
208, 208, 208, 182, 182, 182, 182, 182, 208, 208, 208, 208, 208, 182, 182, 194, 195, 196, 197, 198, 198, 197, 197, 196, 196, 197, 197, 198, 198, 197, 197, 196, 196,
|
||||
197, 197, 198, 198, 197, 197, 196, 195, 194, 182, 182, 182, 182, 182, 182, 182, 208, 208, 208, 208, 208, 208, 210, 210, 211, 211, 211, 211, 211, 211, 210, 210, 38, 96,
|
||||
0, 182, 183, 184, 185, 186, 187, 182, 183, 184, 185, 186, 187, 182, 183, 184, 185, 186, 187, 182, 182, 182, 182, 182, 182, 182, 183, 184, 185, 186, 187, 182, 182, 182
|
||||
, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 183, 184, 185, 186, 187, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182,
|
||||
182, 183, 184, 185, 186, 187, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, 39, 7, 0, 194,
|
||||
195, 196, 197, 198, 199, 200, 40, 3, 0, 210, 211, 212, 41, 8, 0, 213, 213, 214, 214, 215, 215, 214, 214, 42, 20, 0, 17, 17, 18, 18, 19, 19, 1, 1, 215, 215, 214, 214,
|
||||
213, 213, 212, 212, 211, 211, 210, 210, 43, 20, 0, 210, 210, 211, 211, 212, 212, 213, 213, 214, 214, 215, 215, 1, 1, 19, 19, 18, 18, 17, 17, 44, 29, 0, 1, 1, 222, 222,
|
||||
222, 222, 223, 223, 224, 224, 225, 225, 225, 225, 225, 224, 223, 222, 222, 222, 223, 223, 224, 224, 225, 225, 225, 1, 1, 45, 29, 0, 1, 1, 222, 222, 222, 222, 223, 223
|
||||
, 224, 224, 225, 225, 225, 225, 225, 224, 223, 222, 222, 222, 223, 223, 224, 224, 225, 225, 225, 1, 1, 46, 32, 0, 1, 1, 227, 227, 228, 228, 229, 229, 228, 228, 227,
|
||||
227, 226, 226, 227, 227, 228, 228, 229, 229, 228, 228, 227, 227, 226, 226, 227, 227, 228, 228, 1, 1, 47, 34, 0, 135, 135, 136, 136, 137, 137, 231, 231, 231, 231, 230,
|
||||
230, 231, 231, 231, 231, 230, 230, 231, 231, 231, 231, 230, 230, 231, 231, 231, 231, 137, 137, 136, 136, 135, 135, 48, 40, 0, 0, 0, 135, 135, 136, 136, 137, 137, 232,
|
||||
233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 232, 233, 137, 137, 136, 136, 135, 135, 0, 0, 65, 44, 0, 1, 1,
|
||||
288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288,
|
||||
288, 289, 289, 290, 290, 290, 289, 1, 1, 49, 36, 0, 1, 1, 234, 234, 235, 235, 236, 236, 235, 235, 234, 234, 235, 235, 236, 236, 235, 235, 234, 234, 235, 235, 236, 236,
|
||||
235, 235, 234, 234, 235, 235, 236, 236, 235, 235, 1, 1, 50, 64, 0, 238, 238, 239, 239, 240, 240, 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, 240, 240, 241, 241,
|
||||
240, 240, 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, 240, 240, 241, 241, 240, 240, 241, 241, 241, 241, 241, 241, 241, 241, 240, 240, 239, 239, 238,
|
||||
238, 238, 238, 238, 238, 237, 237, 238, 238, 237, 237, 51, 8, 0, 238, 238, 237, 237, 238, 238, 239, 239, 52, 12, 0, 238, 239, 240, 241, 242, 243, 244, 245, 246, 247,
|
||||
248, 249, 53, 6, 0, 251, 251, 238, 238, 238, 238, 54, 25, 0, 168, 168, 169, 169, 170, 170, 171, 171, 170, 170, 169, 169, 168, 168, 169, 169, 169, 168, 168, 169, 169,
|
||||
170, 170, 169, 168, 55, 4, 0, 253, 253, 254, 254, 56, 64, 0, 1, 3, 270, 268, 1, 3, 270, 268, 1, 3, 270, 268, 1, 3, 270, 268, 1, 3, 270, 268, 1, 3, 270, 268, 1, 3, 270,
|
||||
268, 1, 3, 270, 268, 1, 2, 3, 4, 270, 269, 268, 0, 1, 2, 3, 4, 270, 269, 268, 0, 1, 1, 2, 2, 3, 3, 4, 4, 270, 270, 269, 269, 268, 268, 0, 0, 57, 90, 0, 266, 267, 266,
|
||||
267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 266, 267, 40, 40, 40, 40, 41, 41, 41, 41,
|
||||
40, 40, 40, 40, 40, 40, 40, 41, 41, 41, 40, 40, 40, 40, 40, 40, 40, 41, 41, 41, 40, 40, 42, 42, 42, 43, 43, 43, 44, 44, 44, 45, 45, 45, 46, 46, 47, 47, 46, 46, 47, 47
|
||||
, 46, 46, 47, 47, 46, 46, 47, 47, 46, 46, 82, 10, 0, 0, 268, 268, 269, 269, 269, 269, 268, 268, 0, 58, 14, 0, 274, 274, 271, 271, 271, 271, 272, 272, 273, 273, 273,
|
||||
273, 274, 274, 66, 16, 0, 291, 291, 292, 292, 293, 293, 294, 294, 295, 295, 294, 294, 293, 293, 292, 292, 72, 1, 0, 320, 73, 24, 0, 319, 319, 318, 318, 317, 317, 318,
|
||||
318, 319, 319, 320, 320, 321, 321, 322, 322, 323, 323, 322, 322, 321, 321, 320, 320, 74, 128, 0, 1, 1, 2, 2, 3, 3, 4, 4, 270, 270, 269, 269, 268, 268, 0, 0, 1, 2, 3, 4
|
||||
, 270, 269, 268, 0, 1, 2, 3, 4, 270, 269, 268, 0, 1, 3, 270, 268, 2, 4, 269, 0, 1, 3, 270, 268, 2, 4, 269, 0, -1, 3, 270, -1, 2, -1, 269, 0, 1, -1, -1, 268, -1, -1,
|
||||
269, -1, -1, -1, -1, 270, -1, -1, 2, -1, -1, -1, -1, -1, -1, 29, 46, 47, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1
|
||||
, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 63, 92, 0, 263, 264, 265, 264, 263, 264, 265, 264, 263, 264, 265, 264
|
||||
, 263, 264, 265, 264, 263, 264, 265, 264, 263, 264, 265, 264, 263, 264, 265, 264, 263, 264, 265, 264, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0,
|
||||
0, 0, 23, 23, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 133, 133, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 0, 64, 104, 0, 1, 1, 2, 2, 3, 3,
|
||||
285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 285, 286, 287, 286, 3, 3, 2
|
||||
, 2, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 23, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 23, 23, 0, 0, 0, 0, 0, 0, 0, 133, 133, 0, 0, 0, 133, 133, 0, 0, 0, 0, 0, 0, 0, 133,
|
||||
133, 0, 0, 0, 0, 23, 23, 23, 23, 0, 0, 0, 0, 83, 60, 0, 1, 1, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290,
|
||||
290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 289, 288, 288, 289, 289, 290, 290, 290, 290, 290, 290, 290, 290, 290, 290,
|
||||
290, 290, 1, 1, 0
|
||||
};
|
||||
|
||||
extern int table_tutorial[] = {
|
||||
0, 2, 0, 7, -1, 0x190,
|
||||
3, 3, 0, 7, 0, 0x191,
|
||||
3, 4, 0, 7, -1, 0x192,
|
||||
6, 8, 0, 7, -1, 0x193,
|
||||
12, 12, 0, 7, 1, 0x194,
|
||||
12, 13, 0, 7, -1, 0x195,
|
||||
14, 15, 0, 7, -1, 0x196,
|
||||
16, 17, 0, 1, -1, 0x197,
|
||||
22, 23, 0, 7, -1, 0x198,
|
||||
29, 30, 0, 7, -1, 0x199,
|
||||
41, 44, 0, 7, -1, 0x19a,
|
||||
54, 63, 0, 7, -1, 0x19b,
|
||||
69, 70, 0, 7, -1, 0x19c,
|
||||
-1
|
||||
};
|
||||
|
||||
#endif
|
5867
src/event.cpp
Normal file
323
src/event.h
Normal file
@ -0,0 +1,323 @@
|
||||
// Event.h
|
||||
#ifndef EVENT_H
|
||||
#define EVENT_H
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "movie.h"
|
||||
#include "menu.h"
|
||||
#include "button.h"
|
||||
#include "text.h"
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT message;
|
||||
int type;
|
||||
int iconMenu[20];
|
||||
int x, y;
|
||||
int toolTips[20];
|
||||
}
|
||||
Button;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
UINT phase;
|
||||
char backName[36];
|
||||
BOOL bCDrom;
|
||||
BOOL bLocked;
|
||||
Button buttons[MAXBUTTON];
|
||||
}
|
||||
Phase;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
short majRev;
|
||||
short minRev;
|
||||
short bSchool;
|
||||
short bPrivate;
|
||||
short world;
|
||||
short skill;
|
||||
short reserve1[99];
|
||||
}
|
||||
DemoHeader;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int time;
|
||||
short input;
|
||||
UINT message;
|
||||
WPARAM wParam;
|
||||
LPARAM lParam;
|
||||
}
|
||||
DemoEvent;
|
||||
|
||||
|
||||
class CEvent
|
||||
{
|
||||
public:
|
||||
CEvent();
|
||||
~CEvent();
|
||||
|
||||
|
||||
void OutputNetDebug(const char* str);
|
||||
POINT GetMousePos();
|
||||
void Create(HINSTANCE hInstance, HWND hWnd, CPixmap *pPixmap, CDecor *pDecor, CSound *pSound, CNetwork *pNetwork, CMovie *pMovie );
|
||||
void SetFullScreen(BOOL bFullScreen);
|
||||
void SetMouseType(int mouseType);
|
||||
int GetWorld();
|
||||
int GetWorldGroup();
|
||||
void SetMission(int index);
|
||||
int GetPhysicalWorld();
|
||||
int GetImageWorld();
|
||||
BOOL IsHelpHide();
|
||||
BOOL ChangePhase(UINT phase);
|
||||
BOOL LoadImageFromDisc();
|
||||
UINT GetPhase();
|
||||
void MovieToStart();
|
||||
BOOL NetworkNuggets(int fuck);
|
||||
void HandleInputs();
|
||||
void ReadInput();
|
||||
void TryInsert();
|
||||
//void SomethingUserMissions(LPCSTR lpFileName, LPCSTR thing);
|
||||
BOOL CopyMission(char* pMission, char* pFile);
|
||||
void RestoreGame();
|
||||
int MissionBack();
|
||||
void TableSomething();
|
||||
int PlaceBuildItem(POINT cel, int flags, int currentIcon);
|
||||
|
||||
int GetButtonIndex(int button);
|
||||
int GetState(int button);
|
||||
void SetState(int button, int state);
|
||||
BOOL GetEnable(int button);
|
||||
void SetEnable(int button, int bEnable);
|
||||
void SetIconMenu(int button, int bSomething);
|
||||
BOOL GetHide(int button);
|
||||
void SetHide(int button, BOOL bHide);
|
||||
int GetMenu(int button);
|
||||
void SetMenu(int button, int menu);
|
||||
void SomethingDecor();
|
||||
BOOL IsMouseRelease();
|
||||
|
||||
void NetSetPause(BOOL bPause, BOOL bMulti);
|
||||
void NetSendLobby();
|
||||
|
||||
BOOL DrawButtons();
|
||||
BOOL TextSomething();
|
||||
int MousePosToSprite(POINT pos);
|
||||
void MouseSprite(POINT pos);
|
||||
void WaitMouse(BOOL bWait);
|
||||
void HideMouse(BOOL bHide);
|
||||
void DisableMouse(int bFill);
|
||||
POINT GetLastMousePos();
|
||||
BOOL TreatEvent(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
BOOL TreatEventBase(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
|
||||
void DecorAutoShift(POINT pos);
|
||||
|
||||
BOOL StartMovie(char *pFilename);
|
||||
void StopMovie();
|
||||
BOOL IsMovie();
|
||||
|
||||
void FlushInput();
|
||||
|
||||
void SetSpeed(int speed);
|
||||
int GetSpeed();
|
||||
BOOL GetPause();
|
||||
void GetDoors(int doors);
|
||||
BOOL IsShift();
|
||||
BOOL IsMulti();
|
||||
BOOL IsPrivate();
|
||||
|
||||
void DemoStep();
|
||||
void DebugDisplay(char m);
|
||||
|
||||
void IntroStep();
|
||||
void SetNbVies(int lives);
|
||||
|
||||
void ReadAll();
|
||||
BOOL SaveState(int rank);
|
||||
void SomethingUserMissions(char* lpFilename, LPCSTR fileSomething);
|
||||
|
||||
BOOL ClearGamer(int gamer);
|
||||
|
||||
protected:
|
||||
void DrawTextCenter(int res, int x, int y, int font=0);
|
||||
BOOL CreateButtons();
|
||||
BOOL EventButtons(UINT message, WPARAM wParam, LPARAM lParam);
|
||||
BOOL MouseOnButton(POINT pos);
|
||||
int SearchPhase(UINT phase);
|
||||
void DecorShift(int dx, int dy);
|
||||
|
||||
void ChangeButtons(int message);
|
||||
|
||||
void BuildFloor(POINT cel, int insIcon);
|
||||
void BuildWater(POINT cel, int insIcon);
|
||||
BOOL BuildDown(POINT pos, int fwKeys, BOOL bMix=TRUE);
|
||||
BOOL BuildMove(POINT pos, int fwKeys);
|
||||
BOOL BuildUp(POINT pos, int fwKeys);
|
||||
|
||||
void PrivateLibelle();
|
||||
BOOL ReadLibelle(int world, BOOL bSchool, BOOL bHelp);
|
||||
BOOL WriteInfo(int gamer);
|
||||
BOOL ReadInfo(int gamer);
|
||||
BOOL LoadState(BOOL save);
|
||||
void TryPhase();
|
||||
void UnTryPhase();
|
||||
int GetTryPhase();
|
||||
BOOL ReadPlayer();
|
||||
void PutTextInputBox(POINT pos);
|
||||
|
||||
|
||||
void DemoRecStart();
|
||||
void DemoRecStop();
|
||||
BOOL DemoPlayStart();
|
||||
void DemoPlayStop();
|
||||
void DemoRecEvent();
|
||||
|
||||
// Network Functions
|
||||
BOOL NetCreate(int session);
|
||||
BOOL NetEnumSessions();
|
||||
int NetSearchPlayer(DPID dpid);
|
||||
void NetStartPlay();
|
||||
void NetSend(int message, USHORT data);
|
||||
void NetDraw();
|
||||
void ChatSend();
|
||||
void ChatPush(char* str);
|
||||
void ChatPop();
|
||||
void ChatFlush();
|
||||
|
||||
void MouseRelease();
|
||||
void MouseCapture();
|
||||
int GameSave(int save);
|
||||
|
||||
void DrawMap();
|
||||
BOOL CheckWorld1();
|
||||
void NetAdjustLobbyButtons();
|
||||
|
||||
BOOL CurrentRead(BOOL bPrivate);
|
||||
BOOL CurrentWrite(int rank);
|
||||
|
||||
|
||||
protected:
|
||||
int m_speed;
|
||||
int m_exercice;
|
||||
int m_quicksaveIndex;
|
||||
int m_mission;
|
||||
char m_gamerName[100];
|
||||
char m_gamerNameList[MAXGAMER][100];
|
||||
BOOL m_gamerExist[MAXGAMER];
|
||||
void* m_somethingJoystick;
|
||||
int m_menuIndex;
|
||||
int m_choiceIndex;
|
||||
int m_saveIndex;
|
||||
int m_menuDecor[11];
|
||||
BOOL m_bMouseRelease;
|
||||
int m_private;
|
||||
int m_bNamesExist[MAXGAMER];
|
||||
int m_fileIndex;
|
||||
int m_maxMission;
|
||||
int m_phase;
|
||||
int m_index;
|
||||
int m_playerIndex;
|
||||
BOOL m_bSchool;
|
||||
BOOL m_bPrivate;
|
||||
BOOL m_bDrawMap;
|
||||
BOOL m_bMulti;
|
||||
BOOL m_bBuildOfficialMissions;
|
||||
BOOL m_bFullScreen;
|
||||
int m_mouseType;
|
||||
HWND m_hWnd;
|
||||
CPixmap* m_pPixmap;
|
||||
CDecor* m_pDecor;
|
||||
CSound* m_pSound;
|
||||
CMovie* m_pMovie;
|
||||
CNetwork* m_pNetwork;
|
||||
char m_movieToStart[MAX_PATH];
|
||||
int m_phaseAfterMovie;
|
||||
CButton m_buttons[MAXBUTTON];
|
||||
int m_lastFloor[MAXBUTTON];
|
||||
int m_lastObject[MAXBUTTON];
|
||||
int m_lastHome[MAXBUTTON];
|
||||
BOOL m_bRunMovie;
|
||||
BOOL m_bBuildModify;
|
||||
CJauge m_jauges[2];
|
||||
CMenu m_menu;
|
||||
BOOL m_bMenu;
|
||||
POINT m_menuPos;
|
||||
int m_menuNb;
|
||||
int m_menuButtons[MAXBUTTON];
|
||||
int m_menuErrors[MAXBUTTON];
|
||||
int m_menuPerso;
|
||||
POINT m_menuCel;
|
||||
POINT m_oldMousePos;
|
||||
BOOL m_bMousePress;
|
||||
BOOL m_bMouseDown;
|
||||
BOOL m_bHili;
|
||||
int m_fileWorld[10];
|
||||
int m_fileTime[10];
|
||||
POINT m_posToolTips;
|
||||
char m_textToolTips[50];
|
||||
char m_textToolTips2[50];
|
||||
int m_mouseSprite;
|
||||
BOOL m_bDisableMouse;
|
||||
BOOL m_bWaitMouse;
|
||||
BOOL m_bHideMouse;
|
||||
BOOL m_bShowMouse;
|
||||
int m_rankCheat;
|
||||
int m_posCheat;
|
||||
BOOL m_bMovie;
|
||||
BOOL m_bSpeed;
|
||||
BOOL m_bHelp;
|
||||
BOOL m_bAllMissions;
|
||||
BOOL m_bChangeCheat;
|
||||
int m_scrollSpeed;
|
||||
BOOL m_bPause;
|
||||
BOOL m_bShift;
|
||||
int m_shiftPhase;
|
||||
POINT m_shiftVector;
|
||||
POINT m_shiftOffset;
|
||||
char m_libelle[1000];
|
||||
char m_filenameBuffer[100][256];
|
||||
int m_tryPhase;
|
||||
int m_tryInsertCount;
|
||||
POINT m_posInfoButton;
|
||||
POINT m_posHelpButton;
|
||||
BOOL m_bHiliInfoButton;
|
||||
BOOL m_bHiliHelpButton;
|
||||
BOOL m_bInfoHelp;
|
||||
BOOL m_bDemoRec;
|
||||
BOOL m_bDemoPlay;
|
||||
DemoEvent* m_pDemoBuffer;
|
||||
int m_demoTime;
|
||||
int m_demoIndex;
|
||||
int m_demoEnd;
|
||||
int m_demoNumber;
|
||||
BOOL m_bCtrlDown;
|
||||
POINT m_debugPos;
|
||||
int m_introTime;
|
||||
int m_joyID;
|
||||
int m_gamer;
|
||||
int m_textHiliStart;
|
||||
int m_textHiliEnd;
|
||||
int m_textCursorIndex;
|
||||
char m_textInput[100];
|
||||
char m_pPlayerName[100];
|
||||
int m_lives;
|
||||
int m_multi;
|
||||
HINSTANCE m_hInstance;
|
||||
char m_chatZone[100][5];
|
||||
char m_text[100];
|
||||
int m_keyPress;
|
||||
|
||||
int m_choicePageOffset;
|
||||
int m_nbChoices;
|
||||
int m_0008;
|
||||
int m_6D30;
|
||||
int m_96B4;
|
||||
int m_nbVies;
|
||||
};
|
||||
|
||||
extern
|
||||
int DirectoryThing(LPCSTR filename);
|
||||
|
||||
#endif
|
144
src/jauge.cpp
Normal file
@ -0,0 +1,144 @@
|
||||
// Jauge.cpp
|
||||
//
|
||||
|
||||
#include <windows.h>
|
||||
//#include <stdlib.h>
|
||||
//#include <stdio.h>
|
||||
#include <ddraw.h>
|
||||
#include "def.h"
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
#include "decor.h"
|
||||
#include "jauge.h"
|
||||
#include "misc.h"
|
||||
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////
|
||||
|
||||
// Constructor
|
||||
|
||||
CJauge::CJauge()
|
||||
{
|
||||
m_type = 0;
|
||||
m_bHide = TRUE;
|
||||
m_bMinimizeRedraw = FALSE;
|
||||
m_bRedraw = FALSE;
|
||||
}
|
||||
|
||||
// Destructor
|
||||
|
||||
CJauge::~CJauge()
|
||||
{
|
||||
}
|
||||
|
||||
// Create a new Button.
|
||||
|
||||
BOOL CJauge::Create(HWND hWnd, CPixmap *pPixmap, CSound *pSound,
|
||||
POINT pos, int type, BOOL bMinimizeRedraw)
|
||||
{
|
||||
m_hWnd = hWnd;
|
||||
m_pPixmap = pPixmap;
|
||||
m_pSound = pSound;
|
||||
m_type = type;
|
||||
m_bMinimizeRedraw = bMinimizeRedraw;
|
||||
m_bHide = TRUE;
|
||||
m_pos = pos;
|
||||
m_dim.x = DIMJAUGEX;
|
||||
m_dim.y = DIMJAUGEY;
|
||||
m_level = 0;
|
||||
m_bRedraw = TRUE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void CJauge::Draw()
|
||||
{
|
||||
RECT rect;
|
||||
char num2[12];
|
||||
|
||||
if (m_bMinimizeRedraw && !m_bRedraw) return;
|
||||
m_bRedraw = FALSE;
|
||||
|
||||
if (m_bHide) // bouton cach<63> ?
|
||||
{
|
||||
rect.right = m_dim.x + m_pos.x;
|
||||
rect.left = m_pos.x;
|
||||
rect.top = m_pos.y;
|
||||
rect.bottom = m_dim.y + m_pos.y;
|
||||
m_pPixmap->DrawPart(-1, 0, m_pos, rect, 1, FALSE);
|
||||
return;
|
||||
}
|
||||
int num = m_level * 114 / 100;
|
||||
|
||||
*(char*)num2 = (124) / 64;
|
||||
rect.bottom = 22;
|
||||
rect.left = LOWORD(num2);
|
||||
rect.top = HIWORD(num2);
|
||||
rect.right = HIWORD(num2);
|
||||
m_pPixmap->DrawPart(-1, 5, m_pos, rect, 0, FALSE);
|
||||
if (num > 0)
|
||||
{
|
||||
rect.bottom = num + 6;
|
||||
rect.left = m_type * 22;
|
||||
rect.top = (m_type + 1) * 22;
|
||||
rect.right = 0;
|
||||
m_pPixmap->DrawPart(-1, 5, m_pos, rect, 0, FALSE);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void CJauge::Redraw()
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
void CJauge::SetLevel(int level)
|
||||
{
|
||||
if ( level < 0 ) level = 0;
|
||||
if ( level > 100 ) level = 100;
|
||||
|
||||
if ( m_level != level )
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_level = level;
|
||||
}
|
||||
|
||||
int CJauge::GetLevel()
|
||||
{
|
||||
return m_level;
|
||||
}
|
||||
|
||||
|
||||
int CJauge::GetType()
|
||||
{
|
||||
return m_type;
|
||||
}
|
||||
|
||||
|
||||
void CJauge::SetType(int type)
|
||||
{
|
||||
if ( m_type != type )
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_type = type;
|
||||
}
|
||||
|
||||
BOOL CJauge::GetHide()
|
||||
{
|
||||
return m_bHide;
|
||||
}
|
||||
|
||||
void CJauge::SetHide(BOOL bHide)
|
||||
{
|
||||
if ( m_bHide != bHide )
|
||||
{
|
||||
m_bRedraw = TRUE;
|
||||
}
|
||||
|
||||
m_bHide = bHide;
|
||||
}
|
||||
|
47
src/jauge.h
Normal file
@ -0,0 +1,47 @@
|
||||
// Jauge.h
|
||||
#ifndef JAUGE_H
|
||||
#define JAUGE_H
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
|
||||
class CJauge
|
||||
{
|
||||
public:
|
||||
CJauge();
|
||||
~CJauge();
|
||||
|
||||
BOOL Create(HWND hWnd, CPixmap *pPixmap, CSound *pSound,
|
||||
POINT pos, int type, BOOL bMinimizeRedraw);
|
||||
void Draw();
|
||||
void Redraw();
|
||||
|
||||
void SetLevel(int level);
|
||||
int GetLevel();
|
||||
void SetType(int type);
|
||||
int GetType();
|
||||
|
||||
BOOL GetHide();
|
||||
void SetHide(BOOL bHide);
|
||||
|
||||
POINT GetPos();
|
||||
void SetRedraw();
|
||||
|
||||
protected:
|
||||
HWND m_hWnd;
|
||||
CPixmap* m_pPixmap;
|
||||
CSound* m_pSound;
|
||||
BOOL m_bHide;
|
||||
POINT m_pos;
|
||||
POINT m_dim;
|
||||
int m_type;
|
||||
int m_level;
|
||||
BOOL m_bMinimizeRedraw;
|
||||
BOOL m_bRedraw;
|
||||
};
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#endif
|
158
src/menu.cpp
Normal file
@ -0,0 +1,158 @@
|
||||
// Menu.cpp
|
||||
//
|
||||
|
||||
#include <windows.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <ddraw.h>
|
||||
#include "def.h"
|
||||
#include "resource.h"
|
||||
#include "pixmap.h"
|
||||
#include "sound.h"
|
||||
#include "decor.h"
|
||||
#include "button.h"
|
||||
#include "menu.h"
|
||||
#include "text.h"
|
||||
#include "misc.h"
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
#define MARGMENU 0
|
||||
|
||||
|
||||
static short table_button_icon[] =
|
||||
{
|
||||
24, // go
|
||||
40, // stop
|
||||
32, // mange
|
||||
30, // carry
|
||||
31, // depose
|
||||
22, // abat
|
||||
27, // roc
|
||||
28, // cultive
|
||||
19, // build1 (cabane)
|
||||
25, // build2 (couveuse)
|
||||
35, // build3 (laboratoire)
|
||||
61, // build4 (mine)
|
||||
59, // build5 (usine)
|
||||
101, // build6 (t<>l<EFBFBD>porteur)
|
||||
20, // mur
|
||||
26, // palis
|
||||
42, // abat n
|
||||
43, // roc n
|
||||
23, // pont
|
||||
33, // tour
|
||||
34, // boit
|
||||
39, // labo
|
||||
54, // fleur
|
||||
55, // fleur n
|
||||
41, // dynamite
|
||||
58, // bateau
|
||||
60, // djeep
|
||||
64, // drapeau
|
||||
62, // extrait du fer
|
||||
65, // fabrique jeep
|
||||
63, // fabrique mine
|
||||
83, // fabrique disciple
|
||||
100, // repeat
|
||||
107, // qarmure
|
||||
106, // fabarmure
|
||||
};
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
CMenu::CMenu()
|
||||
{
|
||||
m_nbButtons = 0;
|
||||
m_selRank = -1;
|
||||
}
|
||||
|
||||
CMenu::~CMenu()
|
||||
{
|
||||
}
|
||||
|
||||
void CMenu::Delete()
|
||||
{
|
||||
m_nbButtons = 0;
|
||||
m_selRank = -1;
|
||||
}
|
||||
|
||||
BOOL CMenu::TreatEvent(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
POINT pos;
|
||||
|
||||
if ( m_nbButtons == 0 ) return FALSE;
|
||||
|
||||
pos = ConvLongToPos(lParam);
|
||||
|
||||
switch( message )
|
||||
{
|
||||
case WM_LBUTTONDOWN:
|
||||
case WM_RBUTTONDOWN:
|
||||
if ( MouseDown(pos) ) return TRUE;
|
||||
break;
|
||||
|
||||
case WM_MOUSEMOVE:
|
||||
if ( MouseMove(pos) ) return TRUE;
|
||||
break;
|
||||
case WM_LBUTTONUP:
|
||||
case WM_RBUTTONUP:
|
||||
if ( MouseUp(pos) ) return TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
int CMenu::Detect(POINT pos)
|
||||
{
|
||||
int rank;
|
||||
|
||||
if ( pos.x < m_pos.x || pos.x > m_pos.x+m_dim.x ||
|
||||
pos.y < m_pos.y || pos.y > m_pos.y+m_dim.y ) return -1;
|
||||
|
||||
rank = (pos.y-m_pos.y)/(DIMBUTTONY+MARGMENU);
|
||||
rank += ((pos.x-m_pos.x)/(DIMBUTTONX+MARGMENU))*m_nbCel.y;
|
||||
|
||||
if ( rank >= m_nbButtons ) return -1;
|
||||
return rank;
|
||||
}
|
||||
|
||||
BOOL CMenu::MouseDown(POINT pos)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CMenu::MouseMove(POINT pos)
|
||||
{
|
||||
m_mousePos = pos;
|
||||
m_selRank = Detect(pos);
|
||||
|
||||
if ( pos.x < m_pos.x-(DIMBUTTONX+MARGMENU) ||
|
||||
pos.x > m_pos.x+m_dim.x+(DIMBUTTONX+MARGMENU) ||
|
||||
pos.y < m_pos.y-(DIMBUTTONY+MARGMENU) ||
|
||||
pos.y > m_pos.y+m_dim.y+(DIMBUTTONY+MARGMENU) )
|
||||
{
|
||||
Delete(); // enl<6E>ve le menu si souris trop loin !
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
BOOL CMenu::MouseUp(POINT pos)
|
||||
{
|
||||
m_mousePos = pos;
|
||||
m_selRank = Detect(pos);
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
void CMenu::Message()
|
||||
{
|
||||
if ( m_selRank != -1 )
|
||||
{
|
||||
PostMessage(m_hWnd, WM_BUTTON0+m_selRank, 0, 0);
|
||||
}
|
||||
}
|
53
src/menu.h
Normal file
@ -0,0 +1,53 @@
|
||||
// Menu.h
|
||||
#ifndef MENU_H
|
||||
#define MENU_H
|
||||
|
||||
#include "decor.h"
|
||||
#include "pixmap.h"
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
||||
class CMenu
|
||||
{
|
||||
public:
|
||||
CMenu();
|
||||
~CMenu();
|
||||
|
||||
BOOL Create(HWND hWnd, CPixmap *pPixmap, CSound *pSound,
|
||||
POINT pos, int nbm, int *pButtons, int *pErrors,
|
||||
int perso);
|
||||
void Update(int nb, int *pButtons, int *pErrors);
|
||||
void Delete();
|
||||
void Draw();
|
||||
int GetSel();
|
||||
int GetRank();
|
||||
BOOL IsError();
|
||||
BOOL IsExist();
|
||||
void Message();
|
||||
|
||||
BOOL TreatEvent(UINT message, WPARAM wParam, LPARAM lPararm);
|
||||
|
||||
protected:
|
||||
int Detect(POINT pos);
|
||||
BOOL MouseDown(POINT pos);
|
||||
BOOL MouseMove(POINT pos);
|
||||
BOOL MouseUp(POINT pos);
|
||||
|
||||
protected:
|
||||
HWND m_hWnd;
|
||||
CPixmap* m_pPixmap;
|
||||
CDecor* m_pDecor;
|
||||
CSound* m_pSound;
|
||||
POINT m_pos;
|
||||
POINT m_dim;
|
||||
int m_nbButtons;
|
||||
POINT m_nbCel;
|
||||
int m_perso;
|
||||
int m_buttons[MAXBUTTON];
|
||||
int m_errors[MAXBUTTON];
|
||||
UINT m_messages[MAXBUTTON];
|
||||
int m_selRank;
|
||||
POINT m_mousePos;
|
||||
};
|
||||
|
||||
#endif
|