Raised This Month: $ Target: $400
 0% 

[L4D2] an Event that randomly spawn and throws(?) props |had this idea to use ChatGPT


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
LividBunny
Member
Join Date: Mar 2021
Old 04-13-2023 , 18:48   [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use ChatGPT
Reply With Quote #1

I had this idea of using ChatGPT for my own plugin ideas for left 4 dead 2.
I got to about 19th attempt till I gave up.
Just to be clear I know nothing about coding.

It keeps making code either with Errors or outdated code.

Code:
#include <sourcemod>

#define PLUGIN_NAME "Random Props"
#define PLUGIN_VERSION "1.0"
#define PROP_MODELS_NUM 4
#define MIN_PROPS 5
#define MAX_PROPS 10
#define THROW_INTERVAL 60.0

const char g_szPropModels[PROP_MODELS_NUM][32] =
{
    "models/props_interiors/furniture_couch01a.mdl",
    "models/props_interiors/furniture_chair01a.mdl",
    "models/props_junk/garbage_metalcan001a.mdl",
    "models/props_wasteland/kitchen_counter001c.mdl"
};

public void OnPluginStart()
{
    RegisterPlugin(PLUGIN_NAME, PLUGIN_VERSION, "by ChatGPT");

    CreateTimer(THROW_INTERVAL, ThrowProps);
}

public Action ThrowProps(Handle timer)
{
    int numProps = RandomInt(MIN_PROPS, MAX_PROPS);
    PropInfo prop_info;
    PropPhysics prop_physics;

    for (int i = 0; i < numProps; i++)
    {
        int prop_index = RandomInt(0, PROP_MODELS_NUM - 1);
        Vector vPropOrigin = Vector(RandomFloat(-1500.0, 1500.0), RandomFloat(-1500.0, 1500.0), RandomFloat(-1500.0, 1500.0));
        Vector vPropDirection = Vector(RandomFloat(-1.0, 1.0), RandomFloat(-1.0, 1.0), RandomFloat(-1.0, 1.0));

        prop_info.model = g_szPropModels[prop_index];
        prop_info.spawnflags = 0;
        prop_physics.SetPosition(vPropOrigin);
        prop_physics.SetVelocity(vPropDirection * RandomFloat(500.0, 1500.0));
        Prop_Create(prop_info, prop_physics);
    }

    return Plugin_Continue;
}

public void OnPluginEnd()
{
    RemoveTimer(ThrowProps);
}
Code:
\ChatGPT to make a SM plugin\RandoPropLaunch19.sp(10) : error 001: expected token: "=", but found "["
\ChatGPT to make a SM plugin\RandoPropLaunch19.sp(16) : error 010: invalid function or declaration
This is just one of my ideas tho.

Last edited by LividBunny; 04-13-2023 at 18:49.
LividBunny is offline
Marttt
Veteran Member
Join Date: Jan 2019
Location: Brazil
Old 04-13-2023 , 18:58   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #2

Keep asking to ChatGPT until the plugin compiles
__________________
Marttt is offline
LividBunny
Member
Join Date: Mar 2021
Old 04-13-2023 , 19:07   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #3

Quote:
Originally Posted by Marttt View Post
Keep asking to ChatGPT until the plugin compiles
Quote:
"I'm sorry, but I cannot directly compile code for you as I am just a text-based AI language model."
Got it to send a google drive link but "Sorry, the file you have requested does not exist."

lmao

Last edited by LividBunny; 04-13-2023 at 19:11.
LividBunny is offline
TotalChaos SourcePawner
Senior Member
Join Date: Feb 2023
Location: IN PINEAPPLE, UNDER SEA
Old 04-14-2023 , 11:07   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #4

Try looking at this plugin: https://forums.alliedmods.net/showthread.php?p=2605254
"[L4D2] Charger Actions (1.12) [10-Feb-2023]" by "Silvers".

It has a small section of code in the plugin defining some of the Charger's wall slamming sounds.
Maybe that could help?
TotalChaos SourcePawner is offline
LividBunny
Member
Join Date: Mar 2021
Old 04-14-2023 , 16:32   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #5

Quote:
Originally Posted by TotalChaos SourcePawner View Post
Try looking at this plugin: https://forums.alliedmods.net/showthread.php?p=2605254
"[L4D2] Charger Actions (1.12) [10-Feb-2023]" by "Silvers".

It has a small section of code in the plugin defining some of the Charger's wall slamming sounds.
Maybe that could help?
Wrong Thread?
LividBunny is offline
TotalChaos SourcePawner
Senior Member
Join Date: Feb 2023
Location: IN PINEAPPLE, UNDER SEA
Old 04-14-2023 , 17:18   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #6

Quote:
Originally Posted by LividBunny View Post
Wrong Thread?
You said that you had errors compiling the plugin, and it looked like it was related to your table thing that lists the models that can be used.
So I thought "well this plugin has a fully functional thing just like that so maybe it could help this guy".

I just wanted to help you finish the plugin, is all. I really like the idea of random props just flying around the sky every once in a while.


EDIT: Ohhh, I understand now. I misread your post.
I thought you wanted to make a plugin, but couldn't figure out how. So you just released it here for somebody else to pick it up.
But no, that was not the case. You were talking to an AI and it made you a SourceMod plugin.
Sorry about that.

Also, how smart is that AI anyway? Based on your posts, it looks to be incredibly smart.
I looked it up myself, but it seems to be only accessible to people that created an account for the site.

Last edited by TotalChaos SourcePawner; 04-14-2023 at 17:25.
TotalChaos SourcePawner is offline
LividBunny
Member
Join Date: Mar 2021
Old 04-14-2023 , 18:15   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #7

Quote:
Originally Posted by TotalChaos SourcePawner View Post
You said that you had errors compiling the plugin, and it looked like it was related to your table thing that lists the models that can be used.
So I thought "well this plugin has a fully functional thing just like that so maybe it could help this guy".

I just wanted to help you finish the plugin, is all. I really like the idea of random props just flying around the sky every once in a while.


EDIT: Ohhh, I understand now. I misread your post.
I thought you wanted to make a plugin, but couldn't figure out how. So you just released it here for somebody else to pick it up.
But no, that was not the case. You were talking to an AI and it made you a SourceMod plugin.
Sorry about that.

Also, how smart is that AI anyway? Based on your posts, it looks to be incredibly smart.
I looked it up myself, but it seems to be only accessible to people that created an account for the site.
ChatGPT is a powerful AI that can help you instead of CleverBot that just talks with you.
LividBunny is offline
TotalChaos SourcePawner
Senior Member
Join Date: Feb 2023
Location: IN PINEAPPLE, UNDER SEA
Old 04-14-2023 , 18:42   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #8

Quote:
Originally Posted by LividBunny View Post
ChatGPT is a powerful AI that can help you instead of CleverBot that just talks with you.
Ah, thanks for that.
Also, CleverBot wasn't really ever "clever". Even now it's still kinda dumb.
Remember CleverBot Evie? I used to love some of the ridiculous "responses" she would give people. I still do, actually.

Last edited by TotalChaos SourcePawner; 04-14-2023 at 18:42.
TotalChaos SourcePawner is offline
Bacardi
Veteran Member
Join Date: Jan 2010
Location: mom's basement
Old 04-15-2023 , 07:25   Re: [L4D2] an Event that randomly spawn and throws(?) props |had this idea to use Cha
Reply With Quote #9

What the hell have happened people in here?
Bacardi is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:53.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode