JK2 Hilt selector code help

Discussions about modding, questions, mod requests or just show off what you're working on.
Post Reply
Kyojinmaru
Posts: 4
Joined: 16 Oct 2017, 17:22

JK2 Hilt selector code help

Post by Kyojinmaru » 16 Oct 2017, 17:23

Hi, I'm just trying to port the Tchouky hilt selector to basejk but I'm failing. I'm trying to isolate the code and remove all traces of hilt2, etc, but it doesn't work.

I just want that one feature for my mod, so I don't want to use JediMod, ForceMod, etc. If someone that knows about the code of this feature could help me, would be very grateful. Thanks.

User avatar
Boothand
Administrator
Posts: 968
Joined: 24 Feb 2015, 08:21
Contact:

Re: JK2 Hilt selector code help

Post by Boothand » 18 Oct 2017, 08:00

What have you done so far? Do you get compiler errors? If so, what does it say?
Or does it just do nothing in-game?

@Kameleon, you've done hilt selection for your mod, right?

Kyojinmaru
Posts: 4
Joined: 16 Oct 2017, 17:22

Re: JK2 Hilt selector code help

Post by Kyojinmaru » 18 Oct 2017, 10:51

I have compiler errors. I've tried deleting all JediMod 1.2 code, leaving only the hilt selector code and adapting it to the base game by removing hilt2 entries and all that, but no luck.

BTW, I'm doing it on the JediMod 1.2 source.

Kameleon
Administrator
Posts: 361
Joined: 07 Jun 2015, 08:36

Re: JK2 Hilt selector code help

Post by Kameleon » 18 Oct 2017, 14:27

Kyojinmaru wrote:
18 Oct 2017, 10:51
I have compiler errors. I've tried deleting all JediMod 1.2 code, leaving only the hilt selector code and adapting it to the base game by removing hilt2 entries and all that, but no luck.

BTW, I'm doing it on the JediMod 1.2 source.
If you want to remove all of the JediMod stuff except hilts anyway, why not just start with a clean basejk source, and then either port the hilt related things or write it from scratch?

By just removing varrious parts of JediMod you are sure to miss something that could cause future conflicts, or be the reason you have compiler errors right now.

Kyojinmaru
Posts: 4
Joined: 16 Oct 2017, 17:22

Re: JK2 Hilt selector code help

Post by Kyojinmaru » 18 Oct 2017, 20:15

Kameleon wrote:
18 Oct 2017, 14:27
Kyojinmaru wrote:
18 Oct 2017, 10:51
I have compiler errors. I've tried deleting all JediMod 1.2 code, leaving only the hilt selector code and adapting it to the base game by removing hilt2 entries and all that, but no luck.

BTW, I'm doing it on the JediMod 1.2 source.
If you want to remove all of the JediMod stuff except hilts anyway, why not just start with a clean basejk source, and then either port the hilt related things or write it from scratch?

By just removing varrious parts of JediMod you are sure to miss something that could cause future conflicts, or be the reason you have compiler errors right now.
I'm no coder, I'm trying to do it without proper knowledge of the game code, I have the code but I don't know how to port it to basejk properly, that's why I'm asking for help. Could you help me with this, please?

User avatar
fau
Staff
Posts: 422
Joined: 16 Aug 2015, 01:01
Location: Warsaw / Poland
Contact:

Re: JK2 Hilt selector code help

Post by fau » 19 Oct 2017, 08:14

Kyojinmaru wrote:
18 Oct 2017, 20:15
I'm no coder, I'm trying to do it without proper knowledge of the game code, I have the code but I don't know how to port it to basejk properly, that's why I'm asking for help. Could you help me with this, please?
It's like saying: "I'm not an engineer or a mechanic but I would like to make some modifications to my aeroplane. Could you help me with this, please?". No, learn to code (and start with something easier) or find someone to do it for you.

Kyojinmaru
Posts: 4
Joined: 16 Oct 2017, 17:22

Re: JK2 Hilt selector code help

Post by Kyojinmaru » 19 Oct 2017, 10:26

If someone could do it for me would be awesome, but it would be fine just if someone tell me which parts of the code are needed for this. Then I'll port it to basejk and do the needed modifications.

User avatar
ouned
Administrator
Posts: 588
Joined: 23 Feb 2015, 13:03
Location: Gliese581c

Re: JK2 Hilt selector code help

Post by ouned » 21 Oct 2017, 06:59

Learn to do it by yourself, it's not that hard. You will not regret it.

User avatar
Tr!Force
Posts: 429
Joined: 26 Feb 2015, 12:25
Location: Chile
Contact:

Re: JK2 Hilt selector code help

Post by Tr!Force » 31 Oct 2017, 18:28

Kyojinmaru wrote:
19 Oct 2017, 10:26
If someone could do it for me would be awesome, but it would be fine just if someone tell me which parts of the code are needed for this. Then I'll port it to basejk and do the needed modifications.
Just take a look in a sourcecode with hilt support (forcemod, jedimod, duelers, etc...) and copy/paste from the main files where the hilt code is:

GAME
  • g_local.h
  • g_active.c
  • g_main.c
  • w_saber.c
CGAME
  • cg_ents.c
  • cg_event.c
  • cg_main.c
  • cg_players.c
  • cg_weapons.c
UI
  • ui_local.h
  • ui_main.c
  • menudef.h
i did that when i was 15 yrs old with no code knowledge, just copy/paste'ing and testing. Remember to edit the ingame_player.menu file to add the hilt selector ingame.

:grinning:
Image
"The dark side? I've been there. Do your worst." - Kyle Katarn
  • In-Game Nick Name: Tr!Force
  • JK2 & JK3 Code-Mod Developer
  • Jedi Knight Plus Mod Project: Click Here
  • E-Mail: triforce@gznetwork.com

Post Reply
Created by Matti from StylesFactory.pl and Warlords of Draenor (modified by jk2.info)
Powered by phpBB® Forum Software © phpBB Limited
GZIP: On