September 7, 20214 yr Author 10 minutes ago, diesieben07 said: Your offsets are probably wrong. Or your texture is not actually 265 pixels but 256 pixels in size (I would hope it is 256 pixels). As I said earlier, I'm using vanilla textures as a placeholder atm. I looked around the values carefully and here's how it's rendering the colors: 1. It renders in the empty boss bar background by getting the ordinal of the color from the enum, multiplying it by 5 and then multiplying it by 2 which in my case results in 40 aka the texture starts at the 40th pixel. 2. It renders in the filled texture by doing the exact same calculation but adding 5. After that it sets it's width to the progress multiplied by 183 My best guess is that the progress isn't updating or something. Edit: Well, the progress really isn't updating but I doubt that's what's causing the issue. Edited September 7, 20214 yr by uSkizzik
September 7, 20214 yr Author 1 minute ago, diesieben07 said: Then the texture is 256x256, not 265. My bad lol
September 7, 20214 yr Author 5 minutes ago, diesieben07 said: Then the texture is 256x256, not 265. Well, that was the issue. Now, what I need is to get the progress going because so far the bar doesn't seem to be updating. Edit: I just pushed the progress to my repo, here are the links: Package containing boss events, Packet, RenderGameOverlay Edited September 7, 20214 yr by uSkizzik
September 7, 20214 yr Author Well, it's working... I don't know how and why it didn't work previously but it's working. Thank you so much @diesieben07 for putting up with my stupidity this whole time and helping me figure this out. EDIT: Oh we ain't done yet! I will most likely need help on the moving down too! Edited September 7, 20214 yr by uSkizzik
September 7, 20214 yr Author 1 minute ago, diesieben07 said: Show your current code. 47 minutes ago, uSkizzik said: Edit: I just pushed the progress to my repo, here are the links: Package containing boss events, Packet, RenderGameOverlay
September 7, 20214 yr Author 16 minutes ago, diesieben07 said: If you want your boss bars to cooperate with the vanilla rendering, you have to put them into the vanilla events map, not make your own. You can then use RenderGameOverlayEvent.BossInfo to alter the rendering of this custom bar. This is what I told you from the very start. Alright, I made a customColor field in my LerpingBossEvent and extended the original. Now how do I change the rendering? I need to change the drawBar but for that I need the k and j values which are set / changed in the for loop.
September 7, 20214 yr Author Yea I just cancelled the event and rewrote the bit of the code that was causing me an issue. Probably not the best solution but everything works perfectly.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.