Hello, I'm little bit confused, what is the question? If it's about how floats are truncated to long then in ANSI-C the cast from float to long is defined as "trunc" operation.
Last edited by Kada_CZ, .
Reason : a wrong example.
Hello,
I have the same experience. Sometimes, when I go to the serverlist ("list of games"), some servers are listed and then LFS freezes. I did'nt reported it as a bug, because I'm not able to reproduce it. It does happen approximatelly one time of 15. My lfs never freezes, except this server list case. It started with the V patch. I'm using router (USR8054). It never happens with other "heavy load" applications (e.g. quake server browser - XQF, bittorrent, flood ping).
Hello, I've made a new version of a simple program, that allows to display gear numbers on one 7 segment display connected to a LPT port. Additionally several other information (such as "low fuel", "rpm limiter", etc.) can be displayed. I provide sources in C (GPL) for it, so maybe someone here find it useful, please see GI homepage for more details.
It's the same as in Quake, you can look at the quake sources, if you don't believe me :-), they were released under GPL :-). I don't know, how the fps bug is handled when playing demos. But I know for sure, that Quake stores only player inputs and it plays demos correctly.
EDIT: I'm wrong , forget it. I just really looked into the sources, you are right, Quake 1 (but it would be similar in 3) stores object movement.
Yes it is. But you didn't look at the LFS client sources, did you? :-). Quake demos works on all machines, you can play speedrun demo on machine with 10 fps and it works. Playing demos is different from "regular" playing. My point is, that there _could_ be some similar fps bug (a feature, in Quake case :-)) in LFS. I agree, it seems, that there is no such thing in LFS and there are no symptoms of it. But we don't know it for certain and even Scawen doesn't know it for certain, because everyone makes mistakes.
Hello, it is not so obvious, as it seems. For example in (almost) all Quake 3 engine based games (quake3, rtcw, rtcw ET) one can jump faster with fps fixed to the certain number (3, 76, 125, or 333), explanation. I have no idea, if the framerate affects lap times in LFS, but maybe under some circumstances it could.
As I wrote, d3d implementation in wine is not finished (and it'll never be, because of new versions of api). Some things are implemented partially or wrong. For particular fixme you can look at the wine sources, why is the fixme there. If you don't like the messages/wanings/fixmes, you can suppress it by setting the variable WINEDEBUG, e.g.
WINEDEBUG=-all wine <application>
gives you no messages (it saves some fps).
I managed, how to display car textures (still far from perfect) with hardware vertex shading "on". Set "UseGLSL" to "enabled" in the registry editor (wine regedit), see UsefulRegistryKeys for details. It doesn't work with older nvidia drivers, I use 1.0-9631. I cannot use newer, because I have legacy GPU :-(. I get 55 FPS (gf 4200 ti) at blackwood.
Yes, I read about at least one succes by disabling haze effect to solve this issue. I tried almost everything, but it's goot to hear, that it should work with some settings. So I'll keep trying, thank you :-).
EDIT: I found it, you have to disable (set to "None") Vertex Shader Support in winecfg. It is not enough to disable Hardware Vertex Shader in LFS (it is still used, even if it's disabled, yes I restarted LFS). Unfortunatelly, this is a fps killer, I got 30 fps (60 fps with HVS). You have to also set "Simple track (no car shadows)" to "all", unless there are no textures on the track. The car still looks weird, all collors are wrong. Well, the d3d code in wine gets better in every wine release, so one day... :-). BTW I got force feedback working under wine for my wheel (WFF GP), but not in lfs.
E.g. OpenGL/GLX Information in nvidia settings tool, "Direct rendering" should be "Yes". But your glxgears looks good, you have accelerated openGL. Maybe "Antialiasing Settings"? I don't know why it is so slow, I have GF4200 Ti and I get around 50 fps at Blackwood. I use only 16bit color depth.
Question for all wine users, do you guys see textures on cars under wine? I see only wheels, chairs, driver body (without helmet) I have wine 0.9.32, but it's the same for all last year wine versions.
[RCG]Boosted: ad fps. Make sure, that you have hardware accelerated openGL working, if you're in doubt, attach here a result of a command:
glxinfo
EDIT: I just read your info by glxears it looks good. LFS under wine is set to the desktop resolution by default, maybe you have a high desktop resolution and thus lower frame rates?
A lots of fixmes is unfortunatelly quite usual, when running d3d application under wine. You can suppress it by running:
WINEDEBUG=-all wine LFS.exe
Crackling sound could be caused by no3d-accelerated running lfs. Check your opengl settings.
EDIT2: It's generally good idea to instal DCOM and IE under wine, it doesn't mean, that you have to use IE for web browsing. Some programs just use IE's dll for their purposes and thus they may work better than with wine's default native "emulation" dlls. No need to install them for LFS, though.
I still recommend, first of all get the notepad working with "real" x-windows. One more thing, if you are connecting to your linux machine (debian64) from another PC (pc) and you run x-application (wine notepad, xterm, ...), then x-server must running on the PC. There are other, more complicated methods, like VNC, see this thread.
First of all, you have to have working wine, it can be tested by the "wine notepad" command. If this doesn't work, then there is something wrong with your wine configuration/instalation. There can be several reasons for it (especially on a 64bit architecture). It's far beyond a scope of this thread to solve wine specific problems, I think .
My recommendation is: uninstall wine (purge it ideally), backup your configuration (~/.wine directory), then delete it (rm -r ~/.wine). Install a clean new actual version of wine (0.9.31). Run "winecfg" program, it creates a new ~/.wine directory. Try "wine notepad".
Try to install:
libx11-dev
xlibs-dev
libxxf86dga-dev
libxxf86misc-dev
If it doesn't work:
- What is your wine version? (wine --version)
- Did you compile wine for 64bit or do you use 32bit pre-compiled package?
- Does "wine notepad" command work (try it without tty driver)?
Wine does not use ~/.wine/config anymore, see docs.
For using Wine without X server add:
"Graphics"="tty"
into section:
[Software\Wine\Drivers]
in file ~/.wine/user.reg
Faikez: It seems to me, that X-server is not running, try the above.
EDIT: I just checked, that wine complains even if "/dedicated=invisible" option is set, it works fine with ttydriver. If ttydriver does not work, you could use "virtual" Xvfb x-server.
I like glib, but I would suggest to manage luaLFS without external libs, if possible (except libs for LUA). What I really love in this project, is the fact that it's cross platform capable. Each external library could cause problems.
Ok, your way is reasonable then. I'm sorry, I don't have much experience with programming under windows .
I agree with the concept "by tables" to allow user scripts access configuration. I don't see a better solution, but maybe someone else does :-).
I wouldn't be afraid of speed of a Lua code. On the other hand, I don't know how fast the Lua garbage collector works. But if the garbage collector would be the bottle neck, then we could use manual "finalizing" of values.
Hello angry_angel,
it's really nice idea. I played with your sources under Linux (Ubuntu dapper). Here are my notes:
- it doesn't work with LUA below 5.1, it's ok, but it could be mentioned somewhere, e.g. in the README,
- the main binary has to be started from the same directory, where the "scripts" directory is.
After some minor modifications it works :-).
In my Linux system, the declaration of a variable named "type" (in the file scripts/ISM.lua) overrides the lua language "type" function, used e.g. in event.lua like this: type(func) == "string". This leads to "attempt to call global 'type' (a number value)'" errors. It's ok after renaming the variable, e.g. to "type_ism" in ISM.lua (Disclaimer: I have no experience with lua ).
I modified the .c sources at several places, my modifications probably won't always compile under windows. I added src/Makefile and scripts/MSO.lua files, feel free to use them (e.g. put them into a trash, if you don't like them :-)).
Just one more note to insim_recv function. I don't like "busy waiting" code with "sleeps". I would recommend using either blocking recv or using "select" ("pselect") functions, what dou you think about it?
I attached the patch file and modified sources. I really like the idea of easy to use lua scripts, thank you for that .
Hello,
it seems to me, that you have "almost broken" some wire. It is hard to discover it. Try to check all your wires, wire by wire. The shematics for your Momo Force are at this page. Try to move wires, when checking.
Thank you for your answer. I don't suggest a solution in my post. If I could (wrong thread), I suggest a server option "allow_exec=no". I understand, that there are people, who like the /exec command. But, from my point of view, it could lead into security problems, when it is allowed executing _any_ program on the server. Our scenario with layouts is just one of several other possible scenarios, how to put "evil" script on the server.
Hello,
I have some remarks about /exec command. We would like to allow people to upload their layouts into our server. The problem is, if someone upload a file into "layout" directory named with "lfs" extension, for example: "layout\evil.lfs" file, and if the content of "evil.lfs" is /exec <some evil program such as format.exe>
then an admin (a person knowing an admin password) can do: "/hrun ..\layout\evil".
I see, if we allow to upload files on the server, it is a security flaw itself. We could allow to upload only files with ".lyt" extension and everyone doesn't know an admin password. I just would like to draw the attention of possible security problems with /exec and /hrun commands to users/developers.
Hello, thanks P1lot for advertising my GI project :-). I'm really sorry, I'm not able to keep in touch two threads in paralel. If you have comments, please post them on the rsc thread or contact me by PM. Comments _are_ welcome.