Duke4.net Forums: EDuke32 2.0 and Polymer! - Duke4.net Forums

Jump to content

  • 213 Pages +
  • « First
  • 166
  • 167
  • 168
  • 169
  • 170
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

EDuke32 2.0 and Polymer!  "talk about the wonders of EDuke32 and the new renderer"

User is offline   Helixhorned 

  • EDuke32 Developer

#5000

View PostFox, on 15 December 2014 - 12:32 PM, said:

I don't fully understand how the translucency tables work, but doesn't the game holds different lookup tables for 33% and 66% alpha?

No, you have one table. For input color indices a and b representing colors A and B, the result of transluc[a][b] is a color index whose color is close to 0.33*A + 0.67*B. Now if you swap the foreground and background inputs, you get: transluc[b][a] = 0.33*B + 0.67*A. This swapping is just what the "reverse translucency bit", 512 for sprites, effects. So the ingenuity with Duke3D's table is that it packs two translucency levels into one table, but intuitively speaking, that's only possible because they're of the same kind.

Edit: an equivalent formulation is saying that, in matrix terms, the transposed table is accessed with the non-swapped indices: translucT[a][b]. So conceptually, there are two tables, but physically, there's only one.

View PostLeoD, on 15 December 2014 - 04:59 PM, said:

If that's addressed to me: no idea what you're talking about.

Nah, that was mainly addressed to TX. He will know.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5001

View PostHelixhorned, on 16 December 2014 - 02:15 AM, said:

No, you have one table. For input color indices a and b representing colors A and B, the result of transluc[a][b] is a color index whose color is close to 0.33*A + 0.67*B. Now if you swap the foreground and background inputs, you get: transluc[b][a] = 0.33*B + 0.67*A. This swapping is just what the "reverse translucency bit", 512 for sprites, effects. So the ingenuity with Duke3D's table is that it packs two translucency levels into one table, but intuitively speaking, that's only possible because they're of the same kind.

Edit: an equivalent formulation is saying that, in matrix terms, the transposed table is accessed with the non-swapped indices: translucT[a][b]. So conceptually, there are two tables, but physically, there's only one.

If I understand it, there is only one translucency table of 33%, and the game simply swap the background and foreground pixels to create the effect of a 66% table.

Rats, I would then need a way to replace the two default translucency levels.
0

User is offline   Micky C 

  • Honored Donor

#5002

The AMC TC uses both the alpha and additive blending types. Like Helix said, just have different tables and differentiate between them with the .blend function.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5003

Blend won't do the job. I need to replace all instance which the two translucency levels are used.
0

User is offline   sergey808a 

#5004

This bug occurs if the folder autoload there are other packs except duke3d_hrp.zip, for example - duke3d_music.zip.
eduke32_win64_20141213-4814
Also, not working ending movies after 2nd and 3rd bosses.

Posted Image

Attached File(s)



This post has been edited by sergey808a: 17 December 2014 - 12:35 AM

0

User is offline   LeoD 

  • Duke4.net topic/3513

#5005

View Postsergey808a, on 16 December 2014 - 11:24 PM, said:

This bug occurs if the folder autoload there are other packs except duke3d_hrp.zip, for example - duke3d_music.zip.
eduke32_win64_20141213-4814
Also, not working ending movies after 2nd and 3rd bosses.
Delete textures.cache, textures, and retry.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5006

It seems that "bright red" assigns the player with pal 22 instead 21.
1

User is offline   Hendricks266 

  • Weaponized Autism

  #5007

View PostFox, on 17 December 2014 - 05:16 PM, said:

It seems that "bright red" assigns the player with pal 22 instead 21.

Oops.
0

User is offline   Micky C 

  • Honored Donor

#5008

The new high res viewscreens are nice Posted Image There are some problems though.
1) The viewscreen seemed to change its size after the first use.
2) It stopped animating when I went to the menu and returned. Couldn't get it to animate again.

Btw where did all the options like "show level stats" go? I can't see it anywhere. I'm using r4814 btw.
0

User is offline   Hendricks266 

  • Weaponized Autism

  #5009

View PostMicky C, on 18 December 2014 - 04:24 AM, said:

Btw where did all the options like "show level stats" go? I can't see it anywhere. I'm using r4814 btw.

We culled the menus in preparation for Android. That one is in Display Setup --> On-Screen Displays.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5010

View PostMicky C, on 18 December 2014 - 04:24 AM, said:

1) The viewscreen seemed to change its size after the first use.

Spoiler

Probably the result of the tsprite x-yrepeat being truncated.
0

User is offline   Helixhorned 

  • EDuke32 Developer

#5011

View PostFox, on 16 December 2014 - 06:16 AM, said:

Blend won't do the job. I need to replace all instance which the two translucency levels are used.

For sprites, the following will do, assuming the attached PALETTE.DAT table is used.

gamevar tmp 0 0
gamevar cs 0 0

state setup_animatesprites
    getactor[THISACTOR].mdflags tmp
    orvar tmp 16
    setactor[THISACTOR].mdflags tmp
ends

onevent EVENT_EGS
    state setup_animatesprites
endevent

onevent EVENT_LOADACTOR
    state setup_animatesprites
endevent

// Assuming a PALETTE.DAT with e.g.:
//  blend 0: 50/50 alpha
//  blend 1: factor 1.0 additive
onevent EVENT_ANIMATESPRITES
    getactor[THISACTOR].cstat cs
    ifvarand cs 2 ifvarand cs 512
        setactor[THISACTOR].blend 1
    else
        setactor[THISACTOR].blend 0
endevent


Note how I set mdflags[].flags' bit 16 for both cases of sprite creation (premap and in-game spawn), unconditionally for all sprites.

Attached File(s)


0

User is offline   Helixhorned 

  • EDuke32 Developer

#5012

View PostMicky C, on 18 December 2014 - 04:24 AM, said:

1) The viewscreen seemed to change its size after the first use.
2) It stopped animating when I went to the menu and returned. Couldn't get it to animate again.

I can't reproduce any of these problems. For the second one, the rendered view on the security screen stops panning for a second or so, but resumes then. What are your renderer settings (as shown with DNCOORDS entered twice)?
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5013

View PostHelixhorned, on 20 December 2014 - 05:12 AM, said:

For sprites, the following will do, assuming the attached PALETTE.DAT table is used.

(...)

Note how I set mdflags[].flags' bit 16 for both cases of sprite creation (premap and in-game spawn), unconditionally for all sprites.

I need it for masked walls too.

You changed the default table to 50%? That will be very usefull. But then I need a way to change the hard-coded translucency values in OpenGL modes.

This post has been edited by Fox: 20 December 2014 - 10:33 AM

0

User is offline   Micky C 

  • Honored Donor

#5014

View PostHelixhorned, on 20 December 2014 - 05:42 AM, said:

I can't reproduce any of these problems. For the second one, the rendered view on the security screen stops panning for a second or so, but resumes then. What are your renderer settings (as shown with DNCOORDS entered twice)?


Well that hardly gave any information at all.

Rendermode 0, resolution 1024x768, widescreen on.
0

User is offline   Mblackwell 

  • Evil Overlord

#5015

Wait what? 1024x768 is 4:3, not widescreen...
0

User is offline   Helixhorned 

  • EDuke32 Developer

#5016

View PostMicky C, on 18 December 2014 - 04:24 AM, said:

1) The viewscreen seemed to change its size after the first use.
2) It stopped animating when I went to the menu and returned. Couldn't get it to animate again.

OK, 2) is now fixed. A more precise description of the bug is that the animation on the viewscreen was suspended for as long as you had the menu open. As far as 1) is concened, I can't get the viewscreen back to its normal tile with new revisions. Whenever I exceed the tile-update threshold distance (8192 Build units), the last rendered scene remains on the tile, in contrast to resetting to VIEWSCREEN, as in Duke3D. This is a probably unintended side effect of r4445.

View PostFox, on 20 December 2014 - 10:27 AM, said:

I need it for masked walls too.

Assuming the translucency bits of every wall never change, just loop over all of them at map entry and set wall[].blend accordingly.

Quote

You changed the default table to 50%? That will be very usefull. But then I need a way to change the hard-coded translucency values in OpenGL modes.

Well, that has been discussed earlier, like from here on.
1

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5017

View PostHelixhorned, on 21 December 2014 - 08:35 AM, said:

Assuming the translucency bits of every wall never change, just loop over all of them at map entry and set wall[].blend accordingly.

That structure is not avaiable.
0

User is offline   Helixhorned 

  • EDuke32 Developer

#5018

Oops, right, the .blend wall member is present in Lunatic builds only.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5019

I may ask, why is that?
0

User is offline   Helixhorned 

  • EDuke32 Developer

#5020

For the sprite structure type, there used to be an unused "filler" member that was taken over for the purpose of "blend". The V7 wall structure type is already tightly packed and there are no unused fields. In the Lunatic build, the internal map format is decoupled from the on-disk one, so that members can be added arbitrarily.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5021

It's not like I have deep knowledge about the map format, but I don't understand why adding new sector or wall structures would not be viable in the same way as spriteext structures and per-sector or per-wall gamearrays.
0

User is offline   Micky C 

  • Honored Donor

#5022

Is it normal for sprites and the player to move radially inward when in a rotating sector of which the point of rotation is outside the sector?
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5023

It's expected for the position of a sprite to change gradually in relation to the pivot point due to some imprecision in the calculation.
0

User is offline   Micky C 

  • Honored Donor

#5024

Damn, so there's no way around it? Even with con code?
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5025

With CON code there is. If I am not wrong a statnum was created for that?
0

User is offline   Hendricks266 

  • Weaponized Autism

  #5026

htflags & 131072

With this flag you may never move the actor from its starting point.
1

User is offline   Helixhorned 

  • EDuke32 Developer

#5027

View PostFox, on 23 December 2014 - 06:57 AM, said:

It's not like I have deep knowledge about the map format, but I don't understand why adding new sector or wall structures would not be viable in the same way as spriteext structures and per-sector or per-wall gamearrays.

Ultimately because it means the existence of a new on-disk map format which would have to be maintained, together with conversion code from at least the preceding version. So, each time a field were added to sprite/wall/sprite in the non-Lua setting, we'd bump the map format to V10, V11, V12, ... not cool. The situation is different for structures like spriteext[] because they're not exposed in this way. Still, we need to bump BYTEVERSION (breaking older savegames) whenever we change these.
0

User is offline   Helixhorned 

  • EDuke32 Developer

#5028

View PostHendricks266, on 24 December 2014 - 01:57 AM, said:

htflags & 131072

With this flag you may never move the actor from its starting point.

The flag is ineffective when set during the game for an actor, though. The proper way is to mark an actor tile potentially "rotation-fixed" by adding bit 4 to its actortype. At map load time, sprites of that tile number contained in SE0, SE6 or SE14 sectors will be set up for prevention of roundoff error accumulation during the game. Sprites of the following statnums will be set up this way by default: DEFAULT, STANDABLE, FX, FALLER, LIGHT.

Note that in the wiki's htflags documentation, some flags have no CON labels. These flags are not really supposed to be used directly.
2

User is offline   Jblade 

#5029

The save command seems to be crashing the game on the latest snapshots. Wish I could give more info but the game just hangs when the command is used. Here's the code:
ifvarvare SAVEGAME THISACTOR
{
readgamevar SAVEGAME
ifvare SAVEGAME 0 killit
save 9
setvar SAVEGAME 0
savegamevar SAVEGAME
killit
}

ifvare AUTOSAVE_ENABLED YES
ifvare SAVEGAME 0
{
ifvarn HITAGSAVED 0
	{
	checkactivatormotion HITAGSAVED
	ifvare RETURN 1
		{
		userquote 243
		setvarvar SAVEGAME THISACTOR
		}
	}
else
	ifpdistl 1024
	{
	userquote 243
	setvarvar SAVEGAME THISACTOR
	savegamevar SAVEGAME
	}
}

It's convoluted to fix the issue where the game would autosave immediately again upon loading the save back up.

This post has been edited by Jblade: 24 December 2014 - 02:27 AM

0

Share this topic:


  • 213 Pages +
  • « First
  • 166
  • 167
  • 168
  • 169
  • 170
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options