00:00
00:00
mtv129
I'm making a virtual computer on action script 3, ruffle limits me very much

mtv1337 @mtv129

Age 23, Male

as3 and adobe AIR

Ukraine

Joined on 10/22/21

Level:
19
Exp Points:
3,772 / 4,010
Exp Rank:
13,773
Vote Power:
6.08 votes
Rank:
Police Sergeant
Global Rank:
8,522
Blams:
194
Saves:
901
B/P Bonus:
12%
Whistle:
Normal
Trophies:
4
Medals:
851

mtv129's News

Posted by mtv129 - 1 day ago


You probably see the power in SWC libraries, or used #include "file.as", but you just don't know the modules in the Adobe Flash library, here's what you need for this:


1) create a .fla file


2) add an empty MovieClip to it, write in Indetifer the name of the class that will be used in the module


3) write a class for it, create several functions


4) create the main .fla file where the module will be used


5) create a clip with these settings

iu_1190292_9946875.png

6) add to the scene (can be in _root)


7) now you have a class that works as a module and can work with the environment, for example, change Misha’s cursor to another in the entire game, modules can work between each other


Now you can create modules, they will serve you well


Tags:

4

Posted by mtv129 - 8 days ago


I think that some people need a parser for tea leaves of PNG images, if you go into the technical parts, each PNG file consists of a 16-bit signature and chunks, there are many chunks, then they have the same thing:


1) Data size

2) Chunk name

3) Data

4) CRC

and according to my algorithm for finding chunks, which you see below, you can get all the chunks and their data.


The first chunk will always be IHDR in which the basic data of the PNG file will be drawn, namely: width, height, color depth, color type, compression method (always 0), filtering method (always 0), four-line scan. And the last chunk is IEND which has no data.


In order to get all the chunks you need to check every 4 bytes for the presence of a name, get the data size and using it + CRC key the second chunk with the same parameters will be sent, this is how I did it on haxe

public static function parseChunks(code:String):Array<Dynamic> {
    // Array to store parsed chunks
    var chunks = [];
    
    // Starting index for chunk scanning
    var currentIndex:Int = 16;
    
    // Array of known chunk names and their corresponding hexadecimal representations
    var chunkName:Array<String> = ["IDAT", "IEND", "IHDR", "PLTE", "bKGD", "cHRM", "gAMA", "hIST", "iCCP", "iTXt", "pHYs", "sBIT", "sPLT", "sRGB", "tEXt", "tRNS", "zTXt"];
    var chunkHex:Array<String> = ["49444154", "49454E44", "49484452", "504C5445", "624B4744", "6348524D", "67414D41", "68495354", "69434350", "69545874", "70485973", "73424954", "73504C54", "73524742", "74455874", "74524E53", "7A545874"];
    
    // Loop through the code to find and parse chunks
    while (currentIndex < code.length + 2) {
        // Extract 8 characters from the code as a test chunk
        var testChunk = code.substring(currentIndex, currentIndex + 8);
        
        // Check if the test chunk exists in the list of known chunk hexadecimal representations
        if (chunkHex.indexOf(testChunk) != -1){
            // Calculate the size of data for the current chunk
            var dataSize = Std.parseInt("0x" + code.substring(currentIndex - 8, currentIndex ));
            
            // Get the type of the chunk based on its hexadecimal representation
            var type:String = Bytes.ofHex(testChunk).toString();
            
            // Extract data for the current chunk
            var data = code.substring(currentIndex + 8, currentIndex + 8 + dataSize * 2);
            
            // Extract CRC for the current chunk
            var crc = code.substring(currentIndex + 8 + dataSize * 2, currentIndex + 16 + dataSize * 2);
            
            // Create an object to represent the current chunk and add it to the chunks array
            var object = {
                name: testChunk,
                type: type,
                dataSize: dataSize,
                data: data,
                crc: crc
            };
            chunks.push(object);
            
            // Move the current index to the next chunk
            currentIndex += 16 + dataSize * 2;
        } else {
            // Move the current index by 2 if the test chunk is not found
            currentIndex += 2;
        }
    }
    return chunks;
}

and on Rust

// Function to parse chunks from a PNG file
fn read_chunks(code: String) -> Result<Vec<Chunk>, io::Error> {
    // Array to store parsed chunks
    let mut chunks: Vec<Chunk> = Vec::new();
    
    // Starting index for chunk scanning
    let mut current_index: usize = 16;
    
    // Array of known chunk names and their corresponding hexadecimal representations
    let chunk_hex: Vec<&str> = vec![
        "49444154", "49454E44", "49484452", "504C5445", "624B4744", "6348524D",
        "67414D41", "68495354", "69434350", "69545874", "70485973", "73424954",
        "73504C54", "73524742", "74455874", "74524E53", "7A545874"
    ];
    
    // Loop through the code to find and parse chunks
    while (current_index as usize) < code.len() {
        // Extract 8 characters from the code as a test chunk
        let test_chunk = &code[current_index..current_index + 8];
        
        // Check if the test chunk exists in the list of known chunk hexadecimal representations
        if let Some(_position) = chunk_hex.iter().position(|&s| s == test_chunk.to_string()) {
            // Calculate the size of data for the current chunk
            let hex_string = &code[current_index - 8..current_index];
            let data_size: i128 = i128::from_str_radix(hex_string, 16).unwrap();
            
            // Extract data for the current chunk
            let data = &code[current_index + 8..current_index + 8 + (data_size as usize) * 2];
            
            // Extract CRC for the current chunk
            let crc = &code[current_index + 8 + (data_size as usize) * 2..current_index + 16 + (data_size as usize) * 2];
            
            // Create a chunk object and add it to the chunks vector
            let chunk = Chunk {
                name: test_chunk.to_string(),
                data_size: data_size,
                data: data.to_string(),
                crc: crc.to_string(),
            };
            chunks.push(chunk);
            
            // Move the current index to the next chunk
            current_index += 16 + current_index * 2;
        } else {
            // Move the current index by 2 if the test chunk is not found
            current_index += 2;
        }
    }
    Ok(chunks)
}

Tags:

Posted by mtv129 - December 4th, 2023


action script 2: https://jacksmack.newgrounds.com/news/post/1243452


this post has all the links that were in the topics AS3: Main, separate links have also been added for a better understanding of things and creating games not only in Adobe Flash, but also using Flex and other code editors, books have also been provided that can be found on the Internet, it is planned to add other tutorials on AS3, if you want to add something or find errors or the link does not open, write in private messages, Also, this is all intended only if you already know action script 2 or another programming language, and if you can’t find the answer to your question in one of the posts, then read the comments



********** OTHER USEFUL LINKS**********

Flash CS3 Review/Overview by Depredation 

Getting Started with AS3

Senocular's AS3 Tip of the Day

download air

ari development tools

Starling Forum

air discord

AS3 documentation by adobe

help whith adobe AIR

flash help

Kirupa

publication of the project

hit test in as3

Flex SDK ASDoc


BOOKS:

Essential Action Script 3.0

action script 3.0 bible

action script 3.0 animation

make flash game on AS3

action script 3 on android

adobe AIR(AS3) in 24 hours


Actionscript 3.0 Tutorials and Resources


********** BASIC - GENERAL **********

AS3: Basics by trig1

AS3: Main - The ultimate tutorial reading experience by Paranoia

AS3: Buttons Explained by Flynny

AS3: Simple Preloader by Denvish

AS3: TextField class by Silkey



********** BASIC - SPECIFIC **********

AS3: Keyboard Events For Newbies by XBigTK13X

AS3: Drawing Rectangles and circles by m4x0

AS3: fl.controls by Silkey

AS3: Simple Filters by crushy

AS3: Tutorial: Toggle Quality With Q by chronicADRENLIN

AS3: All About Context Menus by Xaotik

AS3: Explaining The Return Function by chronicADRENLIN

AS3: Main, thats what she said! by Sam

AS3: Simple Navigation Button! by SketchistGames



********** INTERMEDIATE - GENERAL **********

AS3: Timer by Denvish

AS3: Custom Cursor by Jindo

AS3: global buttons by tversteeg

AS3: Events by LesPaulPlayer

AS3: Oop by Alphabit

AS3: Object Oriented Programming by Diki

AS3: Quality by LesPaulPlayer

AS3: old fashioned random function by LesPaulPlayer

AS3: Api. Shapes by phyconinja

AS3: Display List & Swapping Depths by ShooterMG

AS3: Buttons Explained by Flynny

AS3: HitTesting by Jindo

AS3: Changing Framerate by Siggles

AS3: Preloader by chunkycheese12

AS3: Displaying Variables in textbox by LilFugitive

AS3: Counter by LilFugitive

AS3: Loading external images by LilFugitive

AS3: Code style speed tests by dELtaluca

AS3: Opening A Url by Xaotik

AS3: Convert Hexidecimal To Rgb by matrix5565

AS3: Document Class Tut! Root Lives! by JoSilver

AS3: Naming Conventions & code style by Yannickl88

AS3: Share Level Code by Glaiel-Gamer

AS3: Remove Everything by Drakenflight



********** INTERMEDIATE - SPECIFIC **********

AS3: Pointing at mouse by trig1

AS3: Rotate And Shoot To Mouse by Pyromaniac

AS3: Class Id - Attachmovieclip by Alphabit

AS3: Collision Detection by pivot11

AS3: Swf Protection! by JoSilver

AS3: Inventory System Tutorial In As3 by FatalFuryX 

AS3: Closures by DougyTheFreshmaker

AS3: Context Menu (rightclickmenu) by xedon

AS3: Fps Display by StaliN98

AS3: Bitwise Operations by Diki

AS3: Objects by MCarsten

AS3: Circle-circle Collision by MCarsten

AS3: Static Keyword, The by Diki

AS3: circumference rect collisions by CocosMiller

AS3: Arrays, Vectors & Dictionaries by Kirk-Cocaine

AS3: Singleton Design Pattern by Kirk-Cocaine

AS3: Billiard Game Physics by MCarsten

AS3: Tile-Based Mechanics by MSGhero

AS3: Advanced Keyboard Detection by Diki 

AS3: Math Functions by MCarsten

AS3: startDrag Area in a Circle by IndigenousDigitalist

AS3: Sockets (adobe Air Style) by egg82

AS3: ByteArrays by egg82

AS3: Basic 3d Simulation by MCarsten

AS3: External Text Files by MSGhero

AS3: State Machines by egg82



********** ADVANCED - GENERAL **********

AS3: How to give someone a seizure by Deadclever23

AS3: Crashing your flash app by Deadclever23

AS3: Digital Clocks by crushy



********** ADVANCED - SPECIFIC **********

AS3: High speed collision detection by johnfn

AS3: Binary Search by matrix5565

AS3: Remove Everything by Drakenflight

AS3: Arranging depths in Y by mtv129



Apache Flex SDK Tutorials and Resources



********** BASIC - GENERAL **********

AS3: Flex: Introduction by mtv129

AS3: Flex: MXML Basics by mtv129

AS3: Flex: Adding elements by mtv129

AS3: Flex: Work with text by mtv129

AS3: Flex: Many screens by mtv129

AS3: Flex: MXML Event by mtv129



********** BASIC - SPECIFIC **********

AS3: Flex: Load Image by mtv129

AS3: Flex: SWF loader by mtv129

AS3: Flex: [Bindable] by mtv129

AS3: Flex: FLV loader by mtv129

AS3: Flex: Text and Fonts by mtv129

AS3: Flex: Style(Basic) by mtv129

AS3: Flex: Layouts by mtv129



********** INTERMEDIATE - GENERAL **********

AS3: Flex: Assets Manager by mtv129



********** INTERMEDIATE - SPECIFIC **********

in production



If you have come here and want to help new users learn in action script 3, then please help me, send me the material you want to add in a private message or help me create Apache Flex SDK Tutorials, we will need to collect books, materials and create tutorials ourselves that are missing, let's give people knowledge, if you want to help, before you go write a tutorial, contact me to get more information


Tags:

8

Posted by mtv129 - December 4th, 2023


I will soon make a huge post containing information about as3, this will be a tutorial like Jack Smeсk did


Posted by mtv129 - November 26th, 2023


https://x.com/mtv7create/status/1728697959942906259?s=20

look what I did, it's a virtual computer, I couldn't give you the files or a demo because it's too early, so watch the video and if you're a musician, write to me, I will need music (free) in the future


Tags:

3

Posted by mtv129 - November 20th, 2023


Hello everyone, and yes, I wrote the same message on many servers where I was, I’m not leaving NG, but I’m leaving communities such as: kitty krew, clock crew, piconjo and some unknown to you, just know that I may return but it won't be soon, for now I'll be making my own game called trace();, I also won’t delete anything, I remember what else I should have participated in, but that’s okay, I just won’t delete old animation games and that’s because it’s memory


Edit* I deleted old games and animations and drawings


Tags:

6