World: r3wp
[Rebol/Flash dialect] content related to Rebol/Flash dialect
older newer | first last |
Oldes 24-Nov-2005 [93] | interesting, this one I haven't known, for me it's enough what I have (anyway it looks that you cannot make subpixel fonts with this editor and you must do the tracing by hand:) |
Alek_K 24-Nov-2005 [94x2] | well - there is another tool for that :) PixFont - http://www.kgroup.ru/ |
Anyway - you made great job! | |
Oldes 24-Nov-2005 [96x3] | I was thinking about making visual editor as well, but don't think it's so important, I have my font and that's enough for now:) |
maybe I could hack the trutype spac to have possibility to save the font as a TTF as well | |
(spac = specification) | |
Alek_K 24-Nov-2005 [99] | It could be good commercial product to sell :) There are many users - and most free fonts are english only (same with tools for making fonts from handwriting f.e.). |
Oldes 24-Nov-2005 [100] | hm, but you make 3 fonts and then nobody will need it:) there is not many possibilities to make something original in 7x8 pixel grid:) and yes, the main reason was, that there are no font's with diacritics for my language (even the commercial one don't have it) |
Alek_K 24-Nov-2005 [101] | I thought about tool for localization :) AFAIK both SimpleFont and PixFont are unique on market. Curious - how many software they sold? |
Oldes 24-Nov-2005 [102] | I don't know |
james_nak 28-Feb-2006 [103] | Oldes, I'm still amazed at this dialect and the sites you have created. I wonder if you have a list of the commands that are being used. I've been going through the examples to try to figure out what does what but it seems like a list would be faster. Thanks. |
Oldes 1-Mar-2006 [104x2] | i will do it one day:-) |
Interesting, just found this page: http://www.langreiter.com/exec/yahoo-vs-google.html?q=rebol | |
JaimeVargas 1-Mar-2006 [106] | Thats really cool. |
james_nak 1-Mar-2006 [107x2] | That's weird. |
Oldes, I downloaded the ActionScript pdf which seems to be the very much related to the dialect examples. Is that correct? | |
Volker 1-Mar-2006 [109] | Are there other differences between real actionscript and dialect? (syntax)? Or is it possible to write an importer? And would it make sense, or does one write anyway everything by himself? |
james_nak 1-Mar-2006 [110] | Volker, I've just begun to really get into the dialect so I can't comment on how one "translates" the actionscript into it, however, the actionscript pdf is at least a start into trying to figure out the examples. At this point, I am taking one of the examples from the flash actionscript pdf and rework it into the dialect form. Before I had this documentation I was just guessing at the whole process. |
james_nak 2-Mar-2006 [111] | Oldes, you what would be helpful is an actionscript example translated into the dialect so we could see the differences. |
Oldes 2-Mar-2006 [112] | The main difference is, that I use variable: value instead of variable= value :) and do not use commas to divide arguments |
james_nak 2-Mar-2006 [113] | is that it? |
Oldes 2-Mar-2006 [114x2] | and cannot use array[index] but must use pick array index |
and do not use for(i=0;i<sz;i++) but use for i sz 1 [] | |
james_nak 2-Mar-2006 [116] | Do you have any examples where you have translated actionscript? |
Oldes 2-Mar-2006 [117] | I don't know what you mean translated actionscript. All content of DoAction [] tag is something like action script |
james_nak 2-Mar-2006 [118] | I see. What I mean is taking an actionscript example and converting it to your dialect. Right now I'm trying to make a simple "slideshow" with fades and I found some actionscript examples. That being said, just you saying that the DoAction[] is somewhat like Actionscript takes some mystery out of the process. |
Oldes 2-Mar-2006 [119] | what do you want to convert? |
james_nak 2-Mar-2006 [120] | I'll have to look for it again...I left my memory stick at home/ |
Oldes 2-Mar-2006 [121] | And I should say, that you definitely must know the ActionScript, if you want to use my dialect. |
james_nak 2-Mar-2006 [122] | Yes, you're right. Up this point I was really looking at the wrong documentation so the Actionscript clue was helpful. Here's an example. I haven't tried to translate it yet. It looks pretty straight forward. Movieclip.prototype.fade = function(speed) { this.speed = speed; this.f_index = this._alpha; if(this.f_index >= 100) this.fade_by = -this.speed; if(this.f_index <= 0) this.fade_by = this.speed; this._alpha += this.fade_by; } Or you can use these to fadeIn() or fadeOut() Movieclip.prototype.fadeOut = function($decrement, $fadeLimit){ var $mcObject = this; //If $decrement is not defined, then define it if($decrement == undefined){ var $decrement = 11; }//End if if($fadeLimit == undefined){ var $fadeLimit = 0; }//End if if(eval($mcObject)._alpha < $fadeLimit){ return(true); } else { eval($mcObject)._alpha -= $decrement; }//End if }//End function |
Oldes 2-Mar-2006 [123x3] | Movieclip.prototype.fade: func[speed][ this.speed: speed this.f_index: this._alpha if this.f_index >= 100 [ this.fade_by: 0 - this.speed] if this.f_index <= 0 [ this.fade_by: this.speed] this._alpha: this._alpha + this.fade_by; ] |
or | |
Movieclip.prototype.fade: func[speed][ this.speed: speed tellTarget this [ f_index: _alpha if f_index >= 100 [ fade_by: 0 - speed] if f_index <= 0 [ fade_by: speed] _alpha: _alpha + fade_by ] ] | |
james_nak 2-Mar-2006 [126] | You're too good. So how then do you use this? |
james_nak 5-Mar-2006 [127] | Oldes, making some progress thanks to your help. There is one example with soem embedded rebol code (the arc example). Is there a way to have rebol do some processing then expose what it does to flash? I want to write a function in rebol to take a string and create a block of characters which I then want to pass to flash. For example, I can hardcode a_block: ["h" "e" "l" "l" "o"] but I would rather send the string "hello" to a function and have it generate that block then pass it to flash. It seems that what I do within a "rebol [ ]" block is hidden from flash. |
Oldes 5-Mar-2006 [128x9] | First of all, I must say, that there are two main parts of the dialect, one which are related to making shapes and sprites in the timelines (processed by rswf/tag-rules) and actions (in doAction and DoInitAction tags and as a part of Actions subtag in placing sprites and in button events) - This is processed by rswf/actions-parser |
you can use Rebol tag to do any Rebol evaluation, but it does not return anything, it's not meant to use something like: spr_mysprite: rebol [some code] | |
but you may use: rebol [ rswf/compile load rejoin [{spr_} spritename {: sprite shp_someshape}]] | |
but in Actions you can use: now: rebol [ rejoin [ a_block " " now]] | |
(will test it if it's working like that, I'm not using it:) | |
yes, it's working:-)) | |
doAction [ info: rebol [now] info: reform [(rebol [rejoin ["h" "e" "l" "l" "o"]]) "now is:" info] ] | |
But it's not working well with blocks, so now if you want to create varaible with block during compilation, you should use: | |
doAction [ rebol [ myRebolBlock: ["h" "e" "l" "l" "o"] ;this is Rebol's variable rswf/compile-actions compose/only [info: (myRebolBlock)] ] ] | |
james_nak 6-Mar-2006 [137x2] | Thanks Oldes, I will try that. The dialect and AS are becoming clearer now with all the info you have given me. I look forward to writing lots of cool things. Thanks for the hint about the two main parts. I wondered how they were connected as most of the AS tutorial have you create something with the GUI then add the AS part. |
Worked great! Is there any way to pass AS vars to a rebol block? You must think I'm crazy but this is an amazing piece of coding and I am determined to use it. I'm curious but when you created your work for the incredible web pages you've done, did you make libraries or are they basically one large script? | |
Oldes 7-Mar-2006 [139] | How you want to pass AS vars to Rebol? Once you compile the RSWF dialect file, you have Flash which has nothing to do with Rebol. But you can connect Flash and Rebol using various ways (, getUrl, loadVariables or XMLsocket connections). When I do some bigger projects, I do not use one file, but rather more files conected together using "include" or "require" tags. |
james_nak 7-Mar-2006 [140] | You know that is true. I hadn't thought of that. |
Oldes 7-Mar-2006 [141] | I also use import-swf tag to get SWF graphics into my projects (when I don't want to load the SWFs using loadMovie) |
james_nak 7-Mar-2006 [142] | I'm going to start a new website project and am excited about designing some stuff. If I could only make the cool things you do... |
older newer | first last |