Blog Features Pricing

Visualize your architechture.
Let Ai do the rest.

As engineers, we think your job should be more solution architecture, and less repetitive code. So we created a tool to visualise and form modules, and an Ai sidekick will generate classes with full module context.

preview

Ai-powered. Ideated by you.

Data Class
using UnityEngine;

public class RacketBehavior : MonoBehaviour
{
    private Rigidbody2D rb;
    public Ball ball; // Reference to the Ball object
    private Vector2 lastPointOfContact;

    // Initialization
    void Start()
    {
        rb = GetComponent<igidbody2D&пt;();
    }

    void Update()
    {
        updatePosition();
    }

    public void updatePosition()
    {
        float moveHorizontal = Input.GetAxis("Horizontal");
        float moveVertical = Input.GetAxis("Vertical");

        Vector2 movement = new Vector2(moveHorizontal, moveVertical);
        rb.MovePosition(rb.position + movement * Time.deltaTime);
    }

    public void applyForce(Vector2 force)
    {
        rb.AddForce(force);
    }

    public void calculateSpin(Vector2 pointOfContact)
    {
        Vector2 racketMovementDirection = rb.velocity.normalized;
        float racketSpeed = rb.velocity.magnitude;

        // Calculate the basic spin value based on racket speed
        float spinAmount = racketSpeed * 0.5f; // Arbitrary coefficient for spin calculation

        // Adjust spin direction based on the point of contact
        if (pointOfContact.x < 0) // Hit on the left side
        {
            spinAmount *= -1; // Negative spin for left-side hits
        }
        // For right-side hits, the spinAmount remains positive

        Debug.Log($"Calculated Spin: {spinAmount}");

        ball.ApplySpin(spinAmount);
    }

    // This method is called when the racket collides with another object
    void OnCollisionEnter2D(Collision2D collision)
    {
        if (collision.gameObject.tag == "Ball") // Ensure we're colliding with the ball
        {
            // Get the first point of contact
            ContactPoint2D contact = collision.contacts[0];
            lastPointOfContact = contact.point; // Store the point for use in other methods

            calculateSpin(lastPointOfContact);
        }
    }
}
                    
        
RacketBehavior

updatePosition(), applyForce(Vector2 force), calculateSpin(Vector2 pointOfContact)

Pricing

  1. Free

    0/mo

    Try it out, make a
    concious decision

    • 1 Admin account
    • Create & Store 2 UML's
    • Generate 10 classes
  2. Pro

    /mo

    Choose smart code tactics

    • 1 Admin account
    • Unlimited UML's
    • Up toAi-classes
    • Store up to 50 modules
  3. Enterprise

    399/mo

    Elevate a whole team's productivity by 5x

    • Team admin accounts
    • Unlimited UML's
    • Unlimited Ai-classes
    • Unlimited storage
You can always add more classes later

Frequently Asked Questions