Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 09/05/24 in all areas

  1. Anders Melander

    Delphi Documentation website issues

    🤦‍♂️ If only there was some way to communicate stuff like that to their users...
  2. We have released updates of our products (September 3, 2024). There are lots of bug fixes and minor improvements. Pascal Analyser 9.12.11 Static code analyzer All features are explained in the online documentation at https://peganza.com/PALHelp/index.html Pascal Expert 9.12.11 Plug-in for RAD Studio, subset of Pascal Analyzer Browse the online documentation here https://peganza.com/PEXHelp/index.html Pascal Browser 3.5.29 Creates documentation for your source code Browse the online documentation here https://peganza.com/PABHelp/index.html Go to https://peganza.com to learn more.
  3. João Antônio Duarte

    VSoft.UUIDv7 - a Delphi implementation of UUIDv7 (RFC 9562)

    Interesting, I also made my own implementation of GUID V7 a while back. Your implementation seems to be more optimized than mine. function NewGuidV7: TGUID; var LBytes: array[0..15] of Byte; LUnixMSec: Int64; I: Integer; begin for I := 0 to 15 do LBytes[I] := Random($FF); LUnixMSec := DateTimeToMilliseconds(TTimeZone.Local.ToUniversalTime(Now)) - Int64(UnixDateDelta + DateDelta) * MSecsPerDay; LBytes[0] := (LUnixMSec shr 40) and $FF; LBytes[1] := (LUnixMSec shr 32) and $FF; LBytes[2] := (LUnixMSec shr 24) and $FF; LBytes[3] := (LUnixMSec shr 16) and $FF; LBytes[4] := (LUnixMSec shr 8) and $FF; LBytes[5] := LUnixMSec and $FF; LBytes[6] := (LBytes[6] and $0F) or $70; LBytes[8] := (LBytes[8] and $3F) or $80; Result := TGuid.Create(LBytes, 0, True); end;
  4. Hello, I think the problem is in the use of the variable "i" inside the async method. You have to make the variable "i" enter the procedure as a parameter of the procedure itself! Something like: for var i := Low(arr_id) to High(arr_id) do begin Parallel.Async( procedure (const task: IOmniTask) begin DOPING(task,i); end); end; procedure DOPING(const task: IOmniTask;i:integer) var PingResult: Boolean; rec_id: LongWord; rec_ip: string; begin // background thread rec_id := arr_id[i]; rec_ip := arr_ip[i]; // PingResult := PingHost(rec_ip); // in the main thread task.Invoke( procedure begin // some actions with ping results based on host ID mmoLog.Lines.Add(Format('rec_id=%d, rec_ip=%s', [rec_id, rec_ip])); end); end; This I think should solve it (I can't check now), however it can also be done in many other ways.
  5. Michalis Kamburelis

    Castle Game Engine 7.0-alpha.3 release

    Castle Game Engine is a free and open-source game engine. Our strong features are: comfortable visual editor, many graphic effects (shader effects, mirrors, bump mapping, PBR...), support for many model formats (glTF, X3D, MD3, Spine JSON...), being cross-platform (desktop, mobile, console) and of course using fast, clean Object Pascal for both the engine development and your games! Details about the Delphi versions and platforms support are here. We are proud to present a big new release of Castle Game Engine, with lots of new features, improvements and fixes. The new engine version is available for download now. The highlights of the release are below. For more details, see the full release notes. The number of this release, “7.0-alpha.3”, is a signal that we’re on our road to the big 7.0 release (see the roadmap and plans and timeline). This release is dedicated to the late Eugene Loza. I miss you, dear friend. The most important highlights of this release are: Physics. New components for colliders and rigid bodies, ability to run physics simulation in the editor, joints, layers, forces. Many rendering improvements: Correct and automatic blending, both batching and occlusion culling easier to use and more powerful, fully modern rendering on new GPUs, better support for ancient systems with old GPUs. Also OpenGLES (Android, iOS, Nintendo Switch) rendering supports now almost all desktop rendering features: shadow volumes, shadow maps, 3D textures, occlusion query, anisotropic filtering, meshes with 32-bit indexes. Shadows using shadow volumes are trivial to activate. Work is under way to expose shadow maps through a trivial property as well. Visual Studio Code integration. Our own VS Code “Castle Game Engine” extension with code completion and syntax highlighting for all Pascal code and easy building / running / debugging of Castle Game Engine projects. Delphi integration improvements: TCastleControl available for VCL and FMX applications, Delphi packages with IDE support, Delphi Linux support and more. Support for Tiled maps with a new component that is comfortable to use and efficient to render. User Interface improvements: better default font, UI batching, image regions and 9-slices borders visually configurable, mask component. Many editor UX improvements: modern color picker, unified tools to edit UI and transformations, wireframe view, “Change Class” menu action, Sketchfab Importer, finding components by name, multi-selection. Improvements to views (formerly states): better API, automatic initialization of the published fields, opening the project greets you with UX to manage views. Mobile improvements: lots of Android services improvements, Castle Model Viewer Mobile and more Android applications released on Google Play, lots of general Android and iOS fixes and improvements to make porting your games to mobile trivial, safe borders. Loading and saving: cache, MD3 improvements, X3D 4.0 improvements, custom model formats registration, STL saving. Inspector (press F8 / 3 fingers in a debug build of any project) improvements: tweaking boolean properties at run-time, hot-reloading at run-time to iterate on your graphics. Float-based images (e.g. for precise terrains) full support at loading and rendering (formats: 16-bit PNG, float-based KTX, 16/32-bit TIFFs). A lot of new documentation and examples. We in particular recommend 2 new tutorial articles introducing most important engine concepts: Bad way to play chess, aka 3D physics fun. Support us We appreciate your support on Patreon. There are also other ways to support us and if you’re a company, we’re open to cooperation (write to michalis@castle-engine.io). By 2024, Michalis, the lead engine developer, spent most of his life on the engine and doesn’t plan to stop. Moreover, Michalis now works on the engine full-time counting only on your support. So anything you can give is really appreciated! Spread the word! We don’t do much marketing. Because we suck at marketing. Help us — spread the word about this new release! Post about it anywhere you can. Talk about it in your communities — online or in the Real World. Tell your family about it (they really want to know). Reuse this news post and screenshots freely. Have fun everyone and thank you for using the engine.
  6. Brian Evans

    "Death to WITH" in your Delphi Code

    If they added the ability to provide an alias the ambiguity would be gone. Aliases in SQL are useful and perform a similar function. Shortening repeated references can make code easier to read, the problem is the current WITH creates ambiguity. A code snipped from the blog post redone with the ability to provide an alias as an example: procedure TMyForm.UpdateInventoryItem(const NewQty: Integer); begin with dmStoreInventoryData as A do begin with A.tblUpdateItemForStore as B do begin B.Edit; B.FieldByName('Qty').AsInteger := NewQty; B.Post; end; end; end;
  7. David Heffernan

    Determining why Delphi App Hangs

    Run in the debugger. When it hangs, use Run | Program pause to pause execution. Look at the thread window, and double click the main thread since I guess that is the thread which is hung. Look at the call stack window which will tell you what the thread is doing that is not completing.
×