triang3l / webquake Goto Github PK
View Code? Open in Web Editor NEWHTML5/WebGL source port of Quake
HTML5/WebGL source port of Quake
... which is a gameplay breaker (well, kboard kung-fu is not well suited for FPSs)
Hi! I found your work pretty impressive!
For web server you use abyss web server
, but why not simply use node.js, like in Server/
part?
It would be much more uniform.
I think you should make Client/
as private npm module, like Server/
in my last Pull Request
hello i just wanted to know how to add pak files to the chrome os version of web quake, can anyne help me on how to do it?
in the meantime i will try to find a way to add it
edit (will be edited soon)
Does anybody hear the "beep beep" sound when touching certain doors on e1m1 in Chrome?
I had an issue when the game displayed "player" text in the center of the screen when touching some doors. I thought I fixed it by changing string indices from int16 to int32, and I actually fixed it in Firefox, but it looks like something is wrong in Chrome.
If a multiplayer server (ip:port) is set in the configuration file -- automatically connect to this server at startup / launch.
If this is already possible, how to configure such a setting is not readily findable in the documentation.
I know this is a long shot, but is there any way you could implement map rotation? I am aware that this feature is not available in vanilla Quake, only in QuakeWorld via localinfo, but maybe you have an idea how it could be done?
Thanks a lot for this port, i got it running on my server to frag a bit whenever i feel like ;-)
Especially noticeable when paused + alt tab.
$ node WebQDS.js
(...)
stuff scrolling by
(...)
map dm1
FindFile: id1/progs.dat
FindFile: can't find maps/dm.bsp
Couldn't spawn server maps/dm.bsp
quit
Unknown command "qui"
The last character is truncated/ignored or something. As a workaround one can simply add any character at the end.
I mean the "console" in the terminal I launched the server in, not RCON.
I'm opening up the client with Chrome and Firefox simultaneously and trying to connect to the same WebQuake server. Once I'm joining the game in the second browser window, the server kicks out the first. Why is this happening?
I've started the server with
-port <custom_port> -maxplayers 8
switches and if i open up http://<server_ip>:<custom_port>
i can see the game is really limited to 8 players. Does the server allows only one connection from the same IP address?
Thanks again,
When I launch from just the index file, I get this screen:
I am not sure of the file structure, or the instructions are somewhat vague on how to implement the game.
I found some information on the original discussion:
2013-02-11
20:12:14
Spirit
Administrator
Paul: For example like this
/dir/
/dir/WebQuake/
/dir/WebQuake.htm
/dir/id1/
/dir/id1/pak0.pak
/dir/rogue/
/dir/randommod/
Make sure everything is lowercase (unless you are on a Windows server).
Andrew, mods work. :) Try http://www.quaddicted.com/stuff/WebQuak … me%20qdqst or http://www.quaddicted.com/stuff/WebQuak … me%20czg07 (that one crashes after the start map) or http://www.quaddicted.com/stuff/WebQuak … me%20quoth (I have not tested that one yet).
This looks similar to what I have, but it still throws an error.
Hi there. i cant run mods. got the error everytime "Corrupted data file."
Even when i try to add not existing dir error is the same.
examles:
http://domain.tld/webquakedirwithindex.htm/?-game qr - dir exists, all files renamed to lowercase
http://domain.tld/webquakedirwithindex.htm/?-game airquake - dir exists, all files renamed to lowercase
http://domain.tld/webquakedirwithindex.htm/?-game notexist - dir not exists
console log output:
Host.Init
COM.js:301 Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check https://xhr.spec.whatwg.org/.
COM.LoadPackFile @ COM.js:301
Sys.js:25 FindFile: qr/gfx/pop.lmp
Sys.js:44 Added packfile id1/pak0.pak (339 files)
Sys.js:44 Added packfile id1/pak1.pak (85 files)
Sys.js:44 Added packfile qr/pak0.pak (131 files)
Sys.js:44 Added packfile qr/pak1.pak (23 files)
Sys.js:44 Added packfile qr/pak2.pak (5 files)
Sys.js:44 Added packfile qr/pak3.pak (74 files)
Sys.js:47 Uncaught Error: Corrupted data file.
at Object.Sys.Error (Sys.js:47)
at Object.COM.CheckRegistered (COM.js:124)
at Object.COM.Init (COM.js:172)
at Object.Host.Init (Host.js:292)
at window.onload (Sys.js:144)
This will require making webquake work with local files instead of websockets to fetch the paks and implement touchscreen controls.
I have verified that webquake runs fine on FxOS (2.2 at least), quite fluent in Flame, so it will be a great addition to the marketplace.
First of all, just wanted to say you guys have done a fabulous job so far. I've been running this on a chromebook, very stable, running at 100% speed. This is actually my first time playing it, and I would like to continue playing it on chrome. How's the full game feature coming? I would be willing to donate if you could assure me it would be coming in some reasonable amount of time.
Tested on latest versions of Chome and Firefox. Mouse is not captured by the web browser
please i need to know
In Quake you can turn in mid-air. Here this is not possible. If I jump and hold a turning key (or turn the mouse view), I will still fly into the "first" direction. This is a bug. In Quake I would have turned the jump's direction in the direction of the turn.
A problem that can happen when spinning around is that the position suddenly jumps a lot in Chrome.
There may be a fix for this that they have not pushed into Chrome yet.
I am only listing this issue here because I noticed it in WebQuake in-case others have this problem and think WebQuake is to blame, it is not related to WebQuake.
Possible work around, lerp the delta by some constant not ideal.
function lerp(v0, v1, t) {
return (1 - t) * v0 + t * v1;
}
function getChromeVersion () {
var pieces = navigator.userAgent.match(/Chrom(?:e|ium)\/([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)/);
if (pieces == null || pieces.length != 5) {
return undefined;
}
pieces = pieces.map(piece => parseInt(piece, 10));
return {
major: pieces[1],
minor: pieces[2],
build: pieces[3],
patch: pieces[4]
};
}
var usePointerLock360BugWorkaround = false;
var chromeVersion = getChromeVersion();
if (chromeVersion) {
usePointerLock360BugWorkaround = true;
IN.mouse_delta_x = 0;
IN.mouse_delta_y = 0;
}
IN.onmousemove = function(e)
{
if (document[IN.pointerLockElement] !== VID.mainwindow)
return;
if (usePointerLock360BugWorkaround === false) {
IN.mouse_x += e[IN.movementX];
IN.mouse_y += e[IN.movementY];
} else {
// Workaround Chrome mouseMove "sudden jump" bug.
IN.mouse_delta_x = lerp(IN.mouse_delta_x, e[IN.movementX], 0.75);
IN.mouse_delta_y = lerp(IN.mouse_delta_y, e[IN.movementY], 0.75);
IN.mouse_x += IN.mouse_delta_x;
IN.mouse_y += IN.mouse_delta_y;
}
};
Related links:
http://www.html5gamedevs.com/topic/34516-pointer-lock-bug-on-chrome-with-windows-10/
https://bugs.chromium.org/p/chromium/issues/detail?id=781182
https://bugs.chromium.org/p/chromium/issues/detail?id=461373
https://bugs.chromium.org/p/chromium/issues/detail?id=411634
https://bugs.chromium.org/p/chromium/issues/detail?id=784122
Possible work around to lerp the delta values found here, going to try adding this as a work-around.
mrdoob/three.js#12757
You already support overbrights (I think) and fullbrights, adding proper rendering of textures that are not in a power of 2 would be a great addition. See the bottom of http://www.quaddicted.com/engines/software_vs_glquake#non-square_pixels for examples.
http://www.html5rocks.com/en/tutorials/doodles/gamepad/
Would be sweet to support gamepads
edit:
Nevermind, I just saw the readme
Figured I'd write a note to let you know that I created a fork off this project that uses promises and recursion to support JS's async functions. The main reason for this is support indexed db, which requires async support to retrieve files. Also, synchronous IO functionality will be deprecated at some point anyway.
I was planning on extending your source further, adding some modern features (from proquake or qrack) and hosting a web based gaming environment. This requires users to specify their own local pak1 file (for licensing reasons).
Just wanted to get your thoughts on this project, and if you had any ideas for performance improvements
I just tried hosting this on my local server and it works great. Server runs great and so does the client.
I've also read here that the server accepts connections from WinQuake and GLQuake. So, I fired up WinQuake and tried connecting. It fails 5 seconds in with only a "client to server keepalive" message. Looking at the server-console, it displays the message SV.ReadClientMessage: unknown command char
and proceeds to remove the player.
I don't know if this is an issue with the server or my setup!
So I decided to Mirror WebQuake on http://h3ll.x10host.com/WebQuake/
I couldn't help but notice that the version on Quaddicted seems to be way better optimized than the latest on here, I tested on a Chromebook to confirm this (huge random performance drops on the latest version on here even with a performance-increasing autoexec)
I'm sure this is due to optimization, and I'm willing to fix this myself if I had a pointer on where to start on this
My target is Chromebooks due their wide usage in schools
I tried the old trick of issuing +mlook in the console.
As well as trying to bind +mlook to a key.
Nothing works... please help !
If you'd like to merge in async support for the XHR's, I have a branch here I can create a PR.
I don't know what I'm doing wrong, but I keep getting the error when I load the page.
Got this error when loading the quaddicted page, and also when cloning from github and running from local web server.
https://github.com/SiPlus/WebQuake/blob/master/Client/WebQuake/S.js#L818
Chrome
Version 36.0.1985.143
Platform 5841.98.0 (Official Build) stable-channel link
Tried running it on a server and after fidding with it to get it work (btw you need to tell people they need people they will also need gfx.wad and they need to be lower case if using a Linux server) and I am getting the error: Error compiling shader: null
Hello. A few questions:
Where are the entry point and main loop?
What each file is for? What's is your recommended order of reading them? What are dependencies between them?
Please add answer to README.md. I don't know if I'm stupid for asking this, other people seem to navigate in this code somewhat ok.
I've tried restarting my computer, deleting the app and re downloading it, and waited about 10 mins to see if it was just loading. I am not a computer wiz so i won't understand technical terms. I am using a MacBook Air to play. It was working yesterday but not now.
Copy "id1" folder from the Quake folder to the folder where you put WebQuake.htm.
- I can't find this folder in repository.
Without this folder I'm getting http://198.211.127.71/quake/WebQuake.htm "Corrupted data file"
From the docs:
You cannot join multiplayer games if the client is installed on https:// protocol, however.
Can you describe the technical issue with this, as I'm interested to see if there is a workaround.
Can not start the Client application...
Error
Sys.js:25 Host.Init
Q.js:115 TypeError: 'undefined' is not a function (evaluating 'Number.isNaN(val)'
The online demo is broken since I only get the following error: 502 Bad Gateway. I managed to port it using 000webhost free version: http://webquake.000webhostapp.com/
Hej!
I created a fork and put it in the chrome web store
https://github.com/kzahel/WebQuake
I am super impressed by your code. Did you write it from scratch by looking at the original source code? Did you use some kind of automatic translator?
I was wondering if you had done any work with quakeworld client / quakeworld server. I grew up playing those and would love to see them revived in a packaged app (which have UDP socket support, btw!)
After following the steps, I double clicked the .htm file to start Quake. A notification then showed up saying, Protocol is file, not http: or https:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.