"Drawing" on the HUD - like in Arx Fatalis
Hi everyone again!
Is it possible to "draw" on the HUD? What I would like is when a player is moving the mouse, then the camera is not moving with it and a cursor is shown on the hud to see where is the mouse on the screen. Then add some sprites and lightings in front of the player to act as a mouse movement tracer. Basicly I would like to get an effect seen in the game: Arx Fatalis( not a HL engine game ). See the video of what I mean( 0: 30 ). http://www.youtube.com/watch?v=oMR-83YpIQM Oh and maybe get the coords of the mouse. Then from the coords I could try to estimate of what simbol was the user drawing. So my question is, can this be done in HL with amxmodx? Thank you in advance for any ideas and comments. |
Re: "Drawing" on the HUD
You can't draw directly on the HUD. The best you can do is draw like this:
http://forums.alliedmods.net/showthread.php?p=487998 |
Re: "Drawing" on the HUD
Okay, but to fix the camera for the player for a time, like in NS on a CO map, a menu pops up, and you see the cursor, you can select items from the menu...
|
Re: "Drawing" on the HUD
Come to think of it...
In Arx Fatalis, while I run forward and cast a spell, then a part of "magic drawing" is getting left behind, so it is indeed this way: the sparkle entites are drawn in front of the player and they do live for about 1-1.5 secs. And that could be done with the get_user_origin() function. And I've also thinked of: NS's ATTACK2 called menu works exactly like the ingame menu of CStrike - default key H, so that's propably the way it's done. But is it possible to toggle mouse look ingame controlled via a plugin? Edit: On disabling mouse look I mean the mouse is not used for rotating the camera and the cursor can be moved around on the HUD( or like that ) and not just stays in the center. |
Re: "Drawing" on the HUD
Okay guys, new approach.
First of all I need to disable rotating view with the mouse. I read in the coords of the player's angle, then calculate the direction, where the mouse moved. Then I draw a sprite( a hud icon ) to the position, plus I need to hide the actual cursor, while drawing. Also I need to disable any weapon orientated things. So far the code is this, and I will write my problem under the code: PHP Code:
But somehow it is possible to fix the camera. Tried setting pev_fixangle, but it didn't work as expected. Everyone experiances camera fixing, when a player's view is dragged around in a "video", or in spectator mode, or when dying. I saw on this forum somewhere a plugin, which allows disabling HUD elements, like money, or crosschair - maybe ConnorMcLeod's code? Also I saw a code here too, which I could draw a HUD icon to any position on the HUD. Thank you all for your helps in advance. |
Re: "Drawing" on the HUD
Maybe there is an ugly way to fix a user's view.:twisted:
Put a camera in the position of the player and hide the player to itself with FM_AddToFullPack. I think the camera's can be fixed that it goes only in a given direction( not paying attention to the player's angles ) with the method of not attaching the camera to the player. an get the coords by the angle settings of the player. I'm going to abuse this: https://forums.alliedmods.net/showthread.php?t=65427 |
Re: "Drawing" on the HUD
Allright, implemented the code, it's working so far, time to edit it.
PHP Code:
|
Re: "Drawing" on the HUD
Would like to see what you're doing, but:
Quote:
|
Re: "Drawing" on the HUD
Quote:
|
Re: "Drawing" on the HUD
Thank you!, forgot to add the file... :3
The plugin above on activation sets an external camera with fixed angles. I want to limit the player's rotation abilities, plus I want to remove the player model for the player. |
| All times are GMT -4. The time now is 10:19. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.