Delgine 3D Tools & Content DeleD Community Edition
Forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

DeleD CE source questions...

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD Development
View previous topic :: View next topic  
Author Message
paul_nicholls
DeleD PRO user


Joined: 05 Dec 2007
Posts: 356
Location: Hobart, Tasmania, Australia

PostPosted: Wed Jan 27, 2010 2:24 am    Post subject: DeleD CE source questions... Reply with quote

Hi guys, I have a question:

I noticed this routine in my travels (Units\unit_XMLDataReader.pas):

Code:
function TXMLDataReader.ObjectTypeForDescription(const aDescription: string): TObjectType;
var found: boolean;

begin
    found := FALSE;

    for result := Low(TObjectType) to High(TObjectType) do
    begin
        if XML_PRIMITIVE_TYPES[result] = aDescription then
        begin
            found := TRUE;
            break;
        end;
    end;

    if not found then
    begin
        raise Exception.Create(Format('Unknown blend operation "%s".', [aDescription]));
    end;
end;


Should this:

Code:
raise Exception.Create(Format('Unknown blend operation "%s".',


be:

Code:
raise Exception.Create(Format('Unknown object type "%s".',


??

This looks like the good old copy and paste but forget to edit trick!! LOL

Been there, done that! Wink

Anyway, I noticed this when I was trying to add in a path primitive to DeleD, and I got an Unknown blend operation... error when trying to load a scene with a path in it (not via IDE).

cheers,
Paul
_________________
Long live DeleD!

Hi ho...hi ho...it's off 3d modeling I go...
Back to top
View user's profile Send private message
paul_nicholls
DeleD PRO user


Joined: 05 Dec 2007
Posts: 356
Location: Hobart, Tasmania, Australia

PostPosted: Wed Jan 27, 2010 5:11 am    Post subject: Reply with quote

I have another question now:

If I want to create a new primitive (vertices, polygons, etc) and add it into the current scene from DeleD code, what is the best procedure for this (including enabling undo, etc)?

I have managed to add in a path primitive to DeleD so I can sort of see how the primitive is added when doing this, but it uses tools and other stuff which is quite confusing...

Is there an easier way of adding plain primitives to a DeleD scene using simpler code?

cheers,
Paul
_________________
Long live DeleD!

Hi ho...hi ho...it's off 3d modeling I go...
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    DeleD Community Edition Forum Index -> DeleD Development All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum