# Custom component. Doesn't show on basic tap

**URL:** https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141
**Category:** Uncategorized
**Created:** [April 11, 2026, 8:19pm UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141 "2026-04-11T20:19:16Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![BlueIcaro](https://forum.castle-engine.io/letter_avatar_proxy/v4/letter/b/eada6e/32.png) [@BlueIcaro](https://forum.castle-engine.io/u/BlueIcaro)
#### Post date: [April 11, 2026, 8:19pm UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141/1 "2026-04-11T20:19:16Z")

</div>

Hello, I making a Custom Component, but the properties doesnt show in basic tap.

I got this:

public  
const  
DefaultDistancia = 50;  
property Direccion: TVector3 read Fdireccion write Setdireccion;  
property Velocidad: TVector3 read Fvelocidad write Setvelocidad;  
published  
property Distancia: single read FDistancia write SetDistancia default  
DefaultDistancia;  
property DireccionPersistent: TCastleVector3Persistent read FDireccionPersistent;  
property VelocidadPersistent: TCastleVector3Persistent read FVelocidadPersistent;

if ArrayContainsString(PropertyName, [‘VelocidadPersistent,DireccionPersistent’]) then  
begin  
Result := [psBasic];  
end  
else  
begin  
Result := inherited PropertySections(PropertyName);  
// Result := [psBasic];  
end;

If I “force” resutl to psbasic the propierties are show in tap. So the problem is that are not found in the array. But I don’t know why

/BlueIcaro

---

<div class="post-metadata">

### Author: ![michalis](https://forum.castle-engine.io/user_avatar/forum.castle-engine.io/michalis/32/3_2.png) [@michalis](https://forum.castle-engine.io/u/michalis)
#### Post date: [April 11, 2026, 9:08pm UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141/2 "2026-04-11T21:08:12Z")

</div>

Hm, I don’t see any obvious error in the code you show. Checking `if ArrayContainsString(PropertyName, [...` follows the pattern we use throughout CGE , and our properties show in “Basic” tab OK.

You need to show a bigger piece of code (preferably a complete testcase, i.e. code that we can compile and test) to allow us to debug it.

Note: You can also debug more on your side

- e.g. from Lazarus IDE (CGE editor is a regular LCL application, you can set a breakpoint e.g. the beginning of your `PropertySections` method).
- adding `WritelnLog`. E.g.

```delphi
WritelnLog('Checking property %s, which seems to be in array? %s', [
  PropertyName,
  BoolToStr(ArrayContainsString(PropertyName, [‘VelocidadPersistent,DireccionPersistent’]), true)
]);

```

The editor makes a regular log file, you can find it following docs [Logging | Manual | Castle Game Engine](https://castle-engine.io/log) (the application name of editor is `castle-editor`). So if you add above `WritelnLog` inside your `PropertySections`, make a test, and later look at log → you should see something that helps 🙂

---

<div class="post-metadata">

### Author: ![BlueIcaro](https://forum.castle-engine.io/letter_avatar_proxy/v4/letter/b/eada6e/32.png) [@BlueIcaro](https://forum.castle-engine.io/u/BlueIcaro)
#### Post date: [April 12, 2026, 8:39am UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141/3 "2026-04-12T08:39:13Z")

</div>

Hello, here is the complete project.

> **[GhostAndGoblins\_CGE-/Capitulo 8 at main · Blueicaro/GhostAndGoblins\_CGE-](https://github.com/Blueicaro/GhostAndGoblins_CGE-/tree/main/Capitulo%208)**
>
> Contribute to Blueicaro/GhostAndGoblins\_CGE- development by creating an account on GitHub.

Thanks

/BlueIcaro

---

<div class="post-metadata">

### Author: ![michalis](https://forum.castle-engine.io/user_avatar/forum.castle-engine.io/michalis/32/3_2.png) [@michalis](https://forum.castle-engine.io/u/michalis)
#### Post date: [April 12, 2026, 10:05pm UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141/4 "2026-04-12T22:05:29Z")

</div>

Thank you!

Looking at GitHub code listing, with proper syntax highlighting (colored Pascal string), I can see the issue at [GhostAndGoblins\_CGE-/Capitulo 8/code/enemigos/gamezombiesbehavior.pas at c4489ea1c33b3b6f9561ac1190e50536592b180d · Blueicaro/GhostAndGoblins\_CGE- · GitHub](https://github.com/Blueicaro/GhostAndGoblins_CGE-/blob/c4489ea1c33b3b6f9561ac1190e50536592b180d/Capitulo%208/code/enemigos/gamezombiesbehavior.pas#L281) (which was also in your post above, I just didn’t see it):

You placed the comma inside a string in the condition:

```delphi
if ArrayContainsString(PropertyName, [‘VelocidadPersistent,DireccionPersistent’]) then

```

That is, you’re _not_ comparing `PropertyName` with 2 possible strings, one `VelocidadPersistent`, other `DireccionPersistent`. You are comparing it with 1 string (containing a comma inside, so it will never match a Pascal identifier) `VelocidadPersistent,DireccionPersistent`.

Simply adding apostrophes should make it valid:

```delphi
if ArrayContainsString(PropertyName, [‘VelocidadPersistent','DireccionPersistent’]) then

```

Please note that in the end, I didn’t test above solution – I’m writing this basing on looking at the code. If some problem in this case remains, please let me know.

---

<div class="post-metadata">

### Author: ![BlueIcaro](https://forum.castle-engine.io/letter_avatar_proxy/v4/letter/b/eada6e/32.png) [@BlueIcaro](https://forum.castle-engine.io/u/BlueIcaro)
#### Post date: [April 13, 2026, 7:24am UTC](https://forum.castle-engine.io/t/custom-component-doesnt-show-on-basic-tap/2141/5 "2026-04-13T07:24:13Z")

</div>

Hello, Thank you!

/BlueIcaro

P.D. ups! 😅 Note to self: Sleep more and program less at night
