Git Product home page Git Product logo

vitrix's Introduction

Vitrix logo

Vitrix is an open-source FPS video game coded in !

📣 Discussions | ❗ Report an error | 🎁 Submit a feature | 📈 Community Insights

stars forks contributors prs issues license
Check out the Vitrix:

Made with ❤️ by ShadityZ and contributors




Everybody knows lots of diffent FPS shooter games, from Fortnite to CS:GO, the list is longly tiresome. So, what's any different about Vitrix? Well first of all, it has a really cool name. Second of all, it is open-source! No more sneaky malware in your closed-source applications, because the code of Vitrix is fully open and accessible to the community! Well? What are you waiting for? Go ahead and download it if you haven't already, and dive into a world of Vitrix fun!

Frequently Asked Questions (FAQ):

Game Video/Screen Settings:

Q: Is there a way to change the screen’s dimensions i.e. width and height? A: Yes! Post-cloning the repository, navigate to the /Vitrix/vitrix/menu.py file. Upon inspecting the code, the “window” object has its attribute size set to two parameters (“default_width” and “default_height”). Initializing these to different integer values will alter the game’s screen dimensions.

Q: Is there a way to toggle whether the screen is borderless or whether it displays in a windowed format? A: Yes! Post-cloning the repository, navigate to the /Vitrix/vitrix/menu.py file. Upon inspecting the code, the “window” object has its attribute borderless which is a boolean toggle for whether the screen is windowed or borderless. As of 2/12/2023, the default setting in the source code is borderless.

Q: Is there a way to toggle whether the screen fullscreen? A: Yes! Post-cloning the repository, navigate to the /Vitrix/vitrix/menu.py file. Upon inspecting the code, the “window” object has its attribute fullscreen which is a boolean toggle for whether the game’s contents are shown as fullscreen or not.

In Game Weapons:

Q: Where can I access source code for the weapons used in game? A: Navigate to the directory “/Vitrix/vitrix/lib/weapons” to find the python source code for each item and its in game statistics/specifications.

Q: I see that within each weapon’s class source code that there is a texture variable being initialized to an image path? Where are these images in the repository? A: Navigate to the directory “/Vitrix/vitrix/assets/textures” to find the images loaded into the game.

Anticheat/Multiplayer Auditing:

Q: Does Vitrix have anitcheat functionality implemented for its multiplayer gameplay? A: Indeed! Navigate to the directory “/Vitrix/vitrix/lib/classes” and access the “anticheat.py” file to see built in precautionary user metric audits to see if gameplay is genuine in its origin.

Q: What are the metrics that Vitrix uses to access whether a player is cheating or not? A: If user speed within the game is not within a deemed “normal” range, they will be kicked out of the game’s multiplayer session by a function call named “perform_quit()”. If the jump height integer wise does not match up with the original source code’s jump height, they will also be removed from the game. Artificial manipulated levels of player health exceeding 150 also indicate that the player is cheating which results in an automatic disconnect for the game.

Q: What are the consequences of a player cheating/how does the anticheat python script handle improper/irregular user behavior A: Through the invocation of the "perform_quit()" function, the player is disconnected from the sever.

Item Functionality:

Q: What does the first aid kit do/how does it function within the game? A: The first aid kit randomly restorces between 50 to 80 health. This is represented in the aid_kit.py file found in the directory "Vitrix/vitrix/lib/items/aid_kit.py" where the class attribute "health_restore" is initlized to a random value between 50 and 80 through the "random.randint(50, 80)" function which is derriven from the random library in python.

User Interface:

Q: Where are U.I. related scripts located? A: Within the directory "Vitrix/vitrix/lib/UI/"


You can find out everything you else you need to know in the Official Vitrix Documentation!

vitrix's People

Contributors

alexandrespallone avatar c0rupted avatar davecarrijo avatar dependabot[bot] avatar evhann avatar sandipanguha avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

vitrix's Issues

The "You Died!" text covers the "Paused" text

When you die, and the You Died! text appears on the screen, the mouse cursor doesn't escape grabb. So you have to use the tab key to pause the game, but even though it works, the Paused text actually covers the You Died! text, and makes half of it unreadable.

Test directory not found when running python build.py command

c:\source\Vitrix>python build.py

Build Path:        C:\source\Vitrix/build

------------------------------------------------------------------------------------------------------------------------

Preparing...

Done!

------------------------------------------------------------------------------------------------------------------------

Building...


