Author Message

Driftmonkey06370

fr
Posts: 24
http://https://discord.gg/3tqqP8V
Location: France Cannes
Occupation: BrapTeam
Age: 23
V$:
#481   2018-11-13 10:56          
Nice :D

TEKKE078

ar
Posts: 16

Location: Argentina , a province that is between rivers.
Occupation: Play some drumz and crash this shet.
Age: 15
V$: Crysis
#482   2018-11-13 16:34          
Dude, you are AWESOME! :bow:


> I still drive a bike, FOCKยก

gorgoil

pt
Posts: 216

Location: Portugal , "Oh Cristiano Ronaldo" Island
Occupation: Making SLRR crash since 2005
Age: 21
V$:
#483   2018-11-13 20:28          
man that's awesome :D with that I can finally make one of my dreams in SLRR wheelie competitions :P

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#484   2018-11-15 23:01          
# amilmand : Almost there but as you found out (judging by the static cast to int) this function returns a float soo its no good for you the full call would be to get the address of the value and decode it as an int:
RawEdit.getI(the_car.getIndexedAddr(Chassis.IndexedData_Flags));
The clues would have been: LINK
And the comments in the chassis.java:
public static final int IndexedData_GearNumber = 0x20FC-0x304;
   //this is an int getIndexedData will return
     strange but the RawEdit.getI with getIndexedAddr will suffice
public static final int IndexedData_Flags = 0x70;//int
Thanks, I think that was what I needed. It's returning really weird values, though. It doesn't seem to be correctly changing when the turn signals turn on.

I dont know what your goal is with the flags but I found that access to this value is of a readonly manner as most of the flags the game updates each frame and invalidates any changes you try to force (though you can get interesting state indicators so to say, (whether the blinker is on, is the car running and some others)
The idea here is to program something like American turn signals, where a single red light is shared for the city, brake, and turn signal functions, and the light turns off entirely when the turn signals are on at the same time as the brake or city lights. (Reference if you have no idea what I'm talking about.)

So basically, the pseudocode should go like this:
if flags & 1
 > if flags & 16
 > > turn off brake light
 > otherwise
 > > turn on brake light
if flags & 1
 > if flags & 16
 > > turn off city light
 > otherwise
 > turn on city light
if !(flags & 1) && !(flags & 4)
 > if flags & 16
 > > turn on brake light
But I can't quite get the flags to work.

By the way, is there a convenient way to display a glow object (or other render) aligned to a part, through Java, besides making it a whole separate part that can then be manipulated? I haven't figured this out yet. I have figured out how to display a render as a child of the part, but it always shows up at the center of the map. I can in fact make attachment parts for all of the glow objects, and then make them disappear under the map by moving their slot position, but I'd prefer not to do this if there is a more light-weight alternative (in terms of part count as well as not slowing down the game).

This post was edited by RedCarDriver (2018-11-15 23:21, 65 days ago)

Bigg Boss93

it
Posts: 3981
http://rdbl.co/1Hmg5XL
Location: Italy - Sardegna
Occupation: Overhyping machine
Age: 25
V$: More than you can afford, pal.
#485   2018-11-16 00:17          
# amilmand :

Vibration when? :))
Diegorborges about my Valo fix: "Now all of you must have your slrr folder like this: C:/BIGBOSSisMYlordANDiamHISbitch/SLRR LOL" :O




amilmand

00
Posts: 250

Location: ---
Occupation:
Age:
V$:
#486   2018-11-16 09:23          
RedCarDriver:
It's returning really weird values
These are not the flags set in the cfgs those are lost upon loading of the cfg (or rather they are not loaded to memory so its impossible to manipulate them directly as of yet)

RedCarDriver:
American turn signals
I dont see a clear (reasonable) way to do this with the current setup.

RedCarDriver:
glow object (or other render) aligned to a part
I only know of the way you described with making parts and slots a sophistication of the method would be to use the SetRenderType function of the Part class as to circumvent the actual attachment and detachment, or the slot movement and avoid suffering the flying glows upon flipping the car, also speed up the process somewhat.
The bad solution would be active monitoring and aligning the matrices but that is a horrendous idea.

Also there are some functions in the RenderRef class which you can try (I managed to change the color of the glow of a given (head)light but not of the projected texture) these are:
public native void setLight( int diffuse, int ambient, int specular );
public native void setFlare( ResourceRef glowtexture, int glowColor, float glowMinSize, float glowMaxSize, int flareCount, int rayCount );
So if you had detachable indicator and other lights(bulbs maybe) you probably would be able to make them do what you want but its getting complicated :/ (need to check if the parent-chassis has ignition and what not)

