Skip to content
This repository has been archived by the owner on Jul 24, 2022. It is now read-only.

Commit

Permalink
Merge tag 'g4.6.0' of https://github.com/coelckers/gzdoom
Browse files Browse the repository at this point in the history
  • Loading branch information
madame-rachelle committed May 22, 2021
2 parents bcccf77 + c320db6 commit 558498f
Show file tree
Hide file tree
Showing 11 changed files with 1,524 additions and 1,401 deletions.
20 changes: 11 additions & 9 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,20 +73,22 @@ jobs:
if [[ ! -z "${{ matrix.config.deps_cmdline }}" ]]; then
eval ${{ matrix.config.deps_cmdline }}
fi
# Build and install ZMusic
mkdir build
cd build
git clone https://github.com/coelckers/ZMusic.git
cd ZMusic
git checkout 1.1.6
cd ..
cmake -B zmusic_build -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DCMAKE_INSTALL_PREFIX=`pwd`/zmusic_install ${{ matrix.config.extra_options }} ZMusic
cmake --build zmusic_build --target install --parallel 3
if [[ "${{ runner.os }}" == 'macOS' ]]; then
export ZMUSIC_PACKAGE=zmusic-1.1.7-macos.tar.bz2
elif [[ "${{ runner.os }}" == 'Linux' ]]; then
export ZMUSIC_PACKAGE=zmusic-1.1.7-linux.tar.bz2
fi
if [[ ! -z "${ZMUSIC_PACKAGE}" ]]; then
cd build
wget -q "https://github.com/coelckers/gzdoom/releases/download/ci_deps/${ZMUSIC_PACKAGE}"
tar -xf "${ZMUSIC_PACKAGE}"
fi
- name: Configure
shell: bash
run: |
cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DCMAKE_PREFIX_PATH=`pwd`/build/zmusic_install ${{ matrix.config.extra_options }} .
cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DCMAKE_PREFIX_PATH=`pwd`/build/zmusic -DPK3_QUIET_ZIPDIR=ON ${{ matrix.config.extra_options }} .
- name: Build
shell: bash
Expand Down
6 changes: 3 additions & 3 deletions src/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ const char *GetVersionString();

/** Lots of different version numbers **/

#define VERSIONSTR "4.6pre"
#define VERSIONSTR "4.6.0"

// The version as seen in the Windows resource
#define RC_FILEVERSION 4,5,9999,0
#define RC_PRODUCTVERSION 4,5,9999,0
#define RC_FILEVERSION 4,6,0,0
#define RC_PRODUCTVERSION 4,6,0,0
#define RC_PRODUCTVERSION2 VERSIONSTR
// These are for content versioning.
#define VER_MAJOR 4
Expand Down
631 changes: 316 additions & 315 deletions wadsrc/static/language.0

Large diffs are not rendered by default.

603 changes: 314 additions & 289 deletions wadsrc/static/language.csv

Large diffs are not rendered by default.

9 changes: 7 additions & 2 deletions wadsrc/static/lmacros.csv
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ hij_ze_nl,nl,hij,ze,hij,hij
zijn_haar_nl,nl,zijn,haar,zijn,zijn
ao_pl,pl,,a,o,o
adj_pl,pl,y,a,e,e
irreg_1_pl,pl,szedł ,eszła,eszło,eszło
irreg_1_pl,pl,szedł ,eszła,eszło,eszło
irreg_2_pl,pl,ął,ęła,ęło,ęło
irreg_3_pl,pl,eś,aś,eś,eś
irreg_4_pl,pl,ógł,ogła,ogło,ogło
Expand All @@ -36,4 +36,9 @@ ao_2_sr,sr,ао,ла,ло,ло
ao_3_sr,sr,ог,у,ог,ог
adj_1_sr,sr,,а,о,о
adj_2_sr,sr,ан,на,но,но
adj_3_sr,sr,ар,ра,ро,ро
adj_3_sr,sr,ар,ра,ро,ро
pro_gr,gr,τον,την,τον,το
pro2_gr,gr,Τον,Την,Τον,Το
pro3_gr,gr,στον,στην,στο,στο
art_gr,gr,Ο,Η,Το,Το
pro4_gr,gr,του,της,του,του
3 changes: 2 additions & 1 deletion wadsrc/static/zscript.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
version "4.5"
version "4.6"

// Generic engine code
#include "zscript/engine/base.zs"
#include "zscript/engine/dynarrays.zs"
#include "zscript/engine/dictionary.zs"
#include "zscript/engine/inputevents.zs"
#include "zscript/engine/service.zs"

#include "zscript/engine/ui/menu/colorpickermenu.zs"
#include "zscript/engine/ui/menu/joystickmenu.zs"
Expand Down
99 changes: 99 additions & 0 deletions wadsrc/static/zscript/engine/service.zs
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
/**
* This is Service interface.
*/
class Service abstract
{
virtual play String Get(String request)
{
return "";
}

virtual ui String UiGet(String request)
{
return "";
}
}

/**
* Use this class to find and iterate over services.
*
* Example usage:
*
* @code
* ServiceIterator i = ServiceIterator.Find("MyService");
*
* Service s;
* while (s = i.Next())
* {
* String request = ...
* String answer = s.Get(request);
* ...
* }
* @endcode
*
* If no services are found, the all calls to Next() will return NULL.
*/
class ServiceIterator
{
/**
* Creates a Service iterator for a service name. It will iterate over all existing Services
* with names that match @a serviceName or have it as a part of their names.
*
* Matching is case-independent.
*
* @param serviceName class name of service to find.
*/
static ServiceIterator Find(String serviceName)
{
let result = new("ServiceIterator");

result.mServiceName = serviceName;
result.mClassIndex = 0;
result.FindNextService();

return result;
}

/**
* Gets the service and advances the iterator.
*
* @returns service instance, or NULL if no more servers found.
*
* @note Each ServiceIterator will return new instances of services.
*/
Service Next()
{
uint classesNumber = AllClasses.Size();
Service result = (mClassIndex == classesNumber)
? NULL
: Service(new(AllClasses[mClassIndex]));

++mClassIndex;
FindNextService();

return result;
}

private void FindNextService()
{
uint classesNumber = AllClasses.size();
while (mClassIndex < classesNumber && !ServiceNameContains(AllClasses[mClassIndex], mServiceName))
{
++mClassIndex;
}
}

private static bool ServiceNameContains(class aClass, String substring)
{
if (!(aClass is "Service")) return false;

String className = aClass.GetClassName();
String lowerClassName = className.MakeLower();
String lowerSubstring = substring.MakeLower();
bool result = lowerClassName.IndexOf(lowerSubstring) != -1;
return result;
}

private String mServiceName;
private uint mClassIndex;
}
Loading

0 comments on commit 558498f

Please sign in to comment.