AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D2]Random Tank Rock With Props And Explosion[v3.0.0] (https://forums.alliedmods.net/showthread.php?t=334215)

King_OXO 09-07-2021 15:20

[L4D2]Random Tank Rock With Props And Explosion[v3.0.0]
 
1 Attachment(s)
Description

this plugin makes that when the tank throws rocks the rock catches fire and when it is destroyed it explodes and also when the tank throws the rock, can spawn a random props: Tree Trunk and Giant Rock

Related Plugins

º [L4D1 & L4D2] Tank Rock Ignition [v1.1.0 | 17-April-2021] by Marttt

º [L4D1 & L4D2] Random Tank Rock [v1.1.0 | 18-April-2021] by Marttt

Video:


if you are using other plugins in which you use tank rock and want to use this plugin, please remove them

you can edit the time for objects to explode in l4d2_timer_explode


Changelog


Cvars

Krufftys Killers 09-07-2021 20:13

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.0]
 
Just installed it and getting is error

SourceMod error session started
L 09/08/2021 - 00:07:57: Info (map "c6m3_port") (file "/home/container/left4dead2/addons/sourcemod/logs/errors_20210908.log")
L 09/08/2021 - 00:07:57: [SM] Exception reported: Invalid edict (2353 - -2107631311)
L 09/08/2021 - 00:07:57: [SM] Blaming: l4d_tank_props_rock.smx
L 09/08/2021 - 00:07:57: [SM] Call stack trace:
L 09/08/2021 - 00:07:57: [SM] [0] GetEdictClassname
L 09/08/2021 - 00:07:57: [SM] [1] Line 122, /home/forums/content/files/3/0/6/7/6/1/191240.attach::OnEntityDestroyed
L 09/08/2021 - 00:07:57: [SM] Exception reported: Invalid edict (2354 - -2113005262)
L 09/08/2021 - 00:07:57: [SM] Blaming: l4d_tank_props_rock.smx

King_OXO 09-08-2021 09:24

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.0]
 
Quote:

Originally Posted by Krufftys Killers (Post 2757214)
Just installed it and getting is error

SourceMod error session started
L 09/08/2021 - 00:07:57: Info (map "c6m3_port") (file "/home/container/left4dead2/addons/sourcemod/logs/errors_20210908.log")
L 09/08/2021 - 00:07:57: [SM] Exception reported: Invalid edict (2353 - -2107631311)
L 09/08/2021 - 00:07:57: [SM] Blaming: l4d_tank_props_rock.smx
L 09/08/2021 - 00:07:57: [SM] Call stack trace:
L 09/08/2021 - 00:07:57: [SM] [0] GetEdictClassname
L 09/08/2021 - 00:07:57: [SM] [1] Line 122, /home/forums/content/files/3/0/6/7/6/1/191240.attach::OnEntityDestroyed
L 09/08/2021 - 00:07:57: [SM] Exception reported: Invalid edict (2354 - -2113005262)
L 09/08/2021 - 00:07:57: [SM] Blaming: l4d_tank_props_rock.smx

FIXED

Krufftys Killers 09-08-2021 12:49

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.1]
 
now this error
09/08/2021 - 14:07:30: SourceMod error session started
L 09/08/2021 - 14:07:30: Info (map "c7m2_barge") (file "/home/container/left4dead2/addons/sourcemod/logs/errors_20210908.log")
L 09/08/2021 - 14:07:30: [SM] Exception reported: Cannot create new entity when no map is running
L 09/08/2021 - 14:07:30: [SM] Blaming: l4d_tank_props_rock.smx
L 09/08/2021 - 14:07:30: [SM] Call stack trace:
L 09/08/2021 - 14:07:30: [SM] [0] CreateEntityByName
L 09/08/2021 - 14:07:30: [SM] [1] Line 124, /home/forums/content/files/3/0/6/7/6/1/191261.attach::OnEntityDestroyed
L 09/08/2021 - 14:35:10: Error log file session closed.

King_OXO 09-08-2021 14:30

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.1]
 
Quote:

Originally Posted by Krufftys Killers (Post 2757281)
now this error
09/08/2021 - 14:07:30: SourceMod error session started
L 09/08/2021 - 14:07:30: Info (map "c7m2_barge") (file "/home/container/left4dead2/addons/sourcemod/logs/errors_20210908.log")
L 09/08/2021 - 14:07:30: [SM] Exception reported: Cannot create new entity when no map is running
L 09/08/2021 - 14:07:30: [SM] Blaming: l4d_tank_props_rock.smx
L 09/08/2021 - 14:07:30: [SM] Call stack trace:
L 09/08/2021 - 14:07:30: [SM] [0] CreateEntityByName
L 09/08/2021 - 14:07:30: [SM] [1] Line 124, /home/forums/content/files/3/0/6/7/6/1/191261.attach::OnEntityDestroyed
L 09/08/2021 - 14:35:10: Error log file session closed.

it is normal, this appears when the map is started, after the map is loaded the plugin works correctly
if the game or server crashes, let me know

Psyk0tik 09-08-2021 15:32

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.1]
 
Quote:

Originally Posted by King_OXO (Post 2757286)
it is normal, this appears when the map is started, after the map is loaded the plugin works correctly
if the game or server crashes, let me know

Create a variable that is set to "true" inside OnMapStart() and only create new entities if that variable is "true". That's how you can fix the error. Just because it is normal doesn't mean you can ignore it. You still have to code your plugin properly to resolve simple errors like that.

King_OXO 10-13-2021 13:04

Re: [L4D2]Random Tank Rock with props and explosion[v2.0.1]
 
NEW UPDATE


see the initial post to see what has changed

MasterMind420 10-13-2021 13:39

Re: [L4D2]Random Tank Rock with props and explosion[v2.1.0]
 
You need to provide the source or a link to the source in order to post plugins on allied modders, this post will eventually get flagged otherwise...
I am curious to look at the code to see what's going on with the errors...not sure why you are creating any entity when they cant be created which is what's causing the error.
No entity should be created with this type of plugin until the tank actually throws the rock, u can do everything from there.

MasterMind420 10-13-2021 13:48

Re: [L4D2]Random Tank Rock with props and explosion[v2.1.0]
 
ok it looks like everything is good...except i'm curious if this is a oversight or not...
line 126...CreateTimer(0.0, Car, entity, TIMER_REPEAT|TIMER_FLAG_NO_MAPCHANGE);
the lowest possible timer thru createtimer is 0.1....i think 0.0 would just default to that but who knows.
also for efficiency and to guarantee all netprops Datamaps are available from the tank rock i would use a spawnpost hook instead of nextframe.
i've seen in some situations where next frame is too early after onentitycreated.
Good luck...

King_OXO 10-13-2021 14:05

Re: [L4D2]Random Tank Rock with props and explosion[v2.1.0]
 
Quote:

Originally Posted by MasterMind420 (Post 2760504)
ok it looks like everything is good...except i'm curious if this is a oversight or not...
line 126...CreateTimer(0.0, Car, entity, TIMER_REPEAT|TIMER_FLAG_NO_MAPCHANGE);
the lowest possible timer thru createtimer is 0.1....i think 0.0 would just default to that but who knows.
also for efficiency and to guarantee all netprops Datamaps are available from the tank rock i would use a spawnpost hook instead of nextframe.
i've seen in some situations where next frame is too early after onentitycreated.
Good luck...

I'll leave it that way because I'm being very careful with the plugin, man.
because I'm very new to sourcepawn


All times are GMT -4. The time now is 09:50.

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