Jump to content

Scrolling


fumanshoo
 Share

Recommended Posts

I do not see a scrolling key under "constants/keycodes" I am trying to make a camera much like Skyrim and Fallout, but I can't find a "scroll up" or "scroll down" keycode. A link or path to the folder containing the script for scrolling keycodes would be much appreciated.

 

EDIT: I also have a completely unrelated question.... when I do the following code, my game does not pause or resume. Why is this not happening?

 

 

--pause/resume
if KeyDown(KEY_Y)==1 then
 PauseApp()
end
if KeyDown(KEY_U)==1 then
 ResumeApp()
end

Link to comment
Share on other sites

Keyboards have usually a Page Up and Page Down key, but not Scroll Up and Scroll Down keys:

KEY_PAGEUP

KEY_PAGEDOWN

 

To pause/resume a game, you should make a variable which is used to skip the major part of the main loop. Usually in pause mode the game still renders something, like a blurred image (at least in Crysis).

Ryzen 9 RX 6800M ■ 16GB XF8 Windows 11 ■
Ultra ■ LE 2.53DWS 5.6  Reaper ■ C/C++ C# ■ Fortran 2008 ■ Story ■
■ Homepage: https://canardia.com ■

Link to comment
Share on other sites

I saw the Page Up Page Down in "keycodes.lua", but what I mean is scrolling the middle mouse button. The closest I see is "MIDDLE_MOUSE", but it is referring to pressing down the middle mouse button. If it can be done by Bethesda, I can do it haha.

 

But thanks very much for the pause response. I think I will set a near Depth of Field behind the menu when I pause. That way, the game appears to be blurred in the background.

Link to comment
Share on other sites

would stop animations that are using AppSpeed()
\

 

Well I can not test animations because my graphics card does not support animation in LE, but my controller moves at AppSpeed() and when I pause, it does not stop my controller, so maybe or maybe not. I will see in a few months when my computer is fit.

Link to comment
Share on other sites

MouseZ() is used to detect rolling of the mouse wheel. Use only relative values though, because the absolute value is "stuck" whereever you started and left it. So you kinda need to do like this:

 

(before main loop):

mouse_z=MouseZ();

 

(in main loop):

mouse_old_z=mouse_z;

mouse_z=MouseZ();

mouse_z_diff=mouse_z-mouse_old_z;

 

and then use mouse_z_diff only in your game.

  • Upvote 1

Ryzen 9 RX 6800M ■ 16GB XF8 Windows 11 ■
Ultra ■ LE 2.53DWS 5.6  Reaper ■ C/C++ C# ■ Fortran 2008 ■ Story ■
■ Homepage: https://canardia.com ■

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...