View unanswered posts | View active topics It is currently Fri Dec 27, 2024 8:52 am



Reply to topic  [ 10 posts ] 
 Device Viewer, or reload device .ini 
Author Message
User avatar

Joined: Fri Apr 04, 2008 12:06 am
Posts: 196
Location: In front of keyboard, staring at monitor. (WA, Oz)
Reply with quote
Post Device Viewer, or reload device .ini
There is a 'button' in the pie menu in the Actor Viewer that says 'Reload Code' or some ♥♥♥♥. I want to reload the code for a device in the same way so that I can get offsets right without booting the game every 20 seconds.

I seem to remember someone saying you can reload a .rte through the console. How so?


Fri Dec 31, 2010 12:01 pm
Profile
User avatar

Joined: Tue Dec 12, 2006 3:10 pm
Posts: 495
Location: Uncertain quantum state
Reply with quote
Post Re: Device Viewer, or reload device .ini
Can't.

Make a CopyOf = Soldier Light, rename it and give it the device in question.


Fri Dec 31, 2010 3:28 pm
Profile
DRL Developer
DRL Developer

Joined: Fri May 15, 2009 10:29 am
Posts: 4107
Location: Russia
Reply with quote
Post Re: Device Viewer, or reload device .ini
if you define a copy of a coalition in the index, I'm pretty sure you can.


Fri Dec 31, 2010 5:45 pm
Profile
User avatar

Joined: Fri Apr 04, 2008 12:06 am
Posts: 196
Location: In front of keyboard, staring at monitor. (WA, Oz)
Reply with quote
Post Re: Device Viewer, or reload device .ini
So technically I can make an actor with the null image and make it 'hold' this device? Would that work?

EDIT: Tried it, successfully made an invisible actor with a head, torso and FG arm and holding the device. However, it doesn't reload the device's code when it reloads the actor's code, which is not surprising.

Surely there is a Lua function to do it?

EDIT2: I searched in the offline Lua docs and found these. What do they do?
Code:
PresetMan:LoadDataModule
PresetMan:ReloadAllScripts


Sat Jan 01, 2011 7:07 am
Profile
User avatar

Joined: Tue Nov 06, 2007 6:58 am
Posts: 2054
Reply with quote
Post Re: Device Viewer, or reload device .ini
Latter only reloads Lua, former may or may not crash/work.


Sat Jan 01, 2011 9:14 am
Profile
User avatar

Joined: Fri Apr 04, 2008 12:06 am
Posts: 196
Location: In front of keyboard, staring at monitor. (WA, Oz)
Reply with quote
Post Re: Device Viewer, or reload device .ini
Found it. Search helped, but I had to be a little obscure.

If you put 'IncludeFile = Path.rte/MyDevice.ini' into an actor, everytime you reload the actor it reloads the device you want.

Found HERE, solved by Grif NUMGUN.


Last edited by Yoman987 on Sat Jan 01, 2011 3:23 pm, edited 1 time in total.



Sat Jan 01, 2011 9:14 am
Profile
User avatar

Joined: Tue Dec 12, 2006 3:10 pm
Posts: 495
Location: Uncertain quantum state
Reply with quote
Post Re: Device Viewer, or reload device .ini
Seriously...?

findude wrote:
Can't.

Make a CopyOf = Soldier Light, rename it and give it the device in question.


Sat Jan 01, 2011 3:03 pm
Profile
User avatar

Joined: Fri Apr 04, 2008 12:06 am
Posts: 196
Location: In front of keyboard, staring at monitor. (WA, Oz)
Reply with quote
Post Re: Device Viewer, or reload device .ini
You missed an important step which numgun caught (not Grif, my mistake. Sorry :-( )

findude wrote:
Make a CopyOf = Soldier Light, rename it and give it the device in question.
This implied to me that all I had to do was 'AddInventoryItem = ', which I quickly found didn't work.

numgun wrote:
IncludeFile ... in the beginning of the actor's .ini file. This would allow instantly to reload the whole thing through the actor viewer.


Sat Jan 01, 2011 3:21 pm
Profile
REAL AMERICAN HERO
User avatar

Joined: Sat Jan 27, 2007 10:25 pm
Posts: 5655
Reply with quote
Post Re: Device Viewer, or reload device .ini
if you're reloading a device, then what you should do is put the copyof actor snippet at the end of the main device code.

any includes will be reloaded automatically (though why anyone would split ammo/effects/weapons is beyond me) and there's no need to fiddle with another .ini


Sun Jan 02, 2011 2:58 am
Profile
User avatar

Joined: Fri Apr 04, 2008 12:06 am
Posts: 196
Location: In front of keyboard, staring at monitor. (WA, Oz)
Reply with quote
Post Re: Device Viewer, or reload device .ini
All I've done is make another index that contains all my Devices , rounds and magazines, then put the IncludeFile of that ini into the invisible actor I made. works like a charm and even helps with the JointOffsets of the firearm.

Case closed, and thanks for all the fish.


Sun Jan 02, 2011 5:43 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 10 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.051s | 14 Queries | GZIP : Off ]