Bigg Boss93:
Vibration
:)

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#487   2018-11-16 09:43          
Alright, thanks. I was afraid it was going to be impossible to read the car's flags well enough to tell whether or not the headlights (or indicators, etc) are on. Thanks for the help, in any case.

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#488   2018-11-21 04:11          
I'm experiencing reproducible crashing if the cursor is on a menu button while the ReShade effects are loading. Is there a way to fix this?

This post was edited by RedCarDriver (2018-11-21 06:15, 59 days ago)

amilmand

00
Posts: 250

Location: ---
Occupation:
Age:
V$:
#489   2018-11-21 08:21          
Maybe, crash it with this: LINK
And tell me the faulting module(it should be d3d9.dll if its the slrr_gi.exe we may manage) and offset (if windows doesnt tell you off the bat in the error message try: LINK)

RedCarDriver:
I was afraid it was going to be impossible to read the car's flags well enough to tell whether or not the headlights (or indicators, etc) are on
I missed this somehow well this is not entirely true you can check for whether the car thinks its night time (this is the same flag that gets checked by the lights) and check for the rpm if its >0 if so the lights are most probably on, there is also a flag for the indicators (but of course for that to actually get flipped the cruse mode needs to be on) and all this is read only as the game overwrites changes.
Code would look along the lines:
int flags = RawEdit.getI(GameLogic.player.car.chassis.getIndexedAddr(Chassis.IndexedData_Flags));
float rpm = GameLogic.player.car.chassis.getIndexedData(Chassis.IndexedData_RPM);
if((flags & 0x8) != 0 && rpm > 1)
{
  //lights are most probably on
}
if((flags & 0x10000) != 0)
{
  //left indicator blinking (mind you this is true for the whole time its in the blinking state not just when its actually lit)
}
if((flags & 0x20000) != 0)
{
  /right indicator
}

But really you dont even need this, you can check for the steering with
getIndexedData(Chassis.IndexedData_CurrentSteering1) (the game does the same for the built in method)
for the indicators, (even enforce them when cruise mode is inactive).
And the current game time also can be acquired (the game checks for (currentTime < 75600 && currentTime >= 21600)) along with the rpm.
(and again the whole shabang for brake lights, IndexedData_BreakStrength, or clucth lights (if that is a thing) IndexedData_ClutchStrength ooor nitro lights IndexedData_NitroStrength and alot others)

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#490   2018-11-21 09:31          
# amilmand : Maybe, crash it with this: LINK
And tell me the faulting module(it should be d3d9.dll if its the slrr_gi.exe we may manage) and offset (if windows doesnt tell you off the bat in the error message try: LINK)

Alright, I'll try that.

I missed this somehow well this is not entirely true you can check for whether the car thinks its night time (this is the same flag that gets checked by the lights) and check for the rpm if its >0 if so the lights are most probably on, there is also a flag for the indicators (but of course for that to actually get flipped the cruse mode needs to be on) and all this is read only as the game overwrites changes.
Code would look along the lines:
int flags = RawEdit.getI(GameLogic.player.car.chassis.getIndexedAddr(Chassis.IndexedData_Flags));
float rpm = GameLogic.player.car.chassis.getIndexedData(Chassis.IndexedData_RPM);
if((flags & 0x8) != 0 && rpm > 1)
{
  //lights are most probably on
}
if((flags & 0x10000) != 0)
{
  //left indicator blinking (mind you this is true for the whole time its in the blinking state not just when its actually lit)
}
if((flags & 0x20000) != 0)
{
  /right indicator
}

That's actually exactly what I wanted, thanks! I'll try that out. And yes, I did want it to happen only when cruise mode is on - I wanted the custom turn signals to come on at exactly the same times as existing SLRR turn signals, except with the changes necessary to make them behave like American signals.

This post was edited by RedCarDriver (2018-11-21 09:47, 59 days ago)

theblockishot

00
Posts: 86

Location: ---
Occupation:
Age:
V$:
#491   2018-11-24 09:49          
Is it possible to run Exhaustive without reshade?

Boop Boop BAP

amilmand

00
Posts: 250

