09-01-15, 01:18 | #1101 |
Member
Joined: Jul 2012
Posts: 4,286
|
As far as I know HEAVY's are activated by any movable/shatterable that isn't a part of the LARA object or accessories. It asks "Is something other than LARA active on my square?" if yes, activate, if no, don't.
|
09-01-15, 06:14 | #1102 |
Member
Joined: May 2010
Posts: 256
|
Added first prototype for the inventory!
Check my fork for pulls! It's a very simple attempt at a ring inventory (I plan on doing many different type of inventories following the suggestions, but I want to remake the ring and the TR4/5 one first, then merge them into a new, customizable type ). It can be opened and closed with ESC. Also, I added colored lines in the console to make it more readable (colors are fully editable of course) and changed the text graphic, the green boxes were really making my eyes bleed. I was also messing a bit with the camera, so beware of that! I wanted to make a video for the inventory, but it's 7:15 am here, so....... I think I'll do it tomorrow Last edited by Nickotte; 09-01-15 at 06:16. |
09-01-15, 06:30 | #1103 |
Member
Joined: Jun 2007
Posts: 26,911
|
If you want to know which fonts I used in my mock-up or need someone to make icons, etc. for the inventory, just ask .
|
09-01-15, 06:31 | #1104 | ||
Moderator
Joined: Dec 2011
Posts: 4,881
|
Quote:
With additional, TRNG information. Quote:
And if you want to why ANTITRIGGER is TRIGGER for CD: http://www.tombraiderforums.com/showthread.php?t=205393 Last edited by AkyV; 09-01-15 at 06:56. |
||
09-01-15, 07:12 | #1105 |
Member
Joined: Apr 2013
Posts: 343
|
Well, I compiled the source code from Federico Barlotti and press ESC button in engine but it doesn't show the inventory at all. Is it necessary to add anything to config file?
OK, now it works. I forgot to add "bind(act.inventory, KEY_ESCAPE);" to config file. I was fool Great job, finally open tomb has ring inventory menu Last edited by Ado Croft; 09-01-15 at 08:23. |
09-01-15, 11:49 | #1106 |
Member
Joined: Apr 2013
Posts: 343
|
As far as I know HEAVY is activated by any moveables, except of enemies and Lara and moreover it is also activated by flyby camera
|
09-01-15, 12:22 | #1107 | ||||
Member
Joined: Aug 2010
Posts: 1,810
|
Wow, that was quick! Thank you SO much, I'll check out changes as soon as possible - right now I'm in the middle of re-writing trigger engine, so this makes merging a bit difficult...
Quote:
Quote:
By the way, how did you managed to "disable" game loop while being in inventory? Original TRs had 3 or 4 states (I don't remember exactly) dealing with main loop pipeline, one for game mode, one for inventory mode, one for text menu mode and one for flyby. Maybe I'm wrong, but you got the idea... Quote:
Edit: tested inventory prototype! Works great! Debug info now has to go now, by the way! At least in inventory/console modes. Also use commands has to be implemented some way, I'm not sure how to do it, however... Best way is through script command (so we have to implement some kind of "useItem" command which will activate per-item function, which can be implemented into some kind of item function array... I don't know! ). Few bugs I've noticed: 1. Item rotation resets when you scroll the item. In originals, item rotation gradually returned to initial state, so the item front side was faced "outside" ring center. 2. Up/down keys are changing item focus without scrolling. Also, you have put item inventory control into DebugKeys function, I think it's better to relocate it to Controls_Key function and make the use of action states instead of strict SDLK states. 3. Item order doesn't comply with original order; I guess, we can sort items by ITEM_TYPE and item index values, e. g. at first we enumerate supplies (weapons, ammo, flares, medipacks), then we enumerate quest items, etc. Although sorting by ITEM_TYPE doesn't make sense if you plan to make three-ring system, as in TR1-3! 4. If inventory is activated, console commands like setlevel won't work unless you'll exit inventory. It's not actually a bug, as it should work this way, but fader with loading screen confused me a bit. Anyway, sorry for my rant about these bugs, I understand it's only prototype, and it indeed works great! Quote:
AkyV: Thanks, that's exactly what I needed - although the setup for HEAVY_SWITCH trigger still doesn't make sense to me. I mean, in TR1 we had perfectly working HEAVY_TRIGGER which did deactivation if item left trigger sector (first movable block in St. Francis Folly), why they developed HEAVY_SWITCH in the first place... I think I won't trash my head with this for now, I'll try to implement at least basic Lara's triggers and leave others for later. Last edited by Lwmte; 09-01-15 at 15:09. |
||||
09-01-15, 16:39 | #1108 | |||
Member
Joined: May 2010
Posts: 256
|
Ah, you beat me to it! XDD
Quote:
Quote:
The item rotation is a pain, I managed to make it work a bit for the moment, but it has two flaws I have to correct: first, the rotation is absolute so if the item rotated 100 times around it'll rotate 100 times back instead of only one; also, for some reason it's not consistent, sometimes it'll skip a frame and look like it's been reset instead of gradually rotating back, although I assure you it does rotate back. The up/down keys originally scrolled between the rows of the inventory table, now they just make the selection jump from the first to the last item since I didn't completely replace the functions yet. Also, yeah, the keys functions were originally in the debug section, but I'm gonna port them to the controls eventually. The item order only obeys the adding order for now, I'll add some stuff to the item struct to make it easier (hopefully without ruining compatibility!) Finally, yeah, since I just copy-pasted the inventory into the console update check, that's why it doesn't set the level and other stuff until you turn it off. Quote:
EDIT: Fixed item rotation! Why overcomplicating it? I just moved the angle values from the inventory struct to the item node struct Last edited by Nickotte; 09-01-15 at 17:29. |
|||
09-01-15, 23:00 | #1109 | |||
Member
Joined: Aug 2010
Posts: 1,810
|
Quote:
Quote:
Here's my idea of inventory menu item struct: Code:
typedef struct gui_invmenu_item_s { float current_angle; float original_angle; float size; uint32_t id; uint32_t count; char* title; char* description; } Another thing to note is that we must somehow manage to define each item's possible actions, e.g. for weapons its equip, choose ammo and possibly combine with lasersight. For normal items it's use or combine. This info can also be kept in Lua script, as different game versions may contain different item layouts (like in TR1-3 shotgun only had one type of ammo, while it had three in TR4-5). Quote:
Last edited by Lwmte; 09-01-15 at 23:07. |
|||
09-01-15, 23:13 | #1110 |
Member
Joined: Dec 2010
Posts: 2,773
|
Excellent work guys. I'm dying to try this out but it looks like SourceForge is currently down... Well it claims to be.
|
Thread Tools | |
|
|