C:
  from distutils.dir_util import copy_tree
package_folder: C:
asset_folder: .
screen resolution: (1920, 1080)
building project: C:
copying python
copying python Lib files
copying always included modules and extra modules
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying always include: C:
copying panda3d
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying: C:
copying ursina
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
compiling: C:
copying assets
ignore: C:
copying assetfolder: C:
ignore: C:
ignore: C:
copying assetfolder: C:
copying asset: C:
copying asset: C:
copying asset: C:
copying asset: C:
copying asset: C:
copying assetfolder: C:
ignore: .py
copying assetfolder: C:
C:
ignore: .py
ignore: .py
ignore: .py
creating .bat file
build complete! time elapsed: 8.46418023109436



Traceback (most recent call last):
  File "c:\source\Vitrix\build.py", line 106, in <module>
    shutil.rmtree(build_path + item)
  File "C:\Users\turus\AppData\Local\Programs\Python\Python310\lib\shutil.py", line 747, in rmtree
    return _rmtree_unsafe(path, onerror)
  File "C:\Users\turus\AppData\Local\Programs\Python\Python310\lib\shutil.py", line 598, in _rmtree_unsafe
    onerror(os.scandir, path, sys.exc_info())
  File "C:\Users\turus\AppData\Local\Programs\Python\Python310\lib\shutil.py", line 595, in _rmtree_unsafe
    with os.scandir(path) as scandir_it:
FileNotFoundError: [WinError 3] The system cannot find the path specified: 'C:\\source\\Vitrix/build/src/test'

c:\source\Vitrix>

Above is the output from command prompt, error message being FileNotFoundError: [WinError 3] The system cannot find the path specified: 'C:\source\Vitrix/build/src/test'

Change in menu.py

Using,

if __name__ = '__main__':
    app.run()

allow other people reading the code know that menu.py is to be ran directly.

Build error on first time build

When building for the first time, windows python throws the error:

FileNotFoundError: [WinError3] The system cannot find the path specified: [build_location]

Aspect ratio goes crazy when launching

This is an issue where it shows that the aspect ratio of the window changes, but does it alot.

Here is the ouput of the log:

package_folder: /home/kanj/.local/lib/python3.9/site-packages/ursina
asset_folder: /home/kanj/Vitrix
OS: posix
screen resolution: (1366, 768)
Known pipe types:
  glxGraphicsPipe
(4 aux display modules not yet loaded.)
Xlib:  extension "XFree86-DGA" missing on display ":0".
:pnmimage:png(warning): iCCP: known incorrect sRGB profile
info: development mode: True
application successfully started
info: changed aspect ratio: 1.779 -> 1.333
info: changed aspect ratio: 1.333 -> 1.779
info: changed aspect ratio: 1.779 -> 1.333
info: changed aspect ratio: 1.333 -> 1.779
info: changed aspect ratio: 1.779 -> 1.333
info: changed aspect ratio: 1.333 -> 1.779

and etc...

Add settings

Add more settings and read/write user/settings.json

Process doesn't end when you close Vitrix from the window

When you click the x to close the window, the window closes, and the process doesn't stop. This uses unnecessary ram space, of up to 50 MBs.

A way around this is to terminate the process with Ctrl+C, or through the task manager, but the inefficiency is likely to be a problem when launching from gui, so a fix is required.

Chat Menu

The idea is a basic new server object called, "message", a new UI class that is used as a display for all the messages received. All of this and some other few perks and features I may add

Optimisation

Things to remove so the game is not too big (Windows):

vitrix/python/Lib/_pycache_/
vitrix/python/Lib/email/
vitrix/python/Lib/logging/_pycache_/ (and basically every _pycache_ folder)
vitrix/python/Lib/lib2to3/
vitrix/python/Doc/
vitrix/python/Tools/demo/
vitrix/python/Scripts/egg2maya*.exe
vitrix/python/Scripts/maya2egg*.exe
vitrix/python/Scripts/mayacopy*.exe
vitrix/python/Lib/site-packages/_pycache_/

When you remove all of these, the game is ~253 mb big

I'm gonna add more later

module missing, paths mixed up

venvctl should be in requirements. But even after that the paths are kind of warbled around and the only way I got it to run was to go inside the linux build, activate the virtual env, install ursina, create the '.unbuilt' file and run singleplayer.py directly.

Screenshot from 2022-04-15 14-25-02

and only way to quit seems to be alt+f4.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.