Location: ---
Occupation:
Age:
V$:
#492   2018-11-24 16:55          
Shouldn't rely on it that heavily try and run it without the d3d9.dll (better to rename it though maybe sometime later youll need it, (or even better to just turn off some performance heavy effects GeneralShaderOverwrite ShadowShaderOverWrite and the like)).

theblockishot

00
Posts: 86

Location: ---
Occupation:
Age:
V$:
#493   2018-11-26 06:58          
Thanks man. I don't use reshade because my laptop is not good enough. I get too low fps even with all the features disabled

Boop Boop BAP

gorgoil

pt
Posts: 216

Location: Portugal , "Oh Cristiano Ronaldo" Island
Occupation: Making SLRR crash since 2005
Age: 21
V$:
#494   2018-11-26 20:03          
Is there any possible way to set part mass/weight by java? because I had an idea and I need to set weight by java to make it work.
Thanks in advance

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#495   2018-12-01 22:37          
Hey, sorry to bother you again, but do you have some idea what all of the variables in WheelRef.SetArm() and WheelRef.SetHub() do? The vast number of variables in there to test is intimidating. I figure "len" in there is probably length, but otherwise I have no idea.

adnan54

br
Posts: 279

Location: Brazil
Occupation: student
Age: 19
V$:
#496   2018-12-02 00:36          
Is it possible to change the engine inertia according to the game FPS? Because at low FPS the engines seems to lost all the power and torque, and at high FPS the engines become overpowered and it is kinda frustrating..
Something wrong is not right.

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#497   2018-12-02 02:04          
# adnan54 : Is it possible to change the engine inertia according to the game FPS? Because at low FPS the engines seems to lost all the power and torque, and at high FPS the engines become overpowered and it is kinda frustrating..
Ohhhh! This is why people tell me my engines are slow in their installation! :O

holeecrab

id
Posts: 878

Location: Indonesia
Occupation: Delusional Artist
Age: 21
V$: vipka
#498   2018-12-02 11:14          
that's the same issue as a lot of game had these days, like Fallout 76 for the example.

would be hard imo. But not impossible since amilmand's is here ;D

svander

ar
Posts: 230

Location: Argentina Cordoba, Justiniano Posse
Occupation: Modding SLRR
Age: 22
V$:
#499   2018-12-02 18:41          
Its not about the engines. At high fps the entire game is faster. Ive got a 144hz display and had to limit @ 70fps just because at 144 game goes too fast for everything, engine accel, braking, camera movement, etc

eduarbio15

pt
Posts: 1

Location: Portugal
Occupation: converting people into loving e36s
Age: 19
V$:
#500   2018-12-21 23:18          
Hello, i'm new into this, sorry if im just asking for something very common but i cant find an answer for my problem, so here it goes.
I'm trying to add cars via moving the _data and .rpk file into the racers folder but they wont ever show up in game, how can i solve this?

RedCarDriver

us
Posts: 1199

Location: United States Arizona
Occupation: Programmer with not enough spare time
Age: 25
V$: 73560
#501   2018-12-22 01:34          
Are you looking in the car dealer? Because the car dealer doesn't refresh for a couple of in-game days. Most of the time, you have to buy new cars through MWM's vehicle catalog.

IceD

vi
Posts: 1280

Location: Virgin Islands (u.s.) Graveyard
Occupation: RIP
Age:
V$:
#502   2018-12-26 17:57          
# amilmand : I was kind of intrigued so I went ahead and made a DynamicRim whose size (width and radius) and appearance can be "tuned" furthermore I added a DynamicTyre to this DynamicRim with "tune-able" mesh, size and other params (the wheel params that can passed to the SetupTyre(..) function) the result is interesting :) , I also maintained the paintability of the rims with a trick (I made a RenderRef with a texture array consisting of 10 of the same texture which is handily the paintable one, this ofcourse makes all textures the rim uses paintable even the reflection but reshade overwrites that so no harm done (well at least when reshade is active))
(For this(the dynamic mesh selection) to work I had to make a long list of valid mesh TypeIDs and renderRef TypeIDs for tyres and rims so the solution is not hmm portable but it can be done (and if we'll find a way to get the MeshID of a given renderRef in script it can be made portable aswell, nevertheless the method can easily be used for a single modded rim)

I know it looks silly but at least now we CAN make it look dumb without much hassle.


I added this to the "Ever refreshing patchlink" for SlrrExhaustive
Sorry for bumping, but is it possible to have this feature as a standalone mod? :D